I have a script that i need to act differently based on if there are any, that is one or more, commits. What is the best way to do this?
In pseudo code it would look something like this..
#!/bin/bash
if [[ `git log_count` == "0" ]]; then
echo "No commits exist for this repo."
# Do stuff..
else
echo "One or more commits do exist!"
# Do other stuff
fi
Any ideas?