chiark / gitweb /
Uncomment verbose messages, fix -I
authorDaniel Martí <mvdan@mvdan.cc>
Tue, 7 Jan 2014 11:24:15 +0000 (12:24 +0100)
committerDaniel Martí <mvdan@mvdan.cc>
Thu, 9 Jan 2014 15:23:48 +0000 (16:23 +0100)
fdroidserver/update.py

index b274dab39b0238dd023b3bc150f04230199b9ad8..45d6ae5068aff56dc23492efbc57085649265974 100644 (file)
@@ -301,9 +301,9 @@ def resize_all_icons(repodirs):
     for repodir in repodirs:
         for density in get_densities():
             icon_dir = get_icon_dir(repodir, density)
-            icon_glob = os.path.join(repodir, icon_dir, '*.png')
+            icon_glob = os.path.join(icon_dir, '*.png')
             for iconpath in glob.glob(icon_glob):
-                resize_icon(iconpath)
+                resize_icon(iconpath, density)
 
 def scan_apks(apps, apkcache, repodir, knownapks):
     """Scan the apks in the given repo directory.
@@ -365,8 +365,6 @@ def scan_apks(apps, apkcache, repodir, knownapks):
                                   'dump', 'badging', apkfile],
                                  stdout=subprocess.PIPE)
             output = p.communicate()[0]
-            #if options.verbose:
-                #print output
             if p.returncode != 0:
                 print "ERROR: Failed to get apk information"
                 sys.exit(1)
@@ -922,21 +920,21 @@ def main():
 
         if added:
             app['added'] = added
-        #else:
-            #if options.verbose:
-                #print "WARNING: Don't know when " + app['id'] + " was added"
+        else:
+            if options.verbose:
+                print "WARNING: Don't know when " + app['id'] + " was added"
         if lastupdated:
             app['lastupdated'] = lastupdated
-        #else:
-            #if options.verbose:
-                #print "WARNING: Don't know when " + app['id'] + " was last updated"
+        else:
+            if options.verbose:
+                print "WARNING: Don't know when " + app['id'] + " was last updated"
 
         if bestver == 0:
             if app['Name'] is None:
                 app['Name'] = app['id']
             app['icon'] = None
-            #if options.verbose and app['Disabled'] is None:
-                #print "WARNING: Application " + app['id'] + " has no packages"
+            if options.verbose and app['Disabled'] is None:
+                print "WARNING: Application " + app['id'] + " has no packages"
         else:
             if app['Name'] is None:
                 app['Name'] = bestapk['name']