--- debderiver +++ debderiver_patch3_2_2.py @@ -477,12 +478,19 @@ if __name__ == "__main__": - # Check for reprepro - if not os.path.exists('/usr/bin/reprepro'): - raise IOError, 'Missing dependency: install reprepro and try again.' + try: + open('/usr/bin/reprepro') + except IOError: + sys.stderr.write('Missing dependency: install reprepro and ' + 'try again\n') CONF_DIR_PATH = '/etc/debderiver' + try: + open('%s/debderiver.yaml' % CONF_DIR_PATH) + except IOError: + sys.stderr.write('Copy "debderiver.yaml" to "%s" and edit it ' + 'to suit your needs\n' % CONF_DIR_PATH) conf = parse(CONF_DIR_PATH) rr = Reprepro(conf) rr.configure()