1
0
Fork 0
mirror of https://github.com/gorhill/uMatrix.git synced 2024-05-20 20:23:37 +12:00

update tool scripts for proper versioning

This commit is contained in:
gorhill 2017-01-31 17:47:03 -05:00
parent 8828c4d5cb
commit cc7be90de4
3 changed files with 12 additions and 4 deletions

View file

@ -2,7 +2,7 @@
"manifest_version": 2,
"name": "uMatrix",
"short_name": "uMatrix",
"version": "0.9.9",
"version": "0.9.9.3",
"description": "__MSG_extShortDesc__",
"icons": {
"16": "img/icon_16.png",

View file

@ -2,6 +2,7 @@
import os
import json
import re
import sys
from io import open
from shutil import rmtree
@ -76,8 +77,15 @@ with open(chromium_manifest, encoding='utf-8') as m:
# https://developer.mozilla.org/en-US/Add-ons/AMO/Policy/Maintenance#How_do_I_submit_a_Beta_add-on.3F
# "To create a beta channel [...] '(a|alpha|b|beta|pre|rc)\d*$' "
if sys.argv[2]:
manifest['version'] += sys.argv[2]
match = re.search('^(\d+\.\d+\.\d+)(\.\d+)$', manifest['version'])
if match:
buildtype = int(match.group(2)[1:])
if buildtype < 100:
builttype = 'b' + str(buildtype)
else:
builttype = 'rc' + str(buildtype - 100)
manifest['version'] = match.group(1) + builttype
manifest['homepage'] = 'https://github.com/gorhill/uMatrix'
manifest['description'] = escape(descriptions['en'])

View file

@ -29,7 +29,7 @@ cp platform/firefox/*.xul $DES/
cp LICENSE.txt $DES/
echo "*** uMatrix.firefox: Generating meta..."
python tools/make-firefox-meta.py $DES/ "$2"
python tools/make-firefox-meta.py $DES/
if [ "$1" = all ]; then
echo "*** uMatrix.firefox: Creating package..."