Skip to content

Commit

Permalink
Remove version check in gitRevParse.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
typicode committed Jan 21, 2020
1 parent d561a88 commit c7976df
Showing 1 changed file with 0 additions and 9 deletions.
9 changes: 0 additions & 9 deletions src/installer/gitRevParse.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,5 @@ export function gitRevParse(cwd = process.cwd()): GitRevParseResult {
// Normalize for Windows
.map(slash)

// Git rev-parse returns unknown options as is.
// If we get --absolute-git-dir in the output,
// it probably means that an old version of Git has been used.
// There seem to be a bug with --git-common-dir that was fixed in 2.13.0.
// See issues above.
if (gitCommonDir === '--git-common-dir') {
throw new Error('Husky requires Git >= 2.13.0, please upgrade Git')
}

return { prefix, gitCommonDir }
}

0 comments on commit c7976df

Please sign in to comment.