Build documentation updates and a new option (novcheck

This commit is contained in:
Ciaran Gultnieks 2011-01-31 22:57:56 +00:00
parent 73cf43ca59
commit 2895250014
2 changed files with 47 additions and 36 deletions

View file

@ -397,17 +397,21 @@ for app in apps:
p = subprocess.Popen([aapt_path,'dump','badging',
src], stdout=subprocess.PIPE)
output = p.communicate()[0]
vercode = None
version = None
for line in output.splitlines():
if line.startswith("package:"):
pat = re.compile(".*versionCode='([0-9]*)'.*")
vercode = re.match(pat, line).group(1)
pat = re.compile(".*versionName='([^']*)'.*")
version = re.match(pat, line).group(1)
if version == None or versioncode == None:
print "Could not find version information in build in output"
sys.exit(1)
if thisbuild.has_key('novcheck') and thisbuild['novcheck'] == "yes":
vercode = thisbuild['vercode']
version = thisbuild['version']
else:
vercode = None
version = None
for line in output.splitlines():
if line.startswith("package:"):
pat = re.compile(".*versionCode='([0-9]*)'.*")
vercode = re.match(pat, line).group(1)
pat = re.compile(".*versionName='([^']*)'.*")
version = re.match(pat, line).group(1)
if version == None or versioncode == None:
print "Could not find version information in build in output"
sys.exit(1)
# Some apps (e.g. Timeriffic) have had the bonkers idea of
# including the entire changelog in the version number. Remove