Skip to content

Comments

remove the misleading warning on using nix-env for split outputs#255947

Merged
fricklerhandwerk merged 1 commit intoNixOS:masterfrom
fricklerhandwerk:doc-outputsToInstall
Sep 25, 2023
Merged

remove the misleading warning on using nix-env for split outputs#255947
fricklerhandwerk merged 1 commit intoNixOS:masterfrom
fricklerhandwerk:doc-outputsToInstall

Conversation

@fricklerhandwerk
Copy link
Contributor

@fricklerhandwerk fricklerhandwerk commented Sep 18, 2023

The text was originally added following an apparently incomplete research on how everything plays together. In fact, Nix propagates outputs to the corresponding nested derivations, and there is some messy behavior in Nixpkgs that only seems to propagate meta.outputsToInstall in buildEnv.

This change moves the hints on how to use NixOS specifics to NixOS module documentation (which is hopefully easier to find through search.nixos.org), describes the default behavior in Nixpkgs (updating a the link to the source), and removes the confusing mention of nix-env.

the last of them should not be there to begin with. we don't want beginners to use nix-env, as this is known to run them into trouble eventually.

Related: NixOS/nix#8990

@fricklerhandwerk fricklerhandwerk added the 8.has: documentation This PR adds or changes documentation label Sep 18, 2023
@fricklerhandwerk fricklerhandwerk requested a review from a team September 18, 2023 18:50
@github-actions github-actions bot added 6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS 8.has: module (update) This PR changes an existing module in `nixos/` labels Sep 18, 2023
The text was originally added [0] following an apparently incomplete
research on how everything plays together. In fact, Nix propagates
`outputs` to the corresponding nested derivations, and there is some
messy behavior in Nixpkgs that only seems to propagate
`meta.outputsToInstall` in `buildEnv`[1].

This change moves the hints on how to use NixOS specifics to NixOS
module documentation (which is hopefully easier to find through
search.nixos.org), describes the default behavior in Nixpkgs (updating
a the link to the source), and removes the confusing mention of
`nix-env`.

the last of them should not be there to begin with. we don't want
beginners to use `nix-env`, as this is known to run them into trouble
eventually.

[0]: NixOS#76794
[1]: https://github.com/NixOS/nixpkgs/blob/1774d07242995050d2d8a91cb4da0855eac2e472/pkgs/build-support/buildenv/default.nix#L66
@ofborg ofborg bot added 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. labels Sep 18, 2023
@fricklerhandwerk fricklerhandwerk merged commit 370097c into NixOS:master Sep 25, 2023
@nixos-discourse
Copy link

This pull request has been mentioned on NixOS Discourse. There might be relevant details there:

https://discourse.nixos.org/t/2023-09-21-documentation-team-meeting-notes-81/33490/1

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

Labels

6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS 8.has: documentation This PR adds or changes documentation 8.has: module (update) This PR changes an existing module in `nixos/` 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants