Add shebang line and check for Bash.

The shebang is ignored when sourcing the script (but still helps many text editors auto-detect the file type), and will cause an error when the script is mistakenly executed.
The Bash check allows to have this called from a generic place (e.g. .profile), and do no harm when under a different shell.
This commit is contained in:
Ingo Karkat
2011-11-20 14:26:52 +01:00
parent 9b67a76833
commit 285d5039f2

View File

@@ -1,3 +1,6 @@
#!/bin/bash source-this-script
[ "$BASH_VERSION" ] || return
_todo()
{
local cur prev opts