From bc367e7814255d5246196aaa7f40d0f099faa5bc Mon Sep 17 00:00:00 2001 From: Andy Pack Date: Tue, 30 Jan 2024 21:58:09 +0000 Subject: [PATCH] adding docs generation --- .github/workflows/build.yml | 24 +++++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 1e43275..0dd2d21 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -31,4 +31,26 @@ jobs: - name: Cargo Test uses: actions-rs/cargo@v1 with: - command: test \ No newline at end of file + command: test + + doc: + runs-on: ubuntu-latest + needs: [ build ] # for ignoring bad builds + if: github.event_name == 'push' && github.ref == 'refs/heads/master' + steps: + - name: Checkout + uses: actions/checkout@v3 + + - name: Install Rust + uses: actions-rs/toolchain@v1 + with: + toolchain: stable + + - name: Build Docs + run: cargo doc --no-deps --document-private-items + + - name: Deploy To Pages + uses: peaceiris/actions-gh-pages@v3 + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + publish_dir: ./target/doc \ No newline at end of file