summaryrefslogtreecommitdiff
path: root/lorry
diff options
context:
space:
mode:
authorRichard Maw <richard.maw@codethink.co.uk>2012-04-20 11:00:37 +0100
committerRichard Maw <richard.maw@codethink.co.uk>2012-04-20 11:00:37 +0100
commit91dbafc6bb448b8a09bf00f24f57c1236cb76808 (patch)
treebfec763d9be613ec9b5337a00e5a526937b9a50a /lorry
parent0940ca623b9955304e759e427331005e721feabd (diff)
downloadlorry-91dbafc6bb448b8a09bf00f24f57c1236cb76808.tar.gz
lorry: absolute path for all working directories
The user may specify a relative one
Diffstat (limited to 'lorry')
-rwxr-xr-xlorry6
1 files changed, 2 insertions, 4 deletions
diff --git a/lorry b/lorry
index 65f88b9..cfd3670 100755
--- a/lorry
+++ b/lorry
@@ -46,7 +46,7 @@ class Lorry(cliapp.Application):
self.settings.string(['working-area', 'w'],
'use DIR as the working area (for holding '
'intermediate git repositories, etc)',
- metavar='DIR')
+ metavar='DIR', default='workd')
self.settings.string(['mirror-base-url-push'],
'base URL to use for pushing to the mirror '
'server (default: %default)',
@@ -83,9 +83,7 @@ class Lorry(cliapp.Application):
def process_args(self, args):
status = 0
- if self.settings['working-area'] == '' :
- print 'No working area defined going to use "workd" directory'
- self.settings['working-area'] = os.path.abspath('workd')
+ self.settings['working-area'] = os.path.abspath(self.settings['working-area'])
if not os.path.exists(self.settings['working-area']):
os.makedirs(self.settings['working-area'])