Skip to content

Commit

Permalink
use "modern" github pages action
Browse files Browse the repository at this point in the history
  • Loading branch information
jkuball committed Dec 24, 2024
1 parent 335b415 commit a946088
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 8 deletions.
7 changes: 4 additions & 3 deletions .github/workflows/book.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,11 @@ jobs:
- uses: nixbuild/nix-quick-install-action@v29
- run: nix develop .#book -c mdbook build ./.
- if: ${{ github.ref == 'refs/heads/main' }}
uses: peaceiris/actions-gh-pages@v4
uses: actions/upload-pages-artifact@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./docs/book
path: ./docs/book/
- if: ${{ github.ref == 'refs/heads/main' }}
uses: actions/deploy-pages@v4
name: Deploy to GitHub Pages
'on':
push:
Expand Down
11 changes: 6 additions & 5 deletions cells/repository/configs.nix
Original file line number Diff line number Diff line change
Expand Up @@ -37,12 +37,13 @@ in
{ uses = "nixbuild/nix-quick-install-action@v29"; }
{ run = "nix develop .#book -c mdbook build ./."; }
{
uses = "peaceiris/actions-gh-pages@v4";
"if" = "\${{ github.ref == 'refs/heads/main' }}";
"with" = {
"github_token" = "\${{ secrets.GITHUB_TOKEN }}";
"publish_dir" = "./docs/book";
};
uses = "actions/upload-pages-artifact@v3";
"with".path = "./docs/book/";
}
{
"if" = "\${{ github.ref == 'refs/heads/main' }}";
uses = "actions/deploy-pages@v4";
}
];
};
Expand Down

0 comments on commit a946088

Please sign in to comment.