Created
January 22, 2018 10:43
-
-
Save PaulChana/46fe896cf394cc702e08356c3200a2aa to your computer and use it in GitHub Desktop.
[Bash Defaults] Set variable defaults #shell #bash
This file contains hidden or 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
#!/bin/bash | |
FIRST_ARG="${1:-no_first_arg}" | |
SECOND_ARG="${2:-no_second_arg}" | |
THIRD_ARG="${3:-no_third_arg}" | |
echo ${FIRST_ARG} | |
echo ${SECOND_ARG} | |
echo ${THIRD_ARG} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment