From 368a6ae5141e383b2ad9456e627b68314d4f0a04 Mon Sep 17 00:00:00 2001 From: Ciaran Gultnieks Date: Thu, 4 Jun 2015 15:00:31 +0100 Subject: [PATCH] Stop fdroid update saying it requires signing keys when it doesn't Again! --- fdroidserver/update.py | 39 ++++++++++++++++++++------------------- 1 file changed, 20 insertions(+), 19 deletions(-) diff --git a/fdroidserver/update.py b/fdroidserver/update.py index 1d31a2be..1af10fa8 100644 --- a/fdroidserver/update.py +++ b/fdroidserver/update.py @@ -745,25 +745,26 @@ def make_index(apps, sortedids, apks, repodir, archive, categories): repoel.setAttribute("timestamp", str(int(time.time()))) nosigningkey = False - if 'repo_keyalias' not in config: - nosigningkey = True - logging.critical("'repo_keyalias' not found in config.py!") - if 'keystore' not in config: - nosigningkey = True - logging.critical("'keystore' not found in config.py!") - if 'keystorepass' not in config and 'keystorepassfile' not in config: - nosigningkey = True - logging.critical("'keystorepass' not found in config.py!") - if 'keypass' not in config and 'keypassfile' not in config: - nosigningkey = True - logging.critical("'keypass' not found in config.py!") - if not os.path.exists(config['keystore']): - nosigningkey = True - logging.critical("'" + config['keystore'] + "' does not exist!") - if nosigningkey: - logging.warning("`fdroid update` requires a signing key, you can create one using:") - logging.warning("\tfdroid update --create-key") - sys.exit(1) + if not options.nosign: + if 'repo_keyalias' not in config: + nosigningkey = True + logging.critical("'repo_keyalias' not found in config.py!") + if 'keystore' not in config: + nosigningkey = True + logging.critical("'keystore' not found in config.py!") + if 'keystorepass' not in config and 'keystorepassfile' not in config: + nosigningkey = True + logging.critical("'keystorepass' not found in config.py!") + if 'keypass' not in config and 'keypassfile' not in config: + nosigningkey = True + logging.critical("'keypass' not found in config.py!") + if not os.path.exists(config['keystore']): + nosigningkey = True + logging.critical("'" + config['keystore'] + "' does not exist!") + if nosigningkey: + logging.warning("`fdroid update` requires a signing key, you can create one using:") + logging.warning("\tfdroid update --create-key") + sys.exit(1) repoel.setAttribute("pubkey", extract_pubkey()) root.appendChild(repoel) -- 2.30.2