dgy
/
hexagons
Archived
1
0
Fork 0
This repository has been archived on 2021-03-24. You can view files and clone it, but cannot push or open issues or pull requests.
hexagons/bin/crear

13 lines
242 B
Bash
Executable File

#!/usr/bin/env bash
FOLDER="$HOME/bin"
FILE="$FOLDER/$1"
if [[ -f $FILE ]]; then
echo -e "There's a file called that already..."
else
echo -e "#!/usr/bin/env bash\\nset -euf -o pipefail\\n" > "$FILE"
chmod +x "$FILE"
$EDITOR "$FILE"
fi