mirror of
https://gitlab.com/fdroid/fdroidserver.git
synced 2024-11-20 13:50:12 +01:00
nightly: --keep-private-keys option to allow further processing
This makes it possible to run `fdroid server update` after `fdroid nightly` has completed. It also actually deletes all private key files.
This commit is contained in:
parent
1d6c462605
commit
881074b2aa
@ -91,6 +91,8 @@ def main():
|
|||||||
help=_("Specify which debug keystore file to use."))
|
help=_("Specify which debug keystore file to use."))
|
||||||
parser.add_argument("--show-secret-var", action="store_true", default=False,
|
parser.add_argument("--show-secret-var", action="store_true", default=False,
|
||||||
help=_("Print the secret variable to the terminal for easy copy/paste"))
|
help=_("Print the secret variable to the terminal for easy copy/paste"))
|
||||||
|
parser.add_argument("--keep-private-keys", action="store_true", default=False,
|
||||||
|
help=_("Do not remove the private keys generated from the keystore"))
|
||||||
parser.add_argument("--file", default='app/build/outputs/apk/*.apk',
|
parser.add_argument("--file", default='app/build/outputs/apk/*.apk',
|
||||||
help=_('The the file to be included in the repo (path or glob)'))
|
help=_('The the file to be included in the repo (path or glob)'))
|
||||||
parser.add_argument("--no-checksum", action="store_true", default=False,
|
parser.add_argument("--no-checksum", action="store_true", default=False,
|
||||||
@ -289,8 +291,10 @@ Last updated: {date}'''.format(repo_git_base=repo_git_base,
|
|||||||
logging.error(_('cannot publish update, did you set the deploy key?')
|
logging.error(_('cannot publish update, did you set the deploy key?')
|
||||||
+ '\n' + deploy_key_url)
|
+ '\n' + deploy_key_url)
|
||||||
sys.exit(1)
|
sys.exit(1)
|
||||||
if shutil.rmtree.avoids_symlink_attacks:
|
if not options.keep_private_keys:
|
||||||
shutil.rmtree(os.path.dirname(ssh_private_key_file))
|
os.remove(KEYSTORE_FILE)
|
||||||
|
if shutil.rmtree.avoids_symlink_attacks:
|
||||||
|
shutil.rmtree(os.path.dirname(ssh_private_key_file))
|
||||||
|
|
||||||
else:
|
else:
|
||||||
if not os.path.isfile(options.keystore):
|
if not os.path.isfile(options.keystore):
|
||||||
|
Loading…
Reference in New Issue
Block a user