nix-darwin icon indicating copy to clipboard operation
nix-darwin copied to clipboard

No entry for configuration.nix in section 5 of the manual

Open Pablo1107 opened this issue 1 year ago • 6 comments

When running

man 5 configuration.nix

Probably an error with my flake configuration since I also use home-manager, but I find it hard to debug how the $MANPATH is set up.

Some info, which man and which manpath points to /usr/bin which idk if that should be the case. And echo $MANPATH is missing /run/current-system/sw/share/man, should I add this to the $MANPATH by myself?

Pablo1107 avatar Jul 23 '22 05:07 Pablo1107

Do you have the following in your configuration?

{
  documentation.enable = true;
}

This will enable the manpages for nix-darwin and the system packages, and enable the man package.

brendanzab avatar Aug 22 '22 08:08 brendanzab

Do you have the following in your configuration?

{
  documentation.enable = true;
}

This will enable the manpages for nix-darwin and the system packages, and enable the man package.

Yes, I do have that option enabled, but I don't think the environment variables are correctly set in my shell.

Pablo1107 avatar Aug 26 '22 12:08 Pablo1107

What's the actual error?

lockejan avatar Aug 28 '22 20:08 lockejan

What's the actual error?

No error, the message is the title of this issue. man does not seems to find any nix-darwin manpages.

Pablo1107 avatar Sep 03 '22 00:09 Pablo1107

Some info, which man and which manpath points to /usr/bin which idk if that should be the case. And echo $MANPATH is missing /run/current-system/sw/share/man, should I add this to the $MANPATH by myself?

nix-darwin doesn't set the MANPATH per default and you shouldn't have to do it either. The same goes for documentation.enable, because true is the default.

However, in my case I get the man bin from my nix-profile. darwin-option documentation.enable and darwin-option programs.man.enable both report true as a current val?

Can you run darwin-help? This should open the manpage in your browser.

lockejan avatar Sep 03 '22 07:09 lockejan

Some info, which man and which manpath points to /usr/bin which idk if that should be the case. And echo $MANPATH is missing /run/current-system/sw/share/man, should I add this to the $MANPATH by myself?

nix-darwin doesn't set the MANPATH per default and you shouldn't have to do it either. The same goes for documentation.enable, because true is the default.

However, in my case I get the man bin from my nix-profile. darwin-option documentation.enable and darwin-option programs.man.enable both report true as a current val?

Can you run darwin-help? This should open the manpage in your browser.

darwin-option does not work, because I configure nix darwin via flakes. darwin-help does work, but I lack all the nix-darwin installed man pages. Also, as I pointed out in the OP, which man outputs /usr/bin/man which I supposed is the culprit. Maybe that should point to a nix man instead, but the order in the path prioritizes /usr/bin over nix binaries which idk if that should be like that or not, again, noobie question.

Pablo1107 avatar Sep 04 '22 01:09 Pablo1107

Are you still running into this issue? I believe man should determine the MANPATH variable from the PATH variable, so you shouldn't have MANPATH set in your terminal.

Enzime avatar Aug 05 '23 22:08 Enzime

I actually don't have a MacBook anymore so I cannot test. If nobody can reproduce, we can close this.

Pablo1107 avatar Aug 06 '23 05:08 Pablo1107

I'll close this for now, if anyone else can reproduce this, feel free to leave a comment :+1:

Enzime avatar Aug 06 '23 06:08 Enzime