Skip to content

Instantly share code, notes, and snippets.

@gargolito
Created May 6, 2019 00:04
Show Gist options
  • Select an option

  • Save gargolito/132e4689957bcc409602e3b71921a708 to your computer and use it in GitHub Desktop.

Select an option

Save gargolito/132e4689957bcc409602e3b71921a708 to your computer and use it in GitHub Desktop.
#bash
[[ $1 == ?(-)+([0-9]) ]] && echo "$1 is an integer"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment