summary refs log tree commit diff
diff options
context:
space:
mode:
authorV <v@anomalous.eu>2020-08-29 09:54:14 +0200
committerV <v@anomalous.eu>2020-08-29 09:54:14 +0200
commite08bcdbec3265f701c175ae5ac9d813e10cad292 (patch)
tree111f6e78b573c55c0132c6a19336613d1264d65b
parentbe193a20572a72a15ffb569aba8eb56fe881c842 (diff)
downloadnixpkgs-e08bcdbec3265f701c175ae5ac9d813e10cad292.tar
nixpkgs-e08bcdbec3265f701c175ae5ac9d813e10cad292.tar.gz
nixpkgs-e08bcdbec3265f701c175ae5ac9d813e10cad292.tar.bz2
nixpkgs-e08bcdbec3265f701c175ae5ac9d813e10cad292.tar.lz
nixpkgs-e08bcdbec3265f701c175ae5ac9d813e10cad292.tar.xz
nixpkgs-e08bcdbec3265f701c175ae5ac9d813e10cad292.tar.zst
nixpkgs-e08bcdbec3265f701c175ae5ac9d813e10cad292.zip
nixos-rebuild: don't quote $EDITOR
$EDITOR is allowed to contain flags, so it is important to allow the
shell to split this normally. For example, Sublime Text needs to be
passed --wait, since otherwise it will daemonise.
-rw-r--r--nixos/modules/installer/tools/nixos-rebuild.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/nixos/modules/installer/tools/nixos-rebuild.sh b/nixos/modules/installer/tools/nixos-rebuild.sh
index e79cc5e24fb..ed9c2509b6b 100644
--- a/nixos/modules/installer/tools/nixos-rebuild.sh
+++ b/nixos/modules/installer/tools/nixos-rebuild.sh
@@ -291,7 +291,7 @@ if [ "$action" = edit ]; then
         if [[ -d $NIXOS_CONFIG ]]; then
             NIXOS_CONFIG=$NIXOS_CONFIG/default.nix
         fi
-        exec "${EDITOR:-nano}" "$NIXOS_CONFIG"
+        exec ${EDITOR:-nano} "$NIXOS_CONFIG"
     else
         exec nix edit "${lockFlags[@]}" -- "$flake#$flakeAttr"
     fi