feat(tricks): auto-create fish-config.1 symlink on shell start
Offline docs drift reminder / remind (push) Failing after 3s
Generate man page / build-manpage (push) Successful in 16s

The symlink from ~/.local/share/man/man1/fish-config.1 to
docs/fish-config.1 is now created automatically alongside the
existing MANPATH setup, making `man fish-config` work out of the
box on any machine after cloning. Simplified docs accordingly.
This commit is contained in:
2026-06-06 04:37:54 -04:00
parent b2dd199e2f
commit 4117b0ddb6
3 changed files with 15 additions and 9 deletions
+7 -1
View File
@@ -17,10 +17,16 @@ end
fish_add_path ~/.local/bin
fish_add_path ~/Applications/depot_tools
# Expose user-local man pages (e.g. fish-config.1 symlinked from docs/)
# Expose user-local man pages and keep fish-config.1 symlink current
if not contains ~/.local/share/man $MANPATH
set -gx MANPATH ~/.local/share/man $MANPATH
end
set -l _man1 ~/.local/share/man/man1
set -l _src ~/.config/fish/docs/fish-config.1
if test -f $_src; and not test -L $_man1/fish-config.1
mkdir -p $_man1
ln -sf $_src $_man1/fish-config.1
end
# Format man pages using bat (only if bat is installed)
if type -q bat