forked from marianogappa/ostinato
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.sh
executable file
·57 lines (40 loc) · 907 Bytes
/
build.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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
#!/usr/bin/env bash
# Quit on first error
set -eu
VERSION=$(./version.sh)
echo
echo "Require envs set"
: "${WORKSPACE?WORKSPACE env not set}"
: "${HOME?HOME env not set}"
: "${VERSION?VERSION not set}"
echo
echo "Clean Ivy Cache"
rm -rf "$HOME"/.ivy2/local/org.gappa
cd "$WORKSPACE"/ostinato
echo
echo "Build binaries/compiled versions"
sbt test
sbt clean
sbt publishLocal
sbt fullOptJS
cd -
echo
echo "Update & push to ostinato-example repo"
cd "$WORKSPACE"/ostinato-example
git pull --rebase
git pull --rebase
cp "$WORKSPACE"/ostinato/js/target/scala-2.12/ostinato-opt.js ostinato.js
git commit -am "Updates library."
git push
cd -
echo
echo "Update & push to nowinalgebraic repo"
cd "$WORKSPACE"/nowinalgebraic
git pull --rebase
git pull --rebase
cp "$WORKSPACE"/ostinato/js/target/scala-2.12/ostinato-opt.js ostinato.js
git commit -am "Updates library."
git push
cd -
echo
echo "Done!"