diff options
Diffstat (limited to 'pkgs')
-rwxr-xr-x | pkgs/by-name/lm/lm/lm.sh | 10 | ||||
-rw-r--r-- | pkgs/by-name/lm/lm/package.nix | 11 |
2 files changed, 13 insertions, 8 deletions
diff --git a/pkgs/by-name/lm/lm/lm.sh b/pkgs/by-name/lm/lm/lm.sh index d5fdca10..9c61f30f 100755 --- a/pkgs/by-name/lm/lm/lm.sh +++ b/pkgs/by-name/lm/lm/lm.sh @@ -1,7 +1,13 @@ #!/usr/bin/env dash -# shellcheck source=/dev/null -SHELL_LIBRARY_VERSION="2.1.2" . %SHELL_LIBRARY_PATH +die() { + echo "ERROR: $1" + exit 1 +} + +msg() { + echo "$1" +} if [ -f "$XDG_RUNTIME_DIR/ll/last_directory" ]; then last_dir="$(cat "$XDG_RUNTIME_DIR/ll/last_directory")" diff --git a/pkgs/by-name/lm/lm/package.nix b/pkgs/by-name/lm/lm/package.nix index ef417cd2..e3ebe962 100644 --- a/pkgs/by-name/lm/lm/package.nix +++ b/pkgs/by-name/lm/lm/package.nix @@ -1,9 +1,8 @@ -{sysLib}: -sysLib.writeShellScript { +{writeShellApplication}: +writeShellApplication { name = "lm"; - src = ./lm.sh; - generateCompletions = false; + text = builtins.readFile ./lm.sh; - # `ll` must be able to change the path of the running shell. - wrap = false; + # This is sourced in the shell + inheritPath = true; } |