Skip to content
This repository has been archived by the owner on Apr 11, 2023. It is now read-only.

Commit

Permalink
Merge pull request #316 from ueokande/release-0.10
Browse files Browse the repository at this point in the history
Release 0.10
  • Loading branch information
ueokande authored Jan 20, 2018
2 parents 9614ec1 + 3c4deaf commit 635fa31
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 2 deletions.
2 changes: 1 addition & 1 deletion manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"manifest_version": 2,
"name": "Vim Vixen",
"description": "Vim Vixen",
"version": "0.9",
"version": "0.10",
"icons": {
"48": "resources/icon_48x48.png",
"96": "resources/icon_96x96.png"
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"scripts": {
"start": "webpack -w --debug --devtool inline-source-map",
"build": "NODE_ENV=production webpack --progress --display-error-details",
"package": "npm run build && node script/package.js",
"package": "npm run build && script/package.sh",
"lint": "eslint --ext .jsx,.js src",
"test": "karma start"
},
Expand Down
20 changes: 20 additions & 0 deletions script/package.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
#!/bin/sh

MANIFEST="manifest.json"

version=$(jq -r '.version' $MANIFEST)

icons=$(jq -r '.icons[]' $MANIFEST)
content_scripts=$(jq -r '.content_scripts[].js[]' $MANIFEST)
background_scripts=$(jq -r '.background.scripts[]' $MANIFEST)
web_accessible_resources=$(jq -r '.web_accessible_resources[]' $MANIFEST)
options_ui=$(jq -r '.options_ui.page' $MANIFEST)
options_scripts=""
for html in $options_ui; do
scripts=$(grep -Po "(?<=src=['\"])[^'\"]*" "$html")
for js in $scripts; do
options_scripts="$options_scripts $(dirname $html)/$js"
done
done

zip ${version}.zip $MANIFEST $icons $content_scripts $background_scripts $web_accessible_resources $options_ui $options_scripts

0 comments on commit 635fa31

Please sign in to comment.