Skip to content

Commit

Permalink
Merge pull request #225 from phips28/revert-224-always-fetch-branches
Browse files Browse the repository at this point in the history
Revert "Tag events: Always fetch branches"
  • Loading branch information
phips28 authored Oct 3, 2023
2 parents 76db496 + 81bfcdb commit 0a70848
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -205,8 +205,11 @@ const pkg = getPackageJson();
await runInWorkspace('git', ['commit', '-a', '-m', commitMessage.replace(/{{version}}/g, newVersion)]);
}

// First fetch to get updated local version of branch
await runInWorkspace('git', ['fetch']);
// now go to the actual branch to perform the same versioning
if (isPullRequest) {
// First fetch to get updated local version of branch
await runInWorkspace('git', ['fetch']);
}
await runInWorkspace('git', ['checkout', currentBranch]);
await runInWorkspace('npm', ['version', '--allow-same-version=true', '--git-tag-version=false', current]);
console.log('current 2:', current, '/', 'version:', version);
Expand Down

0 comments on commit 0a70848

Please sign in to comment.