update packaging setup. Update readme
This commit is contained in:
parent
290ad3409c
commit
d2b30c6141
|
@ -20,15 +20,14 @@ Please note: A [workaround for CORS](https://chrome.google.com/webstore/detail/a
|
|||
## Testing
|
||||
|
||||
1. Run `npm run webpack:watch` in one terminal window to activate running code compilation.
|
||||
2. Run `npm run test` in another terminal window to start Karma tests.
|
||||
2. Run `npm run test` in another terminal window to start Karma tests.
|
||||
|
||||
## Deployment
|
||||
|
||||
Steps to deploy an update to the Chrome extension.
|
||||
|
||||
1. Increment the plugin version number found in `src/plugin-specific/manifest.json`
|
||||
1. Run `npm run build` to build a dist folder ready to be packaged for upload.
|
||||
1. Run `npm run package` to zip the dist folder into a dist.zip.
|
||||
1. Run `npm run package` to build a fresh dist/ folder and zip it into dist.zip.
|
||||
1. Log into [Chrome Web Store Developer Dashboard - Google](https://chrome.google.com/webstore/developer/dashboard). You'll need to have access
|
||||
to the account that have publishing rights to this application.
|
||||
1. Within the dashboard upload the update .zip and hit publish.
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
"build": "webpack && ./build.sh",
|
||||
"test:dist": "karma start",
|
||||
"start": "browser-sync start --no-notify -b chromium --startPath test/ --server --files 'src/**/*'",
|
||||
"package": "rm dist.zip || true && zip -r dist.zip dist",
|
||||
"package": "npm run build && ./package.sh",
|
||||
"webpack": "webpack",
|
||||
"webpack:watch": "webpack --watch",
|
||||
"karma": "karma"
|
||||
|
|
13
package.sh
Executable file
13
package.sh
Executable file
|
@ -0,0 +1,13 @@
|
|||
#!/bin/sh
|
||||
|
||||
# Called by package.json see package.json.
|
||||
|
||||
# Remove old zip
|
||||
rm dist.zip || true
|
||||
|
||||
# Remove script/link tags used for local development
|
||||
# to avoid unecessary plugin errors when published
|
||||
sed -i '' 's#.*/node_modules.*##g' dist/menu.tpl.html
|
||||
|
||||
# zip and ship!
|
||||
zip -r dist.zip dist
|
Loading…
Reference in a new issue