Skip to content

Commit 1d8406f

Browse files
authored
Use some shortcuts in the versioning script (OctoLinker#866)
* Use some shortcuts in the versioning script * Add permission to manifest * Drop json dependency * Update package-lock.json
1 parent 427136e commit 1d8406f

File tree

3 files changed

+43
-9
lines changed

3 files changed

+43
-9
lines changed

assets/manifest.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@
2828
{
2929
"matches": [
3030
"https://github.com/*",
31+
"https://api.github.com/*",
3132
"https://gist.github.com/*"
3233
],
3334
"js": [

package-lock.json

Lines changed: 40 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,7 @@
1111
"e2e": "node ./e2e/generate-fixtures-json.js && jest --config=e2e/jest-e2e.config.js",
1212
"postinstall": "lerna bootstrap",
1313
"test:watch": "jest --watch",
14-
"version": "json -I -f assets/manifest.json -e \"this.version='`json -f package.json version`'\" && git add assets/manifest.json && json -I -f packages/core/package.json -e \"this.version='`json -f package.json version`'\" && git add packages/core/package.json",
15-
"patch-permissions": "json -I -f dist/manifest.json -e 'this.permissions.push(\"https://api.github.com/\")'",
14+
"version": "dot-json assets/manifest.json version $npm_package_version && dot-json packages/core/package.json version $npm_package_version && git add assets/manifest.json packages/core/package.json",
1615
"release:cws": "cd dist && webstore upload --auto-publish",
1716
"release:amo": "cd dist && npm run patch-permissions && web-ext-submit",
1817
"release": "npm run release:cws && npm run release:amo",
@@ -40,6 +39,7 @@
4039
"codecov": "^3.5.0",
4140
"copy-webpack-plugin": "^5.0.3",
4241
"css-loader": "^3.0.0",
42+
"dot-json": "^1.2.0",
4343
"dotenv": "^8.0.0",
4444
"eslint": "^6.4.0",
4545
"eslint-config-airbnb": "^17.1.0",
@@ -51,7 +51,6 @@
5151
"jest": "^25.1.0",
5252
"jest-fetch-mock": "^3.0.2",
5353
"jest-puppeteer": "^4.2.0",
54-
"json": "^9.0.6",
5554
"json-loader": "^0.5.7",
5655
"lerna": "^3.15.0",
5756
"npm-run-all": "^4.1.5",

0 commit comments

Comments
 (0)