Skip to content

Commit

Permalink
fix(git): add -- to git rev-parse
Browse files Browse the repository at this point in the history
  • Loading branch information
rarkins committed May 4, 2021
1 parent 4ad7f5f commit e7bb72d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/util/git/index.ts
Expand Up @@ -409,7 +409,7 @@ export async function checkoutBranch(branchName: string): Promise<CommitSha> {
try {
config.currentBranch = branchName;
config.currentBranchSha = (
await git.raw(['rev-parse', 'origin/' + branchName])
await git.raw(['rev-parse', 'origin/' + branchName, '--'])
).trim();
await git.checkout(['-f', branchName, '--']);
const latestCommitDate = (await git.log({ n: 1 }))?.latest?.date;
Expand Down

0 comments on commit e7bb72d

Please sign in to comment.