`git branch` upstream-setting fixes

also helper script for checking installed `git` version
You can do this comparison directly on the lists:
```
In [3]: [1,2,3] < [1,2,2]
Out[3]: False

In [4]: [1,2,3] < [1,2,4]
Out[4]: True
```