forked from enviPath/enviPy
Current Dev State
This commit is contained in:
33
static/js/ketcher2/node_modules/pem/bin/aftersuccess.sh
generated
vendored
Executable file
33
static/js/ketcher2/node_modules/pem/bin/aftersuccess.sh
generated
vendored
Executable file
@ -0,0 +1,33 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
|
||||
VAR_PUSH=0
|
||||
|
||||
for i in "$@" ; do
|
||||
if [[ $i == "-push" ]] ; then
|
||||
VAR_PUSH=1
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
||||
git config --global user.name "Dexus via TravisCI"
|
||||
git config --global user.email "github@josef-froehle.de"
|
||||
git config credential.helper "store --file=.git/credentials"
|
||||
echo "https://$GH_TOKEN:@github.com" > .git/credentials
|
||||
git checkout "$TRAVIS_BRANCH" || exit 0
|
||||
|
||||
if [[ "${VAR_PUSH}" == "1" ]]
|
||||
then
|
||||
OUTPUT=$(node "$(pwd)/bin/aftersuccess.js")
|
||||
STATUS=$?
|
||||
echo "${OUTPUT}"
|
||||
fi
|
||||
|
||||
if [[ "${STATUS}" == "0" && "${VAR_PUSH}" == "1" ]]
|
||||
then
|
||||
sleep 10
|
||||
npm run changelog
|
||||
git add HISTORY.md
|
||||
git commit -m "Update HISTORY.md via TravisCI" -m "[ci skip]"
|
||||
git push
|
||||
fi
|
||||
Reference in New Issue
Block a user