Move helpers into lib.nix

This commit is contained in:
Alex David 2025-05-11 14:51:48 -07:00
commit 08e7907337
2 changed files with 16 additions and 8 deletions

View file

@ -3,7 +3,14 @@
exe-str = if builtins.typeOf exe == "string" then lib.escapeShellArg exe else lib.getExe exe;
combinators = import ./combinators.nix pkgs;
helpers = {
escape = rawOrStr: if builtins.typeOf rawOrStr == "string" then lib.strings.escapeShellArg rawOrStr else rawOrStr.raw;
noescape = value: { raw = value; };
};
combinators = import ./combinators.nix {
inherit pkgs lib helpers;
};
initial-state = lib.pipe {
cmd = "${lib.getExe pkgs.bubblewrap}";