New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
nixos: doc: implement #12542 #46193
nixos: doc: implement #12542 #46193
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just skimmed this quickly, but I do like it.
233ef0a
to
8c4ea26
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall looks fine, just a nit pick with the phrasing. 👍 Thanks for the work!
nixos/modules/misc/documentation.nix
Outdated
<citerefentry><refentrytitle>configuration.nix</refentrytitle> | ||
<manvolnum>5</manvolnum></citerefentry> if <option>man.enable</option> is | ||
set.</para></listitem> | ||
<listitem><para>This includes HTML manual and <command>nixos-help</command> script if |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this should be phrased "This includes the HTML manual and the nixos-help [...]". Additionally, the end-user wouldn't care much whether it is a script or a binary. "the nixos-help command" represents better what the end-user would use; a command.
(The previous sentence "This includes man pages like [...]", though is fine without adding "the".)
Status: this conflicts with merged #46510 and I have questions about that change there, so this is now stalled. |
Because when I see "config.system.build.manual.manual" after I forgot what it means I ask "Why do I need that second `.manual` there again?". Doesn't happen with `config.system.build.manual.manualHTML`.
8c4ea26
to
0f3b89b
Compare
Fixed nitpicks. Fixed conflicts and rebased. |
Error update NixOS
with --show-trace
|
Please show the output of `grep nixosManual configuration.nix` (and/or all equivalent files).
It looks like you have `services.nixosManual.enable` disabled but `services.nixosManual.showManual` enabled and the new `assert` gets computed too late for some reason.
|
Not found nixosManual in /etc/nixos/* |
Indeed, I reproduced your error it with a minimal config with the above combination of options, so evaluation order is indeed buggy, fixed in #47293. Now the question is what sets this combination of variables in your config. Do you include any profiles? (In principle, I can "fix" this by simply disabling |
This config causes an error
|
Should be fixed by #47298. |
nixos: fix fallout from #46193
Introduced by 0f3b89b. If services.nixosManual.showManual is enabled and documentation.nixos.enable is not, there is no config.system.build.manual available, so evaluation fails. For example this is the case for the installer tests. There is however an assertion which should catch exactly this, but it isn't thrown because the usage of config.system.build.manual is evaluated earlier than the assertions. So I split the assertion off into a separate mkIf to make sure it is shown appropriately and also fixed the installation-device profile to enable documentation.nixos. Signed-off-by: aszlig <aszlig@nix.build> Cc: @oxij
Motivation for this change
NixOS
documentation
subtree was born out of 2/3s of #12542, this implements the leftover 1/3. This patchset consists of option renames, code movements, a bit of cleanup, and one new assert.In short, nothing substantial.
This simply makes the
configuration.nix(5)
manual cleaner and theservices.nixosManual
service is now actually a service, not an amalgamation of different things.Known issues
services.nixosManual.showManual
should be renamed toservices.nixosManual.enable
, but sinceservices.nixosManual.enable
meant a completely different thing before and there's noconfigVersion
-thing yet I left it as is.Things done
Don't merge sooner than 2018-09-09 23:59 UTC.