Fix git version detection during setup wizard

pull/73/head
NGPixel 8 years ago
parent b9afbcb792
commit 8daa772c61

@ -90,7 +90,7 @@ module.exports = (port, spinner) => {
if (err || stdout.length < 3) {
reject(new Error('Git is not installed or not reachable from PATH.'))
}
let gitver = _.chain(stdout.replace(/[^\d.]/g, '')).split('.').take(3).join('.').value()
let gitver = _.head(stdout.match(/[\d]+\.[\d]+\.[\d]+/g))
if (!semver.satisfies(semver.clean(gitver), '>=2.7.4')) {
reject(new Error('Git version is too old. Minimum is v2.7.4.'))
}

Loading…
Cancel
Save