Skip to content

Instantly share code, notes, and snippets.

@holman57
Created June 10, 2024 17:51
Show Gist options
  • Select an option

  • Save holman57/2240976c5e8fc6cddfc68c1530a48e6e to your computer and use it in GitHub Desktop.

Select an option

Save holman57/2240976c5e8fc6cddfc68c1530a48e6e to your computer and use it in GitHub Desktop.
Check arguments passed to a bash shell
#!/bin/bash
if [ $# -eq 0 ]
then
echo -e "You need to specify the target domain.\n"
echo -e "Usage:"
echo -e "\t$0 <domain>"
exit 1
else
domain=$1
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment