Browse Source

Fix deployment scripts

pull/486/head
Guillaume Vincent 5 years ago
parent
commit
ff1b574eb6
4 changed files with 11 additions and 7 deletions
  1. +2
    -5
      bin/deploy_node_modules
  2. +1
    -0
      bin/deploy_web_extensions
  3. +7
    -2
      bin/release
  4. +1
    -0
      package.json

+ 2
- 5
bin/deploy_node_modules View File

@@ -16,11 +16,8 @@ set -o pipefail
set -o nounset set -o nounset


function push_packages_on_npm { function push_packages_on_npm {
grep --fixed-strings --line-regexp --silent "//registry.npmjs.org/:_authToken=$NPM_TOKEN" ~/.npmrc
if [ $? == 1 ]
then
echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" >> ~/.npmrc
fi
touch ~/.npmrc
grep --fixed-strings --line-regexp --silent "//registry.npmjs.org/:_authToken=$NPM_TOKEN" ~/.npmrc || echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" >> ~/.npmrc
projects="lesspass lesspass-crypto lesspass-entropy lesspass-fingerprint lesspass-pure lesspass-render-password" projects="lesspass lesspass-crypto lesspass-entropy lesspass-fingerprint lesspass-pure lesspass-render-password"
for project in ${projects} for project in ${projects}
do do


+ 1
- 0
bin/deploy_web_extensions View File

@@ -16,6 +16,7 @@ set -o pipefail
set -o nounset set -o nounset


function release_web_extensions { function release_web_extensions {
yarn install
yarn workspace lesspass-web-extension run release yarn workspace lesspass-web-extension run release
VERSION=$(grep -Po '(?<="version": ")[^"]*' package.json) VERSION=$(grep -Po '(?<="version": ")[^"]*' package.json)
echo "Download sources on https://github.com/lesspass/lesspass/releases/tag/${VERSION}" echo "Download sources on https://github.com/lesspass/lesspass/releases/tag/${VERSION}"


+ 7
- 2
bin/release View File

@@ -19,12 +19,17 @@ function check_repository_is_clean {
git remote update git remote update
git add . git add .
git status git status
git diff-index --quiet HEAD --;
git diff-index --quiet HEAD
if [ $? == 1 ] if [ $? == 1 ]
then then
print_error "Git repository not clean. Aborting." print_error "Git repository not clean. Aborting."
exit 1 exit 1
fi fi
if [ $(git rev-parse HEAD) != $(git rev-parse @{u}) ]
then
print_error "Git branch diverged. Aborting."
exit 1
fi
} }


function check_branch_is_master { function check_branch_is_master {
@@ -116,7 +121,7 @@ function build_web_extensions {


function build_mobile_app { function build_mobile_app {
pushd mobile/android/ pushd mobile/android/
./gradlew assembleRelease
./gradlew bundleRelease
popd popd
} }




+ 1
- 0
package.json View File

@@ -60,6 +60,7 @@
"vue-polyglot-utils": "^0.1.1", "vue-polyglot-utils": "^0.1.1",
"vue-template-compiler": "^2.6.10", "vue-template-compiler": "^2.6.10",
"walk": "^2.3.14", "walk": "^2.3.14",
"web-ext": "^3.2.0",
"web-ext-submit": "^3.1.0", "web-ext-submit": "^3.1.0",
"webpack": "^4.35.3", "webpack": "^4.35.3",
"webpack-cli": "^3.3.6", "webpack-cli": "^3.3.6",


Loading…
Cancel
Save