Compare commits

...

17 Commits

Author SHA1 Message Date
Georges Dupéron
1419620d68 Fixed typo 2017-05-02 16:52:53 +02:00
Georges Dupéron
8bdc1999fa Allow builds of v2.7.1-racket-mini-source branch 2017-05-02 16:01:43 +02:00
Georges Dupéron
2287de322d make the openssl line easier to substitue (move the decrypted file to its destination after the command, not as part of it) 2017-03-22 00:23:27 +01:00
Georges Dupéron
0585c0b74a Fix script 2017-03-21 01:46:34 +01:00
Georges Dupéron
0d6a3a49dd Fix script 2017-03-21 01:42:22 +01:00
Georges Dupéron
9fb852d1ef Fix script 2017-03-21 01:38:18 +01:00
Georges Dupéron
6f8805033c Fix script 2017-03-21 01:35:52 +01:00
Georges Dupéron
9bb1d81212 Fix script 2017-03-20 20:13:56 +01:00
Georges Dupéron
a555db20c9 Fix script 2017-03-20 20:12:46 +01:00
Georges Dupéron
73a45ea0ec Fix script 2017-03-20 20:07:08 +01:00
Georges Dupéron
0b9355a7d1 Fixed script 2017-03-20 20:01:02 +01:00
Georges Dupéron
ec4623a80f Fixed script. 2017-03-20 19:38:24 +01:00
Georges Dupéron
062820300a Fixed issues with deploy script 2017-03-20 18:59:02 +01:00
Georges Dupéron
7e0a9e441e Fixed issues with deploy script 2017-03-20 18:58:07 +01:00
Georges Dupéron
f0b14cecf3 Fixed auto-deploy script 2017-03-20 18:16:59 +01:00
Georges Dupéron
655648db7f Fixed auto-deploy script 2017-03-20 18:10:14 +01:00
Georges Dupéron
ebf429472f Use deploy key instead of secret token. 2017-03-20 18:04:02 +01:00
3 changed files with 52 additions and 10 deletions

View File

@ -6,16 +6,9 @@ env:
global:
- secure: kPOwvkCDLpwJneCPeKUxbEZSsPWPpOpIK2wKf5Fm2BqJlUm+Wm8g5GZy1WHjo/IdNyb5mDIJzxWcr/uYDykehkNR1tRVrzUfRCVWqOFXGeI5P9e0zBaXp/GW3kfKivWNhpec8WSu9ZPjQhsRfDCjKRCHAB3JzwDWF8Kfl9UeBicFXQVRo+9zo3okRLsuJsEP/0MEtN0GxdsfKDleSW28AZLxu7raoJHHFY1t3QxMoYDd5312Pz7smv1/l4RG/P6XZZrtWEeVwctrNbU0CBO8tX8nqUCHA0bWyOW+crf4/NZZGg9e1RUq8eDbVUd7iGq81nr0+F7IvvwbvSLmpU2/b9hbcF4i4MpIE1Yy/0+zUhuTj1Yy8tw/irc8Y6Nc/g25BJBSCrfdPQnnbAESUv2ywbHC8vBztLca1xBQbQ+q0N0YYUK/mgxUiOznwTQ3PRIs/SENSdhFufT9pCRBp+lvkY+DVHSt6ogPYdRmyF/KPdcDWu5GqKrUs4KyroAzMLX/brw9+TjASnjTipnUWSlTQpoXjf1aQQuescqZMAbxEZH5ed6YvyPehdDqB8bpkeZ9OUkP8pV1kndSnnUsDH7Kn7ZyYUI20FNsU8Yqp1v94jOfrz2np2N9mJUT3teDy8k4yIxTERYSfbBcn4X30YX8fwRk/8skHRtgU4VOpUnIjkw=
script:
- npm install grunt grunt-cli grunt-contrib-clean grunt-regex-replace
- PATH="$PWD/node_modules/grunt-cli/bin:$PATH" grunt racket-mini
- git config --global user.name "Travis CI"
- git config --global user.email "travis@nobody.com"
- git add -A . &> /dev/null
- git rm -f .gitignore || true
- git rm -f Gruntfile.js || true
- git commit -m "auto-commit" &>/dev/null
- git log --oneline --decorate --graph -10
- git push --force --quiet "https://${GH_TOKEN}@github.com/jsmaniac/scribble-mathjax.git" HEAD:refs/heads/v2.6-racket-mini
- cp travis-auto-deploy.sh ~/travis-auto-deploy.sh
- sh ~/travis-auto-deploy.sh
branches:
only:
- v2.6-racket-mini-source
- v2.7.1-racket-mini-source

49
travis-auto-deploy.sh Normal file
View File

@ -0,0 +1,49 @@
#!/bin/sh
set -e
set +x
if test "$(git config remote.origin.url)" != "https://github.com/jsmaniac/scribble-mathjax.git"; then
echo "Not on official repo, will not deploy gh-pages."
elif test "$TRAVIS_PULL_REQUEST" != "false"; then
echo "This is a Pull Request, will not deploy gh-pages."
elif test "$TRAVIS_BRANCH" != "v2.6-racket-mini-source"; then
echo "Not on v2.6-racket-mini-source branch (TRAVIS_BRANCH = $TRAVIS_BRANCH), will not deploy gh-pages."
elif test -z "${encrypted_675a73236f08_key:-}" -o -z "${encrypted_675a73236f08_iv:-}"; then
echo "Travis CI secure environment variables are unavailable, will not deploy gh-pages."
else
set -x
echo "Automatic push to gh-pages"
ls -l /home/travis/build/jsmaniac/scribble-mathjax/.git/index.lock || true
# Git configuration:
git config --global user.name "$(git log --format="%aN" HEAD -1) (Travis CI automatic commit)"
git config --global user.email "$(git log --format="%aE" HEAD -1)"
# SSH configuration
mkdir -p ~/.ssh
chmod 700 ~/.ssh
set +x
if openssl aes-256-cbc -K $encrypted_675a73236f08_key -iv $encrypted_675a73236f08_iv -in travis-deploy-key-id_rsa.enc -out travis-deploy-key-id_rsa -d >/dev/null 2>&1; then
echo "Dectypred key successfully."
else
echo "Error while decrypting key."
fi
mv travis-deploy-key-id_rsa ~/.ssh/travis-deploy-key-id_rsa
set -x
chmod 600 ~/.ssh/travis-deploy-key-id_rsa
set +x
eval `ssh-agent -s`
set -x
ssh-add ~/.ssh/travis-deploy-key-id_rsa
npm install grunt grunt-cli grunt-contrib-clean grunt-regex-replace
PATH="$PWD/node_modules/grunt-cli/bin:$PATH" grunt racket-mini
git add -A . >/dev/null 2>&1
git rm -f .gitignore || true
git rm -f Gruntfile.js || true
git rm -f travis-deploy-key-id_rsa.enc || true
git rm -f travis-auto-deploy.sh || true
git commit -m "auto-commit" >/dev/null 2>&1
git log --oneline --decorate --graph -10
git push --force --quiet "git@github.com:jsmaniac/scribble-mathjax.git" HEAD:refs/heads/v2.6-racket-mini > /dev/null 2>&1
fi

Binary file not shown.