Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 6 additions & 9 deletions build_tools/ci.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ echo "--- installing dependencies"
dnf install findutils git make ruby rubygems -y
gem install --no-document --minimal-deps asciidoctor

# get the current working branch, if we're master, we'll end up pushing new docs
# get the current working branch, if we're stable-1.5, we'll end up pushing new docs
echo "--- current working branch is $BRANCH"

echo "--- building documentation"
Expand Down Expand Up @@ -37,21 +37,18 @@ rm -rf images/
echo "--- moving built files into the top-level directory"
touch .nojekyll
mv build/doc-Service-Telemetry-Framework/* ./
mv index-upstream.html index.html
rm -rf build/

# Add everything, get ready for commit. But only do it if we're on
# master. If you want to deploy on different branches, you can change
# this.
if [[ "$BRANCH" =~ ^master$|^[0-9]+\.[0-9]+\.X$ ]]; then
echo "Branch is master, so pushing docs to gh-pages"
# Build this for stable-1.5 branch and push custom paths to gh-pages
if [[ "$BRANCH" =~ ^stable-1\.5$ ]]; then
echo "Branch is stable-1.5, so pushing docs to gh-pages"
git add --all
git commit -am '[ci skip] publishing updated documentation...'
git commit -am '[ci skip] publishing updated documentation for STF 1.5...'

git remote rm origin
git remote add origin https://$GH_NAME:$GH_TOKEN@github.com/infrawatch/documentation.git

git push origin gh-pages
else
echo "Not on master, so won't push doc"
echo "Not on stable-1.5, so won't push doc"
fi
8 changes: 4 additions & 4 deletions doc-Service-Telemetry-Framework/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ BUILD_DIR = ../build
ROOTDIR = $(realpath .)
NAME = $(notdir $(ROOTDIR))
DEST_DIR = $(BUILD_DIR)/$(NAME)
DEST_HTML = $(DEST_DIR)/index-$(BUILD).html
DEST_HTML_170 = $(DEST_DIR)/index-$(BUILD)-170.html
DEST_HTML_162 = $(DEST_DIR)/index-$(BUILD)-162.html
DEST_HTML_13 = $(DEST_DIR)/index-$(BUILD)-13.html
DEST_HTML = $(DEST_DIR)/index-1-5-$(BUILD).html
DEST_HTML_170 = $(DEST_DIR)/index-1-5-$(BUILD)-170.html
DEST_HTML_162 = $(DEST_DIR)/index-1-5-$(BUILD)-162.html
DEST_HTML_13 = $(DEST_DIR)/index-1-5-$(BUILD)-13.html
DEST_PDF = $(BUILD_DIR)/$(NAME)-$(BUILD).pdf
IMAGES_DIR = $(DEST_DIR)/images
IMAGES_TS = $(DEST_DIR)/.timestamp-images
Expand Down