-
-
Save anonymous/3bd16c7d1f51ccbbd07238715c3f1486 to your computer and use it in GitHub Desktop.
Function/alias to snap create an executable bash script with vim
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
vix() { | |
[ -e "$1" ] || echo -e '#!/bin/bash\n\n' > "$1"; | |
chmod +x "$1"; | |
vi "+normal G" +startinsert "$1" | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment