File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1- language : go
2- install :
3- - export HUGO_VERSION=0.20
4- - export HUGO_PACKAGE=hugo_${HUGO_VERSION}_Linux-64bit
5- - curl -L https://github.com/spf13/hugo/releases/download/v$HUGO_VERSION/$HUGO_PACKAGE.tar.gz | tar xz
6- - mkdir $HOME/bin
7- - mv ./hugo_${HUGO_VERSION}_linux_amd64/hugo_${HUGO_VERSION}_linux_amd64 $HOME/bin/hugo
8- script :
9- - rm -rf docs
10- - cd DOCUMENTATION/_settings
11- - hugo
1+ language : bash
2+ sudo : required
3+ services :
4+ - docker
5+
6+ env :
7+ matrix :
8+ - PHP_VERSION=56
9+ - PHP_VERSION=70
10+ - PHP_VERSION=71
11+ - HUGO_VERSION=0.20
12+
13+ script : ./scripts/build.sh
1214
1315deploy :
1416 provider : pages
1517 skip_cleanup : true
16- local_dir : public
18+ local_dir : ../../docs
1719 github_token : $GITHUB_TOKEN
1820 on :
1921 branch : master
22+ condition : " -n ${HUGO_VERSION}"
2023
2124notifications :
2225 email : false
Original file line number Diff line number Diff line change 1+ #! /usr/bin/env bash
2+
3+ if [ -n ${PHP_VERSION} ]; then
4+ cp env-example .env
5+ docker-compose build
6+ docker images
7+ fi
8+
9+ if [ -n ${HUGO_VERSION} ]; then
10+ HUGO_PACKAGE=hugo_${HUGO_VERSION} _Linux-64bit
11+ HUGO_BIN=hugo_${HUGO_VERSION} _linux_amd64
12+
13+ # Download hugo binary
14+ curl -L https://github.com/spf13/hugo/releases/download/v$HUGO_VERSION /$HUGO_PACKAGE .tar.gz | tar xz
15+ mkdir $HOME /bin
16+ mv ./${HUGO_BIN} /${HUGO_BIN} $HOME /bin/hugo
17+
18+ # Remove existing docs
19+ rm -r ./docs
20+
21+ # Build docs
22+ cd DOCUMENTATION/_settings
23+ hugo
24+ fi
You can’t perform that action at this time.
0 commit comments