Skip to content

Commit

Permalink
ci: Hopefully push the "docs" to Github Pages
Browse files Browse the repository at this point in the history
  • Loading branch information
alcarney committed Jan 20, 2024
1 parent 1b9c548 commit d14970d
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 1 deletion.
28 changes: 28 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,26 @@ on:
branches:
- main

# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write

# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
concurrency:
group: "pages"
cancel-in-progress: false

jobs:
docs:
runs-on: ubuntu-latest

environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}

steps:
- uses: actions/checkout@v4

Expand All @@ -21,8 +37,20 @@ jobs:
run: |
nix build .
- name: Setup Pages
uses: actions/configure-pages@v4

- name: 'Upload Artifact'
uses: actions/upload-artifact@v4
with:
name: 'out'
path: result/

- name: Upload pages content
uses: actions/upload-pages-artifact@v3
with:
path: result/

- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
2 changes: 1 addition & 1 deletion docs/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,6 @@ stdenv.mkDerivation {
buildCommand = ''
mkdir $out
${awdur}/bin/awdur bind "$src/index.rst"
cp out.html $out
cp out.html $out/index.html
'';
}

0 comments on commit d14970d

Please sign in to comment.