From 69ff89d3610c1cff4fa255c3c37ea192b8384043 Mon Sep 17 00:00:00 2001 From: Ciaran Gultnieks Date: Wed, 14 Aug 2013 08:49:27 +0100 Subject: [PATCH] Make RepoManifest work with gradle (at least for simple cases) --- fdroidserver/checkupdates.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/fdroidserver/checkupdates.py b/fdroidserver/checkupdates.py index 20f51b80..0cb435ac 100644 --- a/fdroidserver/checkupdates.py +++ b/fdroidserver/checkupdates.py @@ -145,7 +145,13 @@ def check_repomanifest(app, sdk_path, branch=None): if not os.path.isdir(build_dir): return (None, "Subdir '" + app['builds'][-1]['subdir'] + "'is not a valid directory") - version, vercode, package = common.parse_androidmanifest(build_dir) + if os.path.exists(os.path.join(build_dir, 'AndroidManifest.xml')): + version, vercode, package = common.parse_androidmanifest(build_dir) + elif os.path.exists(os.path.join(build_dir, 'src', 'main', 'AndroidManifest.xml')): + # Alternate location for simple gradle locations... + version, vercode, package = common.parse_androidmanifest(os.path.join(build_dir, 'src', 'main')) + else: + return (None, "AndroidManifest.xml not found") if not package: return (None, "Couldn't find package ID") if package != app['id']: