forked from NOAA-GFDL/FMS
-
Notifications
You must be signed in to change notification settings - Fork 4
30 lines (29 loc) · 1.1 KB
/
update_docs.yml
File metadata and controls
30 lines (29 loc) · 1.1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
name: Generate and deploy documentation on GH pages
# update on releases or when triggered manually(must have write access)
on:
release:
types: [published]
workflow_dispatch:
jobs:
update_docs:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Setup repo
run: | # do autotool's job for substitutes since we don't need a full build environement
mkdir gen_docs
sed 's/@abs_top_builddir@\/docs/gen_docs/g' docs/Doxyfile.in > gen_docs/Doxyfile
sed -i 's/@abs_top_srcdir@/./g' gen_docs/Doxyfile
# grab version number from configure.ac
export VER="`awk '/AC_INIT/{getline;print}' configure.ac | cut -d "[" -f2 | cut -d "]" -f1`"
sed -i "s/@PACKAGE_VERSION@/$VER/g" gen_docs/Doxyfile
- name: Install and run doxygen
run: |
sudo apt -y install doxygen graphviz
doxygen gen_docs/Doxyfile
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./gen_docs/html