docs: Deploy both stable & unstable docs to github pages

This commit is contained in:
traxys 2024-05-21 19:40:23 +02:00
parent 1c9f2a23a6
commit b0b010a0e9
3 changed files with 13 additions and 2 deletions

View file

@ -44,12 +44,12 @@ jobs:
name: nix-community
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}'
- run: nix build .#docs --show-trace
- run: ./build-docs.sh
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: "result/share/doc"
path: "docs-build"
- name: Deploy to GitHub Pages
id: deployment

View file

@ -233,6 +233,8 @@ be.
Documentation is available on this project's GitHub Pages page:
[https://nix-community.github.io/nixvim](https://nix-community.github.io/nixvim)
The stable documentation is also available at [https://nix-community.github.io/nixvim/stable](https://nix-community.github.io/nixvim/stable).
If the option `enableMan` is set to `true` (by default it is), man pages will also
be installed containing the same information, they can be viewed with `man nixvim`.

9
build-docs.sh Executable file
View file

@ -0,0 +1,9 @@
#!/usr/bin/env sh
set -ex
mkdir -p docs-build
nix build github:nix-community/nixvim#docs
cp -r result/share/doc docs-build
nix build github:nix-community/nixvim/nixos-23.11#docs
cp -r result/share/doc docs-build/stable