Skip to content

Commit

Permalink
Create Doxygen documentation on PR as artifact (#164)
Browse files Browse the repository at this point in the history
* Split doxygen in two jobs

* try test upload

* fix name

* add checkout action

* only upload on push to master
  • Loading branch information
phbasler authored Sep 4, 2024
1 parent 7302d69 commit 54fe4b4
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 8 deletions.
33 changes: 26 additions & 7 deletions .github/workflows/doc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,19 @@ name: Doxygen Deploy

on:
push:
branches: [ master ]
branches:
- master
pull_request:
branches:
- master

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true


jobs:
Deploy:
CreateDocumentation:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand All @@ -34,9 +38,24 @@ jobs:
- run: python3 Setup.py --build-missing
- run: cmake --preset conan-linux-x86_64-release
- run: cmake --build --preset conan-linux-x86_64-release -j${{ steps.cpu-cores.outputs.count }} -t doc
- name: Deploy
uses: JamesIves/[email protected]
- uses: actions/upload-artifact@v4
with:
branch: gh-pages # The branch the action should deploy to.
folder: build/linux-x86_64-release/html # The folder the action should deploy.
target-folder: documentation
path: build/linux-x86_64-release/html
name: documentation

UploadDocumentation:
if: github.event_name == 'push' && github.ref == 'refs/heads/master'
needs: CreateDocumentation
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/download-artifact@v4
with:
name: documentation
path: documentation
- name: Deploy
uses: JamesIves/[email protected]
with:
branch: gh-pages # The branch the action should deploy to.
folder: documentation # The folder the action should deploy.
target-folder: documentation
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ Program: BSMPT version 3.0.7

Released by: Philipp Basler, Lisa Biermann, Margarete Mühlleitner, Jonas Müller, Rui Santos and João Viana

[!["GitHub Discussions"](https://img.shields.io/badge/%20GitHub-%20Discussions-gray.svg?longCache=true&logo=github&colorB=purple)](https://github.com/phbasler/BSMPT/discussions)
[![GitHub Discussions](https://img.shields.io/badge/%20GitHub-%20Discussions-gray.svg?longCache=true&logo=github&colorB=purple)](https://github.com/phbasler/BSMPT/discussions)
[![Unit tests](https://github.com/phbasler/BSMPT/actions/workflows/test.yml/badge.svg?branch=master)](https://github.com/phbasler/BSMPT/actions/workflows/test.yml)
[![codecov master](https://codecov.io/gh/phbasler/BSMPT/branch/master/graph/badge.svg?token=LDGNQTADB5)](https://codecov.io/gh/phbasler/BSMPT)
[![Documentation](https://img.shields.io/badge/Documentation-master-success)][DoxygenLink]
Expand Down

0 comments on commit 54fe4b4

Please sign in to comment.