| 19 Feb 2024 |
@philiptaron:matrix.org | It's coming from pkgs.mkShell.
To read how that happens, open up pkgs/top-level/all-packages.nix, find mkShell. That gets you to pkgs/build-support/mkshell/default.nix.
Inside pkgs/build-support/mkshell/default.nix, note how the return value is stdenv.mkDerivation. (that stdenv is the key).
Consider also mkShellNoCC for your use case. Note how that definition in pkgs/top-level/all-packages.nix does this:
mkShellNoCC = mkShell.override { stdenv = stdenvNoCC; };
You can do similarly to override the stdenv with whatever's appropriate for your usecase.
| 16:50:23 |
mr-qubo | Thanks, that's very helpful! | 16:54:12 |
| bitraten joined the room. | 19:27:19 |
mr-qubo | In reply to @mr-qubo:matrix.org When I do e.g. nix shell 'nixpkgs#htop' only htop is added to path. But if I create flake with devShell and htop in buildInputs, and use nix develop dependencies are added into the PATH as well, like with nix-shell -p htop. Is it possible to have this work as nix shell? Also, as a second question, is it possible to group multiple packages and link all bins in one path, so only one entry in PATH is added instead of separate entry for each package? I switched to https://devenv.sh/. It fixes my problem with unwanted packages in PATH and automatically uses buildEnv to create single PATH entry for all packages. | 20:05:55 |
| 20 Feb 2024 |
| @sofo:matrix.org changed their display name from Sofi to Sofie. | 07:39:15 |
| @sofo:matrix.org changed their profile picture. | 14:39:08 |
| @sofo:matrix.org changed their profile picture. | 14:41:41 |
| @sofo:matrix.org changed their profile picture. | 14:42:46 |
| @sofo:matrix.org changed their profile picture. | 14:44:03 |
| duffyduke joined the room. | 21:30:17 |
| 22 Feb 2024 |
| @atakan:atkn.me joined the room. | 03:10:03 |
| hx-markus joined the room. | 12:25:43 |
| 26 Feb 2024 |
| maribox joined the room. | 14:34:09 |
maribox |  Download image.png | 14:40:27 |
maribox | Hey! I added flakes as an experimental feature in my configuration.nix but I got the error in the image.
After I removed the experimental-features line I still get the same error when running nixos-rebuild switch, even though there's no mention of flakes in the configuration.nix file.
I'm a super noob, what am I missing here? | 14:41:58 |
maribox | Also when I load an older version of my OS, even the first one, the same Error appears, even though I just added the flakes line in the last rebuild... | 14:46:09 |
@2xsaiko:tchncs.de | In reply to @maribox:matrix.org sent an image. it loads /etc/nixos/flake.nix instead of configuration.nix if it exists | 14:49:12 |
@2xsaiko:tchncs.de | rename/remove it | 14:49:23 |
@2xsaiko:tchncs.de | (it has nothing to do with whether the experimental option is enabled, but purely with the existence of the file) | 14:50:22 |
maribox | thanks! | 14:50:59 |
| 27 Feb 2024 |
Bryan | (We've been having a similar discussion on a nix-direnv issue lately, so if you're stessaris on github and this is a reiteration - I apologize :) )
This is due to the way you're entering the shell and what nix develop does vs nix shell. You'd also find that things like libraries are not always accessible in nix shell invocations, since it effectively brings in only certain environment variables like PATH and excludes bringing in others like OCAMLPATH or PKG_CONFIG_PATH. The environment gets "dirty" but it is because Nix is actually trying to help...
| 13:24:55 |
| Daniel Herrera Rendón joined the room. | 20:48:06 |
| 28 Feb 2024 |
| ethan2 joined the room. | 16:51:44 |
| @atakan:atkn.me left the room. | 18:18:00 |
| 29 Feb 2024 |
| @wimpress:matrix.org joined the room. | 21:09:54 |
| 1 Mar 2024 |
| @accelbread:matrix.org joined the room. | 04:28:22 |
| tomberek set a profile picture. | 15:21:36 |
| 2 Mar 2024 |
| Qyriad joined the room. | 06:56:26 |
| Qyriad | 07:51:29 |
| 3 Mar 2024 |
| Tim changed their display name from Tim Le Pés to Tim. | 22:49:42 |