Skip to content

docs: clarify forget.keep- value 0 doesn't remove snapshots (#526) #460

docs: clarify forget.keep- value 0 doesn't remove snapshots (#526)

docs: clarify forget.keep- value 0 doesn't remove snapshots (#526) #460

Workflow file for this run

name: Documentation Build
on:
workflow_dispatch:
push:
branches:
- master
paths:
- "docs/**"
pull_request:
types: [opened, synchronize, reopened]
paths:
- 'docs/**'
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: true # Fetch Hugo themes (true OR recursive)
fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: ~1.25
- name: Check configuration snippets in documentation
run: go run ./config/checkdoc -r docs/content -i changelog.md
shell: bash
- name: Build JSON schema & config reference
run: make generate-jsonschema generate-config-reference
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Setup Hugo
uses: peaceiris/actions-hugo@v3
with:
hugo-version: '0.150.1'
extended: true
- name: Build
run: |
cd docs
sed -i "s/canonifyURLs = true/canonifyURLs = false/g" hugo.toml
export BRANCH_NAME=$(echo ${GITHUB_REF_NAME} | tr / -)
echo "BRANCH_NAME=${BRANCH_NAME}" >> "$GITHUB_ENV"
hugo --minify --baseURL https://${BRANCH_NAME}.resticprofile.pages.dev/
- name: Check broken links
uses: ruzickap/action-my-broken-link-checker@v2
with:
url: "https://${{ env.BRANCH_NAME }}.resticprofile.pages.dev/"
pages_path: ./public/
cmd_params: '--exclude="(linux\.die\.net|scoop\.sh|commit)" --buffer-size=8192 --max-connections-per-host=8 --rate-limit=20 --color=always --skip-tls-verification --header="User-Agent: Muffet/2.10.8" --timeout=20'
- name: Publish to pages.dev
continue-on-error: true # secrets are not set for PRs from forks
uses: cloudflare/pages-action@v1
with:
apiToken: ${{ secrets.CF_API_TOKEN }}
accountId: ${{ secrets.CF_ACCOUNT_ID }}
projectName: 'resticprofile'
directory: 'public'
gitHubToken: ${{ secrets.GITHUB_TOKEN }}
branch: ${{ github.ref_name }}