message="$(git log --merges -n 1)" echo $message if [[ $message == *"__post__"* ]]; then echo "It's there!" fi