sys.stderr.write('Please clone the gitian-builder repository from github.com/devrandom/gitian-builder to the directory containing the gitian.sigs repository.\nIf you already have the gitian.sigs directory cloned, but under another name or path, use --gitian-builder-dir to pass its absolute directory path to the script.\n')
sys.exit(1)
ifnotos.path.isdir(args.monero_dir):
sys.stderr.write('Please clone the monero repository from github.com/monero-project/monero to the directory containing the gitian.sigs repository.\nIf you already have the monero repository cloned, but under another name or path, use --monero-dir to pass its absolute directory path to the script.\n')
parser=argparse.ArgumentParser(usage='%(prog)s [options] version',description='Use this script before merging a pull request to the gitian.sigs repository and to verify the signature of existing gitian assert files and gitian assert files in specific pull requests')
parser.add_argument('-p','--pull_id',dest='pull_id',help='Github Pull request id to check')
parser.add_argument('--monero-dir',dest='monero_dir',default='../monero',help='System Path to the monero repository, e.g. /home/user/monero')
parser.add_argument('--gitiian-builder-dir',dest='gitian_builder_dir',default='../gitian-builder',help='System Path to the gitian-builder repository, e.g. /home/user/gitian-builder')
parser.add_argument('-k','--refresh-keys',action='store_true',dest='refresh_keys',help='refresh all pgp public keys that are currently in the gpg keyring.')
parser.add_argument('-i','--import-keys',action='store_true',dest='import_keys',help='import all public keys in the gitian-pubkeys directory to the gpg keyring.')