-
Notifications
You must be signed in to change notification settings - Fork 0
/
deploy.sh
executable file
·34 lines (28 loc) · 986 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
set -e # stop when failed
RSYNC_OPTS="-lrv --delete --exclude=Gemfile* --exclude=bin"
if [ $# -ne 1 ]; then
echo "please use $0 [jus|jus-localhost|smellman]"
exit 1
fi
if [ $1 = "jus" ]; then
echo "deploy to ll.jus.or.jp/2013"
rm -fr ../deploy/ll.jus
bundle exec jekyll --base-url http://ll.jus.or.jp/2013 ../deploy/ll.jus
rsync $RSYNC_OPTS ../deploy/ll.jus/ ll.jus.or.jp:/usr/local/docs/ll.jus.or.jp/llweb/2013
exit $?
fi
if [ $1 = "jus-localhost" ]; then
echo "deploy to ll.jus.or.jp/2013"
rm -fr ../deploy/ll.jus
bundle exec jekyll --base-url http://ll.jus.or.jp/2013 ../deploy/ll.jus
rsync $RSYNC_OPTS ../deploy/ll.jus/ /usr/local/docs/ll.jus.or.jp/llweb/2013
exit $?
fi
if [ $1 = "smellman" ]; then
echo "deploy to ll2013.smellman.org"
rm -fr ../deploy/smellman.org
bundle exec jekyll --base-url http://ll2013.smellman.org ../deploy/smellman.org
rsync $RSYNC_OPTS ../deploy/smellman.org/ synthamesk:/home/nginx/ll2013
exit $?
fi