Git sync fork

@kevgo please review
not a debug statement. This is how you can get a return value out of a bash function with setting a global variable.