ci: adopt reusable workflows from `named-data/actions`
Change-Id: Iefd142d82f56a6fb83c5039565b6eba83c6e6445
diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml
index e566385..915954c 100644
--- a/.github/workflows/docs.yml
+++ b/.github/workflows/docs.yml
@@ -5,33 +5,23 @@
- '*.md'
- '.mailmap'
workflow_dispatch:
+ inputs:
+ skip-deploy:
+ description: 'Skip deployment?'
+ required: true
+ type: boolean
-permissions:
- contents: read
+permissions: {}
jobs:
- build:
- runs-on: ${{ matrix.os }}
- strategy:
- fail-fast: false
- matrix:
- os: [macos-latest, ubuntu-latest]
- env:
- JOB_NAME: Docs
- steps:
- - name: Checkout
- uses: actions/checkout@v3
- with:
- submodules: true
- - name: Install dependencies
- run: |
- find .jenkins.d/ -type f -name '[1-9]*.sh' -exec chmod -x '{}' +
- ./.jenkins
- - name: Build documentation
- run: |
- pybindir=$(python3 -c 'import sysconfig; print(sysconfig.get_path("scripts", "posix_user"))')
- export PATH="${pybindir}${PATH:+:}${PATH}"
- ./waf --color=yes configure
- ./waf --color=yes build --targets=version.hpp
- ./waf --color=yes build --targets=manpages
- ./waf --color=yes docs
+ html:
+ uses: named-data/actions/.github/workflows/docs-html.yml@v1
+ with:
+ submodules: true
+ # Deploy only the master branch and release tags
+ deploy: ${{ !inputs.skip-deploy && (github.ref == 'refs/heads/master' || startsWith(github.ref, 'refs/tags/NFD-')) }}
+ secrets: inherit
+ man:
+ uses: named-data/actions/.github/workflows/docs-man.yml@v1
+ with:
+ submodules: true