Avoid using 'which' executable for finding git

Just use 'git --version' to check if the git executable is present

Change-Id: Ib5c11060fa7d9b7d9741dd88fc3430237f0bc1a0
Closes-Bug: #1248447
Merge "Avoid using 'which' executable for finding git"