Skip to content

Commit

Permalink
improvement(CI): Adds Doxyfile documentation generator
Browse files Browse the repository at this point in the history
* Adds Doxygen build and pages deploy
  • Loading branch information
rgcouto committed Jul 18, 2023
1 parent 88305d4 commit 3bec966
Showing 1 changed file with 40 additions and 1 deletion.
41 changes: 40 additions & 1 deletion .github/workflows/pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -84,4 +84,43 @@ jobs:
dotnet pack -o output_package /p:Version=$NUGET_VERSION
- name: Publish NuGet Package
run: dotnet nuget push output_package/*.nupkg --api-key ${{ secrets.NUGET_API_KEY }} --source https://api.nuget.org/v3/index.json
run: dotnet nuget push output_package/*.nupkg --api-key ${{ secrets.NUGET_API_KEY }} --source https://api.nuget.org/v3/index.json

pages:
runs-on: ubuntu-latest
needs: test
if: github.event_name == 'release' && startsWith(github.ref, 'refs/tags/')
steps:
- name: Check Tag Pattern
run: |
if [[ "${{ github.ref }}" =~ refs/tags/[0-9]+\.[0-9]+\.[0-9]+ ]]; then
echo "Publishing tag ${{ github.ref }}"
else
echo "Skipping job as the tag does not match the pattern X.Y.Z"
exit 1
fi
- name: Checkout repository
uses: actions/checkout@v3

- name: Setup Pages
uses: actions/configure-pages@v3

- name: Install Doxygen
run: sudo apt update && sudo apt install -y doxygen graphviz

- name: Build Doxyfile documentation
run: |
DOCKER_VERSION=$(echo "${{ github.ref }}" | sed 's/refs\/tags\///')
(cat Doxyfile; echo "PROJECT_NUMBER=$DOCKER_VERSION") | doxygen - > /dev/null
- name: Configure Git
run: |
git config --global user.name "${GITHUB_ACTOR}"
git config --global user.email "${GITHUB_ACTOR}@users.noreply.github.com"
- name: Push documentation to gh-pages branch
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./doxydocs/html

0 comments on commit 3bec966

Please sign in to comment.