Update deploy-script in documentation (#6666)

Merge pull request 6666
This commit is contained in:
ashmaroli 2018-01-15 03:08:17 +05:30 committed by jekyllbot
parent 1dc0702e29
commit 2cb5375519
1 changed files with 4 additions and 2 deletions

View File

@ -66,13 +66,15 @@ server$ mkdir /var/www/myrepo
Next, add the following lines to hooks/post-receive and be sure Jekyll is Next, add the following lines to hooks/post-receive and be sure Jekyll is
installed on the server: installed on the server:
```sh ```bash
GIT_REPO=$HOME/myrepo.git GIT_REPO=$HOME/myrepo.git
TMP_GIT_CLONE=$HOME/tmp/myrepo TMP_GIT_CLONE=$HOME/tmp/myrepo
GEMFILE=$TMP_GIT_CLONE/Gemfile
PUBLIC_WWW=/var/www/myrepo PUBLIC_WWW=/var/www/myrepo
git clone $GIT_REPO $TMP_GIT_CLONE git clone $GIT_REPO $TMP_GIT_CLONE
bundle exec jekyll build -s $TMP_GIT_CLONE -d $PUBLIC_WWW BUNDLE_GEMFILE=$GEMFILE bundle install
BUNDLE_GEMFILE=$GEMFILE bundle exec jekyll build -s $TMP_GIT_CLONE -d $PUBLIC_WWW
rm -Rf $TMP_GIT_CLONE rm -Rf $TMP_GIT_CLONE
exit exit
``` ```