diff options
author | Egor Tensin <Egor.Tensin@gmail.com> | 2022-03-10 12:51:15 +0500 |
---|---|---|
committer | Egor Tensin <Egor.Tensin@gmail.com> | 2022-03-10 13:14:29 +0500 |
commit | 232cb5b1c678ae52133904779b288a436ef36522 (patch) | |
tree | be0c369b123bdb2aeb8e724ebae322027b67ba68 | |
parent | add Doxygen docs (diff) | |
download | winapi-common-232cb5b1c678ae52133904779b288a436ef36522.tar.gz winapi-common-232cb5b1c678ae52133904779b288a436ef36522.zip |
workflows/ci: publish docs to GitHub Pages
Diffstat (limited to '')
-rw-r--r-- | .github/workflows/ci.yml | 46 | ||||
-rw-r--r-- | Makefile | 2 | ||||
-rw-r--r-- | README.md | 2 |
3 files changed, 50 insertions, 0 deletions
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 3f49eb1..10daeee 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -85,3 +85,49 @@ jobs: ${{ runner.workspace }}/build/**/*_report.txt if-no-files-found: error if: always() && runner.os == 'Windows' + + docs: + needs: [lint, build] + runs-on: ubuntu-latest + name: Docs + if: github.ref == 'refs/heads/master' + env: + TOOLSET: mingw + PLATFORM: auto + CONFIGURATION: Debug + BOOST_VERSION: 1.65.0 + CMAKE_FLAGS: -D WINAPI_COMMON_TESTS=OFF + steps: + # This is rather stupid. In order to build Doxygen docs, I need a working + # CMake build directory, so I assume that means I need to pretty much + # build the project. TODO: research if this is possible without having a + # Doxyfile. + - name: Checkout + uses: actions/checkout@v2 + with: + submodules: recursive + - name: Cache Boost + uses: actions/cache@v2 + with: + path: '${{ runner.workspace }}/build/boost_*.tar.gz' + key: 'boost_${{ env.BOOST_VERSION }}' + - name: Set up Python + uses: actions/setup-python@v2 + - name: Set up MinGW + uses: egor-tensin/setup-mingw@v2 + - name: Install Doxygen + run: | + sudo apt-get update + sudo DEBIAN_FRONTEND=noninteractive apt-get install -yq --no-install-recommends doxygen + - name: Build Boost + run: make deps + - name: Build + run: make install + - name: Build docs + run: make docs + - name: Publish to GitHub Pages + uses: JamesIves/github-pages-deploy-action@4.1.5 + with: + branch: gh-pages + folder: ../build/cmake/html + single-commit: true @@ -85,9 +85,11 @@ xdg-open := $(shell command -v xdg-open 2> /dev/null) .PHONY: docs docs: cmake --build '$(call escape,$(cmake_dir))' --target docs +ifndef CI ifdef xdg-open xdg-open '$(call escape,$(cmake_dir))/html/index.html' &> /dev/null endif +endif clang-tidy := run-clang-tidy ifeq (1,$(shell test -e /usr/share/clang/run-clang-tidy.py && echo 1)) @@ -28,6 +28,8 @@ Build & display the documentation using make docs +View the online documentation at https://egor-tensin.github.io/winapi-common/. + License ------- |