forked from synthetichealth/synthea
-
Notifications
You must be signed in to change notification settings - Fork 0
/
deploy.sh
34 lines (24 loc) · 831 Bytes
/
deploy.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#!/bin/bash
# --------------------------------------------------------------------------
# This script deploys rendered graphs of the Synthea modules to github pages
# --------------------------------------------------------------------------
set -o errexit -o nounset
if [ "$TRAVIS_BRANCH" != "master" ]
then
echo "Skipping publication of module graphs for non-master branches."
exit 0
fi
rev=$(git rev-parse --short HEAD)
./gradlew graphviz
cd output
git init
git config user.name "Jason Walonoski"
git config user.email "[email protected]"
git remote add upstream "https://[email protected]/synthetichealth/synthea.git"
git fetch upstream
git reset upstream/gh-pages
# echo "synthea.org" > CNAME
touch graphviz
git add -A graphviz/
git commit -m "rebuild graphs at ${rev}"
git push -q upstream HEAD:gh-pages