neighbors #1000
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: github pages | |
on: | |
push: | |
branches: | |
- master # Set a branch to deploy | |
jobs: | |
deploy: | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
submodules: recursive # Fetch Hugo themes (true OR recursive) | |
fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod | |
- uses: cachix/install-nix-action@v12 | |
with: | |
nix_path: nixpkgs=channel:nixos-unstable | |
- run: nix-shell --run 'echo "Installed nix dependencies"' | |
- name: Install assets | |
run: nix-shell --run 'cd themes/hugo-darktable-docs-theme/assets/ && yarn install' | |
- name: Run linkchecker | |
run: nix-shell --run 'hugo server --disableFastRender -verbose --config config.yaml -b https://darktable-org.github.io/dtdocs/ & sleep 30 && linkchecker --ignore-url .*pdf$ --ignore-url .*epub$ --no-status http://localhost:1313/dtdocs/index.html && pkill hugo' | |
- name: build site | |
run: nix-shell --run './tools/build-all.sh https://darktable-org.github.io/dtdocs/' | |
- name: Deploy | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: ./public | |
force_orphan: true |