1
0
mirror of https://github.com/nix-community/home-manager synced 2024-06-26 16:38:34 +02:00

home-manager: add more pass-through options

Specifically, pass through --[extra-]experimental-features to Nix.
This commit is contained in:
Shamrock Lee 2022-02-12 18:50:51 +00:00 committed by Robert Helgesson
parent 03b7495183
commit 23a9f9127c
No known key found for this signature in database
GPG Key ID: 36BDAA14C2797E89
2 changed files with 13 additions and 2 deletions

View File

@ -18,10 +18,13 @@ Either set in `nix.conf`
[source,bash] [source,bash]
experimental-features = nix-command flakes experimental-features = nix-command flakes
+ +
or pass them to `nix` by or pass them to `nix` and `home-manager` by
+ +
[source,console] [source,console]
nix --experimental-features "nix-command flakes" your command ----
$ nix --extra-experimental-features "nix-command flakes" <sub-commands>
$ home-manager --extra-experimental-features "nix-command flakes" <sub-commands>
----
* Prepare your Home Manager configuration (`home.nix`). * Prepare your Home Manager configuration (`home.nix`).
+ +

View File

@ -608,6 +608,14 @@ while [[ $# -gt 0 ]]; do
PASSTHROUGH_OPTS+=("$opt" "$1" "$2") PASSTHROUGH_OPTS+=("$opt" "$1" "$2")
shift 2 shift 2
;; ;;
--experimental-features)
PASSTHROUGH_OPTS+=("$opt" "$1")
shift
;;
--extra-experimental-features)
PASSTHROUGH_OPTS+=("$opt" "$1")
shift
;;
--no-out-link) --no-out-link)
NO_OUT_LINK=1 NO_OUT_LINK=1
;; ;;