From d1db986e15c6b38f735ee76145b34ec2cec89b90 Mon Sep 17 00:00:00 2001 From: Daniel Fichtinger Date: Sun, 23 Feb 2025 19:45:07 -0500 Subject: [PATCH] AutoYADM commit: 2025-02-23 19:45:07 --- .zshrc | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/.zshrc b/.zshrc index 6ee36c33..bf02427d 100644 --- a/.zshrc +++ b/.zshrc @@ -142,6 +142,18 @@ function set_win_title(){ function viewport_osc(){ print -Pn "\e]133;A\e\\" } + +function mksh(){ + local path="$1.sh" + if [[ ! -f "$path" ]]; then + echo "#!/bin/env bash\n" >> "$path" + /usr/bin/chmod +x "$path" + echo "$path created." + else + echo "$path already exists." + fi +} + # precmd_functions+=(set_win_title viewport_osc) precmd_functions+=(viewport_osc) zle -N zle-line-init