Skip to content

Instantly share code, notes, and snippets.

@liuyix
Created May 6, 2013 03:12
Show Gist options
  • Save liuyix/5523176 to your computer and use it in GitHub Desktop.
Save liuyix/5523176 to your computer and use it in GitHub Desktop.
Check if a file exists with wildcard in shell script link:http://stackoverflow.com/a/6364244
if ls /path/to/your/files* &> /dev/null; then
echo "files do exist"
else
echo "files do not exist"
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment