mirror of
https://github.com/bellingcat/datasheet-server.git
synced 2026-06-08 03:18:33 +03:00
refactor to scripts
This commit is contained in:
@@ -10,9 +10,7 @@ before_script:
|
||||
install:
|
||||
- yarn
|
||||
script:
|
||||
- if [ "TRAVIS_PULL_REQUEST" = "false" ]; then bash ./scripts/decrypt.sh; fi
|
||||
- yarn build
|
||||
- yarn lint
|
||||
- yarn test
|
||||
before_install:
|
||||
- openssl aes-256-cbc -K $encrypted_4f23b46f1ec6_key -iv $encrypted_4f23b46f1ec6_iv
|
||||
-in .env.enc -out .env -d
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
},
|
||||
"husky": {
|
||||
"hooks": {
|
||||
"pre-commit": "yarn test && yarn lint && travis encrypt-file .env --add --force && git add ."
|
||||
"pre-push": "yarn test && yarn lint && travis encrypt-file .env --add --force && git add .env.enc && git commit -m \"add encrypted key\""
|
||||
}
|
||||
},
|
||||
"repository": {
|
||||
|
||||
2
scripts/decrypt.sh
Normal file
2
scripts/decrypt.sh
Normal file
@@ -0,0 +1,2 @@
|
||||
#!/bin/bash
|
||||
openssl aes-256-cbc -K $encrypted_4f23b46f1ec6_key -iv $encrypted_4f23b46f1ec6_iv -in .env.enc -out .env -d
|
||||
6
scripts/encrypt.sh
Normal file
6
scripts/encrypt.sh
Normal file
@@ -0,0 +1,6 @@
|
||||
#!/bin/bash
|
||||
yarn test
|
||||
yarn lint
|
||||
travis encrypt-file .env --add --force
|
||||
git add .env.enc
|
||||
git commit -m "add encrypted private key for travis testing"
|
||||
Reference in New Issue
Block a user