aboutsummaryrefslogtreecommitdiffstats
path: root/utils/scripts.nix
diff options
context:
space:
mode:
Diffstat (limited to 'utils/scripts.nix')
-rw-r--r--utils/scripts.nix33
1 files changed, 0 insertions, 33 deletions
diff --git a/utils/scripts.nix b/utils/scripts.nix
deleted file mode 100644
index 87639c6..0000000
--- a/utils/scripts.nix
+++ /dev/null
@@ -1,33 +0,0 @@
-{
- lib,
- pkgs,
- config,
-}:
-
-{
- # We define mkScript as a function that takes the context it needs
- mkScript =
- name: path: env:
- let
- # Logic inside the helper
- defaultShell =
- if (config.tools.zsh.enable or false) then
- (lib.getExe config.programs.zsh.package)
- else
- "/usr/bin/env sh";
-
- envVars = lib.concatStringsSep "\n" (
- lib.mapAttrsToList (n: v: "export ${n}=\"${toString v}\"") env
- );
- in
- pkgs.writeTextFile {
- inherit name;
- executable = true;
- destination = "/bin/${name}";
- text = ''
- #!${defaultShell}
- ${envVars}
- ${builtins.readFile path}
- '';
- };
-}