Skip to content

Instantly share code, notes, and snippets.

@ozh
Created April 3, 2013 09:21
Show Gist options
  • Save ozh/5299695 to your computer and use it in GitHub Desktop.
Save ozh/5299695 to your computer and use it in GitHub Desktop.
Bash template script with argument
#!/bin/sh
usage() {
echo "usage: this that <param>"
}
if [ $# -ne 1 ]; then
usage
exit 1
fi
... do stuff
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment