From 638b80a8497a9ebe98be68669afab17379c2008b Mon Sep 17 00:00:00 2001 From: Ayaka Mikazuki Date: Sun, 27 Sep 2020 11:12:27 +0800 Subject: [PATCH] Update ToJyutping to https://github.com/CanCLID/ToJyutping/commit/54945d4cf1fc86858acff7b1dd6f3f13dc838bf0 --- build.py | 14 +++++++------- manifest.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/build.py b/build.py index adc5f47..67552c7 100644 --- a/build.py +++ b/build.py @@ -5,17 +5,17 @@ os.system('wget -nc -O lib/browser-polyfill.js https://unpkg.com/webextension-polyfill@0.6.0/dist/browser-polyfill.js') # Preprocess -os.system('wget -nc https://github.com/CanCLID/ToJyutping/raw/f607036f6cce114fced2502aa0d2d0d8169b67f6/preprocess.py') +os.system('wget -nc https://github.com/CanCLID/ToJyutping/raw/54945d4cf1fc86858acff7b1dd6f3f13dc838bf0/preprocess.py') os.system("sed -i 's/src\/ToJyutping\/jyut6ping3.simple.dict.yaml/jyut6ping3.simple.dict.yaml/' preprocess.py") os.system('python preprocess.py') l = [] with open('jyut6ping3.simple.dict.yaml') as f: - for line in f: - k, v = line.rstrip('\n').split('\t') - l.append((k, v)) + for line in f: + k, v = line.rstrip('\n').split('\t') + l.append((k, v)) -with open('background_scripts/dictionary.json.txt', 'w') as f: - f.write(json.dumps(l, ensure_ascii=False).replace('], [', '],\n[')) - f.write('\n') # Add line break at the end of file +with open('background_scripts/dictionary.json.txt', 'w') as f: # *.json.txt: See mozilla/addons-linter#1700 + f.write(json.dumps(l, ensure_ascii=False).replace('], [', '],\n[')) + f.write('\n') # Add line break at the end of file diff --git a/manifest.json b/manifest.json index dad2927..91110fe 100644 --- a/manifest.json +++ b/manifest.json @@ -1,7 +1,7 @@ { "manifest_version": 2, "name": "__MSG_extensionName__", - "version": "0.2.2", + "version": "0.2.3", "description": "__MSG_extensionDescription__", "icons": { "48": "icons/48.png",