-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
build: add pages workflow to deploy docs to github pages
- Loading branch information
Richard Pospesel
committed
Jul 2, 2023
1 parent
19cee15
commit 477605f
Showing
1 changed file
with
39 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
name: pages | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Gosling | ||
uses: actions/checkout@v3 | ||
with: | ||
submodules: true | ||
- name: Install Dependencies | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install -y libboost-all-dev | ||
cargo install cargo-tarpaulin | ||
sudo apt-get install -y doxygen | ||
- name: Build Docs | ||
run: | | ||
make docs | ||
- name: Build Code Coverage | ||
run: | | ||
make coverage-offline | ||
- name: Move Outputs | ||
run: | | ||
mkdir pages | ||
mv out/release/gosling/crates/gosling-ffi/html pages/libcgosling | ||
mv out/release/gosling/crates/doc pages/gosling | ||
mv out/release/gosling/tarpaulin-offline pages/coverage | ||
ln -s tarpaulin-report.html pages/coverage/index.html | ||
- name: Deploy to Github Pages | ||
uses: peaceiris/actions-gh-pages@v3 | ||
with: | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
publish_dir: pages |