viff

changeset 852:dca8bd3398ab

Allow for uploads outside of viff.dk/builds/.
author Martin Geisler <mg@daimi.au.dk>
date Sun, 27 Jul 2008 22:16:32 +0200
parents 660d22033155
children b5707c789a5a
files run.py
diffstat 1 files changed, 7 insertions(+), 7 deletions(-) [+]
line diff
     1.1 --- a/run.py	Sun Jul 27 22:00:21 2008 +0200
     1.2 +++ b/run.py	Sun Jul 27 22:16:32 2008 +0200
     1.3 @@ -179,12 +179,12 @@
     1.4      fp.close()
     1.5  
     1.6  
     1.7 -@command('upload', 'build', 'key')
     1.8 -def upload(build, key):
     1.9 -    """Upload build directory to http://viff.dk/builds/. This requires
    1.10 -    access to a SSH private key that has access to viff.dk."""
    1.11 -    if not isdir(build):
    1.12 -        abort("%s should be a directory", build)
    1.13 +@command('upload', 'directory', 'key')
    1.14 +def upload(directory, key):
    1.15 +    """Upload directory to http://viff.dk/. This requires an SSH
    1.16 +    private key that has access to viff.dk."""
    1.17 +    if not isdir(directory):
    1.18 +        abort("%s should be a directory", directory)
    1.19      if not os.access(key, os.R_OK):
    1.20          abort("Cannot read %s", key)
    1.21  
    1.22 @@ -192,7 +192,7 @@
    1.23               '--human-readable', '--stats', '--verbose',
    1.24               '--chmod', 'go=rX',
    1.25               '-e', 'ssh -l viff -i %s' % key,
    1.26 -             build, 'viff.dk:~/viff.dk/builds/'])
    1.27 +             directory, 'viff.dk:~/viff.dk/'])
    1.28  
    1.29  @command('size')
    1.30  def size():