Build: fix git command execution on some environment