From d1635ffd31d127ba0bf10de97f0693813d3ef459 Mon Sep 17 00:00:00 2001 From: Hektor Misplon Date: Thu, 27 Oct 2022 03:29:24 +0200 Subject: [PATCH] Update script to create script --- .bin/script | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/.bin/script b/.bin/script index 6b36d7d..604d34b 100755 --- a/.bin/script +++ b/.bin/script @@ -13,5 +13,13 @@ path="$HOME/.bin/$1" set -o noclobber # Create script -echo "#!/usr/bin/env bash" > "$path" +cat > "$path" << EOF +#!/usr/bin/env bash + + +EOF + chmod +x "$path" + +# Open script in editor on line 3 +"$EDITOR" +3 "$path"