From 6ee1d00b924e6187c7ee0f70b5a7d62be43b5853 Mon Sep 17 00:00:00 2001 From: tv Date: Wed, 7 Sep 2022 11:17:39 +0200 Subject: runShell: admit non-posix-compatible shells --- pkgs/krops/default.nix | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pkgs/krops/default.nix b/pkgs/krops/default.nix index 429e648..b94c89b 100644 --- a/pkgs/krops/default.nix +++ b/pkgs/krops/default.nix @@ -19,7 +19,10 @@ in allocateTTY ? false }: command: let - command' = if target.sudo then "sudo ${command}" else command; + command' = /* sh */ '' + ${lib.optionalString target.sudo "sudo"} \ + /bin/sh -c ${lib.escapeShellArg command} + ''; in if lib.isLocalTarget target then command' -- cgit v1.2.3