Skip to content

Install manpages from selected version#20

Open
quinnyo wants to merge 1 commit intogbdev:masterfrom
quinnyo:manpage-management
Open

Install manpages from selected version#20
quinnyo wants to merge 1 commit intogbdev:masterfrom
quinnyo:manpage-management

Conversation

@quinnyo
Copy link

@quinnyo quinnyo commented Jan 17, 2026

Changes rgbenv to make the man pages for the selected rgbds version detectable by man-db.

How it works:

  • Creates directory $RGBENV_DEFAULT/man -- this will get automatically searched by man-db, provided $RGBENV_DEFAULT/bin is in PATH.
  • Selected rgbds directory is searched for pages (files with extensions matching the man section numbers).
    • This is a search (find) because different versions of rgbds have different pages, filenames, layouts, etc.
  • The detected pages are symlinked to corresponding man section dir in $RGBENV_DEFAULT/man/man{1,5,7}

I've been installing man pages on Arch and Debian in this way for many years without an issue, but I'm not necessarily an expert on the topic. More to the point, I'm not aware of what exists outside of man-db and this is only intended to work with the automatic search path detection implemented by man-db.
In the case that this is executed on a system without man-db, there should be no consequence as all it does is create directories and symlinks within the rgbenv managed directory.

For reference, explanation of manpath search behaviour in manpath(5) SEARCH PATH. Notably:

[...] man-db examines the user's $PATH. For each path_element found there, [...] it adds all of path_element/../man, path_element/man, path_element/../share/man, and path_element/share/man that exist as directories to the search path.

Fixes #19

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Install man pages with selected version

1 participant