diff options
Diffstat (limited to '')
-rw-r--r-- | home-manager/config/lf/cmds/mk_scr.sh | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/home-manager/config/lf/cmds/mk_scr.sh b/home-manager/config/lf/cmds/mk_scr.sh index 4b80e564..0441c63f 100644 --- a/home-manager/config/lf/cmds/mk_scr.sh +++ b/home-manager/config/lf/cmds/mk_scr.sh @@ -1,27 +1,27 @@ -#!/bin/sh +#!/usr/bin/env dash # shellcheck disable=SC2086 # shellcheck source=/dev/null -. ~/.local/lib/shell/lib +. %SHELL_LIBRARY_PATH star=$(mktmp) cat << EOF > $star -#!/bin/sh +#!/usr/bin/env dash # shellcheck disable=SC2086 # shellcheck source=/dev/null -. ~/.local/lib/shell/lib +. %SHELL_LIBRARY_PATH -LIB_TEMP_DIR_FOR_SCRIPT=$(mktemp -d) +LIB_TEMP_DIR_FOR_SCRIPT=\$(mktemp -d) -if [ -d "$LIB_TEMP_DIR_FOR_SCRIPT" ];then rm -r "$LIB_TEMP_DIR_FOR_SCRIPT"; fi +if [ -d "\$LIB_TEMP_DIR_FOR_SCRIPT" ];then rm -r "\$LIB_TEMP_DIR_FOR_SCRIPT"; fi EOF readp "Script Name: " script_name scr="$(pwd)"/"$script_name" -[ -e $scr ] && die "$script_name exitst, exiting.." +[ -e $scr ] && die "$script_name exist, exiting.." cat "$star" > $scr chmod +x $scr |