Skip to content

Merge pull request #100 from apiman/dependabot/npm_and_yarn/_sass/boo… #65

Merge pull request #100 from apiman/dependabot/npm_and_yarn/_sass/boo…

Merge pull request #100 from apiman/dependabot/npm_and_yarn/_sass/boo… #65

name: Build New Apiman Website
on:
push:
branches: [ "master" ]
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Set up Homebrew
id: set-up-homebrew
uses: Homebrew/actions/setup-homebrew@master
- name: Install minify
run: |
brew install tdewolff/tap/minify
sudo apt-get update
sudo apt-get install graphviz
- uses: actions/checkout@v3
- name: Setup Ruby
uses: ruby/[email protected]
with:
ruby-version: '3.1.2'
bundler-cache: true
- name: Setup Node.js environment
uses: actions/[email protected]
with:
node-version: 19
- name: Build site
run: |
bundle exec jekyll build
- name: Optimise site
run: |
minify --sync --all --recursive --html-keep-default-attrvals --html-keep-document-tags --html-keep-quotes --html-keep-whitespace --xml-keep-whitespace --verbose --output=docs/ _site/
# Skip qmino apidocs as its angularjs app does not work properly with minification.
cp -rf _site/api-docs/ docs/
- name: Commit generated website
uses: EndBug/[email protected]
with:
message: "Regenerate apiman.github.io"
add: -A
push: false
- name: Push to `serve` branch
run: git push origin HEAD:serve -f