comparison python/setup_repo.py @ 464:35f3730870e7

python/setup_repo.py
author Jeff Hammel <jhammel@mozilla.com>
date Sat, 10 Aug 2013 18:34:47 -0700
parents 66c2a17d8424
children 4063bbeaa7d4
comparison
equal deleted inserted replaced
463:66c2a17d8424 464:35f3730870e7
29 def call(command, *args, **kwargs): 29 def call(command, *args, **kwargs):
30 30
31 if isinstance(command, string): 31 if isinstance(command, string):
32 command_str = command 32 command_str = command
33 else: 33 else:
34 if len(command) == 1: 34 command_str = subprocess.list2cmdline(command)
35 command_str = subprocess.list2cmdline(command)
36 35
37 print 'Running:\n%s' % (command_str) 36 print 'Running:\n%s' % (command_str)
38 if globals()['dry_run']: 37 if globals()['dry_run']:
39 return 38 return
40 return subprocess.check_output(*args, **kwargs) 39 return subprocess.check_output(*args, **kwargs)