Improve init command's argument parsing

This commit is contained in:
2013-06-12 00:08:44 +01:00
parent 21c43be558
commit c9c3534f05

View File

@@ -2,9 +2,9 @@
set -e
[ -n "$TMUXIFIER_DEBUG" ] && set -x
# Set shell to first argument that is not "-" or "--help".
# Set shell to first argument that is not "-", "-h" or "--help".
for arg in "$@"; do
if [ "$arg" != "-" ] && [ "$arg" != "--help" ]; then
if [ "$arg" != "-" ] &&[ "$arg" != "-h" ] && [ "$arg" != "--help" ]; then
shell="$arg"
fi
done