chiark / gitweb /
Make the 'update' flag a list too
authorDaniel Martí <mvdan@mvdan.cc>
Mon, 17 Feb 2014 12:07:13 +0000 (13:07 +0100)
committerDaniel Martí <mvdan@mvdan.cc>
Mon, 17 Feb 2014 12:09:44 +0000 (13:09 +0100)
docs/fdroid.texi
fdroidserver/common.py
fdroidserver/metadata.py

index 08b8f3fcab46dece0fb30851abb60312a4791cee..665fedd7bb18ad8f7e54f706801493627befef1e 100644 (file)
@@ -852,7 +852,7 @@ possibly sub-projects. This is likely to cause the whole build.xml to be
 rewritten, which is fine if it's a 'standard' android file or doesn't already
 exist, but not a good idea if it's heavily customised.
 
-@item update=xxx
+@item update=<auto/dirs>
 By default, 'android update project' is used to generate or update the
 project and all its referenced projects. Specifying update=no bypasses that.
 Note that this only matters in ant build recipes.
@@ -860,7 +860,7 @@ Note that this only matters in ant build recipes.
 Default value is '@code{auto}', which uses the paths used in the
 project.properties file to find out what project paths to update.
 
-Otherwise, value can be a semicolon-separated list of directories in
+Otherwise, value can be a comma-separated list of directories in
 which to run 'android update project' relative to the main
 application directory (which may include '@code{subdir}' parameter).
 
@@ -895,14 +895,14 @@ Multiple files/directories can be specified by separating them with ','.
 Directories will be recursively deleted.
 
 @item extlibs=a,b,...
-Specifies a list of external libraries (jar files) from the
+Comma-separated list of external libraries (jar files) from the
 @code{build/extlib} library, which will be placed in the @code{libs} directory
-of the project. Separate items with semicolons.
+of the project.
 
 @item srclibs=[n:]a@@r,[n:]b@@r1,...
-Specifies a list of source libraries or Android projects. Separate items with
-semicolons, and each item is of the form name@@rev where name is the predefined
-source library name and rev is the revision or tag in source control to use.
+Comma-separated list of source libraries or Android projects. Each item is of
+the form name@@rev where name is the predefined source library name and rev is
+the revision or tag to use in the respective source control.
 
 For ant projects, you can optionally append a number with a colon at the
 beginning of a srclib item to automatically place it in project.properties as
index 6e2c1b1fde4566b68505d8b1620cbad9da6f6615..b52562b2c8992a7335d49b5955aa875e687e87bf 100644 (file)
@@ -1055,9 +1055,9 @@ def prepare_source(vcs, app, build, build_dir, srclib_dir, extlib_dir, onserver=
             raise BuildException("Error running prebuild command for %s:%s" %
                     (app['id'], build['version']), p.stdout)
 
-    updatemode = build.get('update', 'auto')
+    updatemode = build.get('update', ['auto'])
     # Generate (or update) the ant build file, build.xml...
-    if updatemode != 'no' and build['type'] == 'ant':
+    if updatemode != ['no'] and build['type'] == 'ant':
         parms = [os.path.join(config['sdk_path'], 'tools', 'android'), 'update']
         lparms = parms + ['lib-project']
         parms = parms + ['project']
@@ -1065,10 +1065,10 @@ def prepare_source(vcs, app, build, build_dir, srclib_dir, extlib_dir, onserver=
         if 'target' in build and build['target']:
             parms += ['-t', build['target']]
             lparms += ['-t', build['target']]
-        if updatemode == 'auto':
+        if updatemode == ['auto']:
             update_dirs = ant_subprojects(root_dir) + ['.']
         else:
-            update_dirs = [d.strip() for d in updatemode.split(';')]
+            update_dirs = updatemode
 
         for d in update_dirs:
             subdir = os.path.join(root_dir, d)
index 12c99bf68962d0c5c89af19637e634f457841aa0..ef6e8e8e86803ef29f2d24b1c499abc29bccb7e9 100644 (file)
@@ -452,7 +452,7 @@ def metafieldtype(name):
 
 def flagtype(name):
     if name in ['extlibs', 'srclibs', 'patch', 'rm', 'buildjni',
-            'scanignore', 'scandelete']:
+            'update', 'scanignore', 'scandelete']:
         return 'list'
     if name in ['init', 'prebuild', 'build']:
         return 'script'