Index: releaseAutomation.py |
diff --git a/releaseAutomation.py b/releaseAutomation.py |
index a309ec81526fb1d373a7530271fe854dc8a77332..092addd741c52e5ffd818862be5de94bf7a01315 100644 |
--- a/releaseAutomation.py |
+++ b/releaseAutomation.py |
@@ -118,9 +118,7 @@ def run(baseDir, type, version, keyFile, downloadsRepo): |
print('Aborting release.') |
return 1 |
- if type == 'gecko': |
- import buildtools.packagerGecko as packager |
- elif type == 'safari': |
+ if type == 'safari': |
import buildtools.packagerSafari as packager |
elif type == 'edge': |
import buildtools.packagerEdge as packager |
@@ -142,15 +140,13 @@ def run(baseDir, type, version, keyFile, downloadsRepo): |
file.truncate() |
# Read extension name from locale data |
- import buildtools.packagerGecko as packagerGecko |
- if type == 'gecko': |
- locales_base = baseDir |
- else: |
- # This is somewhat of a hack but reading out locale import config here would be too much |
- locales_base = os.path.join(baseDir, 'adblockplus') |
+ locales_base = os.path.join(baseDir, 'adblockplus') |
- locales = packagerGecko.readLocaleMetadata(locales_base, [packagerGecko.defaultLocale]) |
- extensionName = locales[packagerGecko.defaultLocale]['name'] |
+ with open(os.path.join(locales_base, 'chrome', 'locale', |
Sebastian Noack
2017/10/04 22:22:18
This will no longer work since the "adblockplus" d
tlucas
2017/10/05 10:10:30
Done.
|
+ packager.defaultLocale.replace('_', '-'), |
+ 'meta.json'), |
+ 'r') as fp: |
+ extensionName = json.load(fp)['name'] |
# Now commit the change and tag it |
subprocess.check_call(['hg', 'commit', '-R', baseDir, '-m', 'Releasing %s %s' % (extensionName, version)]) |
@@ -161,11 +157,7 @@ def run(baseDir, type, version, keyFile, downloadsRepo): |
# Create a release build |
downloads = [] |
- if type == 'gecko': |
- buildPath = os.path.join(downloadsRepo, getDefaultFileName(metadata, version, 'xpi')) |
- packager.createBuild(baseDir, type=type, outFile=buildPath, releaseBuild=True) |
- downloads.append(buildPath) |
- elif type == 'chrome': |
+ if type == 'chrome': |
# Create both signed and unsigned Chrome builds (the latter for Chrome Web Store). |
buildPath = os.path.join(downloadsRepo, getDefaultFileName(metadata, version, 'crx')) |
packager.createBuild(baseDir, type=type, outFile=buildPath, releaseBuild=True, keyFile=keyFile) |