Fixed issue checking .git file for cmake