-
Notifications
You must be signed in to change notification settings - Fork 4
47 lines (45 loc) · 1.56 KB
/
ghpages.yml
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
name: Doxygen CI
on:
push:
branches: [master]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: true
- name: Install requirements
run: |
sudo apt-get update
sudo apt-get install -y libboost-all-dev cmake doxygen
- name: Create build directory
run: mkdir build-debug-generators
- name: Configure
run: cd build-debug-generators && cmake .. -DCMAKE_BUILD_TYPE=Debug -DGENERATORS=on
- name: Compile
run: cd build-debug-generators && make
- name: Test
env:
CTEST_OUTPUT_ON_FAILURE: 1
run: cd build-debug-generators && make test
- name: Create documentation
run: cd build-debug-generators && make doc
- name: Cleanup submodules
run: git reset --hard HEAD && git submodule sync && git submodule deinit -f . || true
- name: Checkout gh-pages
uses: actions/checkout@v4
with:
ref: "gh-pages"
clean: false
- name: Move and commit files
run: |
git config --global user.name github-actions
git config --global user.email '${GITHUB_ACTOR}@users.noreply.github.com'
git remote set-url origin https://x-access-token:${{ secrets.DEPLOY_TOKEN }}@github.com/$GITHUB_REPOSITORY
cp -rp ./build-debug-generators/doc/html/* .
rm -rf ./build-debug-generators
ls -lah
git add .
git commit -m "Documentation for $GITHUB_SHA" || true
git push --force || true