Skip to content

FAIRSPC-87: added workflow to Build and deploy docs to Github Pages a… #22

FAIRSPC-87: added workflow to Build and deploy docs to Github Pages a…

FAIRSPC-87: added workflow to Build and deploy docs to Github Pages a… #22

# This workflow is triggered on any PR's changes
name: Build and deploy docs to Github Pages
on:
push:
branches:
- bugfix/FAIRSPC-87
jobs:
build-saturn:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Log details
run: |
BRANCH=${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}}
echo "Triggered on branch: $BRANCH"
- name: Set up Ruby (required for gem installation)
uses: ruby/setup-ruby@v1
with:
ruby-version: '2.7'
- name: Install Asciidoctor to build docs
run: |
gem install asciidoctor
gem install asciidoctor-pdf
gem install rouge
- name: Run Build Docs script
run: ./docs/scripts/build.sh
- name: Run Deploy Docs script
env:
CI_SERVICE_ACCOUNT_USER: ${{ secrets.CI_SERVICE_ACCOUNT_USER }}
CI_SERVICE_ACCOUNT_PASSWORD: ${{ secrets.FNS_PAT }}
DOCUMENTATION_REPO: ${{ vars.DOCUMENTATION_REPO }}
run: ./docs/scripts/deploy.sh