Check if directory contains at least one file type
I am trying to check if a directory contains at least one .JPG file before running code.
Using multiple conditions using bash Test [duplicate]
This question already has answers here: Why does the equal to operator not work if it is not surrounded by spaces? (4 answers) Closed 2 days ago. I’m using the following bash Test for one condition and it’s working correctly [[ $# == 1 ]] || { echo “Syntax: $0 arg1”; exit 1; } But […]
Using multiple conditions using bash Test [duplicate]
This question already has answers here: Why does the equal to operator not work if it is not surrounded by spaces? (4 answers) Closed 2 days ago. I’m using the following bash Test for one condition and it’s working correctly [[ $# == 1 ]] || { echo “Syntax: $0 arg1”; exit 1; } But […]