version.sh: simplify an unused if/else

base is only needed in the case where the current branch is not master
version.sh: fix for when master branch does not exist

This can happen when the repo is cloned with --branch.
In this case, don't try to find the merge-base and don't
append it to the version string.
Merge pull request #98 from m0vie/version

version.sh improvements