mirror of
https://github.com/nix-community/nixvim.git
synced 2025-07-22 11:45:28 +02:00
docs: specify site-url
Fixes 404 page's relative links and styling being relative to `/`.
This commit is contained in:
parent
4ea34656c2
commit
a92339d83b
2 changed files with 11 additions and 0 deletions
|
@ -321,6 +321,10 @@ pkgs.stdenv.mkDerivation (finalAttrs: {
|
|||
cp "$file" "$path"
|
||||
done
|
||||
|
||||
# Patch book.toml
|
||||
substituteInPlace ./book.toml \
|
||||
--replace-fail "@SITE_URL@" "$siteURL"
|
||||
|
||||
# Patch SUMMARY.md - which defiens mdBook's table of contents
|
||||
substituteInPlace ./SUMMARY.md \
|
||||
--replace-fail "@PLATFORM_OPTIONS@" "$wrapperOptionsSummary" \
|
||||
|
@ -332,6 +336,10 @@ pkgs.stdenv.mkDerivation (finalAttrs: {
|
|||
cp -r ${search}/* $dest/search
|
||||
'';
|
||||
|
||||
# The root directory of the site
|
||||
# Can be overridden, e.g. by CI
|
||||
siteURL = "/nixvim/";
|
||||
|
||||
inherit (mdbook)
|
||||
nixvimOptionsSummary
|
||||
wrapperOptionsSummary
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue