mirror of
https://github.com/ItsDrike/nixdots
synced 2024-11-10 02:49:41 +00:00
Use a simper way to enable flakes
This commit is contained in:
parent
6b3200bbb1
commit
3f1e0f8568
|
@ -97,11 +97,7 @@
|
||||||
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
||||||
system.stateVersion = "23.11"; # Did you read the comment?
|
system.stateVersion = "23.11"; # Did you read the comment?
|
||||||
|
|
||||||
nix = {
|
nix.package = pkgs.nixUnstable;
|
||||||
package = pkgs.nixUnstable;
|
nix.settings.experimental-features = [ "nix-command" "flakes" ];
|
||||||
extraOptions = ''
|
|
||||||
experimental-features = nix-command flakes
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -34,15 +34,11 @@ nano configuration.nix
|
||||||
|
|
||||||
In there, change the `environment.systemPackages = with pkgs; [];` like, and include `git` and `vim`.
|
In there, change the `environment.systemPackages = with pkgs; [];` like, and include `git` and `vim`.
|
||||||
|
|
||||||
After that, let's enable flakes, by adding the following at the end of your `configuration.nix` (but still within the function body - before the last `}`):
|
After that, let's enable flakes, by adding the following anywhere in your `configuration.nix`:
|
||||||
|
|
||||||
```nix
|
```nix
|
||||||
nix = {
|
nix.package = pkgs.nixUnstable;
|
||||||
package = pkgs.nixUnstable;
|
nix.settings.experimental-features = [ "nix-command" "flakes" ];
|
||||||
extraOptions = ''
|
|
||||||
experimental-features = nix-command flakes
|
|
||||||
''
|
|
||||||
};
|
|
||||||
```
|
```
|
||||||
|
|
||||||
Now you can save the changes and rebuild the system:
|
Now you can save the changes and rebuild the system:
|
||||||
|
|
Loading…
Reference in a new issue