chiark / gitweb /
checkupdates: don't ignore root directory
authorDaniel Martí <mvdan@mvdan.cc>
Sun, 25 Oct 2015 18:09:55 +0000 (19:09 +0100)
committerDaniel Martí <mvdan@mvdan.cc>
Sun, 25 Oct 2015 18:09:55 +0000 (19:09 +0100)
fdroidserver/checkupdates.py

index 32d6604e8fb4e06b0cef9dbf22b682ee97bb20db..f6ebc57a851077dc88ff969d649c451311285021 100644 (file)
@@ -143,7 +143,10 @@ def check_tags(app, pattern):
             vcs.gotorevision(tag)
 
             for subdir in possible_subdirs(app):
-                root_dir = os.path.join(build_dir, subdir)
+                if subdir == '.':
+                    root_dir = build_dir
+                else:
+                    root_dir = os.path.join(build_dir, subdir)
                 paths = common.manifest_paths(root_dir, flavours)
                 version, vercode, package = \
                     common.parse_androidmanifests(paths, app['Update Check Ignore'])
@@ -210,7 +213,10 @@ def check_repomanifest(app, branch=None):
         hver = None
         hcode = "0"
         for subdir in possible_subdirs(app):
-            root_dir = os.path.join(build_dir, subdir)
+            if subdir == '.':
+                root_dir = build_dir
+            else:
+                root_dir = os.path.join(build_dir, subdir)
             paths = common.manifest_paths(root_dir, flavours)
             version, vercode, package = \
                 common.parse_androidmanifests(paths, app['Update Check Ignore'])
@@ -328,8 +334,6 @@ def possible_subdirs(app):
         package = common.parse_androidmanifests(m_paths, app['Update Check Ignore'])[2]
         if app_matches_packagename(app, package):
             subdir = os.path.relpath(d, build_dir)
-            if subdir == '.':
-                continue
             logging.debug("Adding possible subdir %s" % subdir)
             yield subdir