Skip to content

Commit b800744

Browse files
authored
chore(ci): push mongosh tag separately during release (#2508)
Since GitHub Actions only runs create tag workflows when no more than 3 tags are created (https://docs.github.com/en/actions/reference/events-that-trigger-workflows#create), we will push the mongosh tag separately to ensure it triggers the merge tag workflow
1 parent 5737032 commit b800744

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

packages/build/src/npm-packages/publish.ts

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,17 @@ export class PackagePublisher {
111111
if (!mongoshVersion) {
112112
throw new Error('mongosh package not found');
113113
}
114+
115+
if (!this.config.isDryRun) {
116+
// Push the tag separately for mongosh to trigger the merge-release-tag.yml workflow
117+
// Since GitHub Actions only runs create tag workflows when no more than 3 tags are created.
118+
// https://docs.github.com/en/actions/reference/events-that-trigger-workflows#create
119+
this.spawnSync(
120+
'git',
121+
['push', 'origin', `refs/tags/mongosh@${mongoshVersion}`],
122+
commandOptions
123+
);
124+
}
114125
}
115126

116127
if (!this.config.isDryRun) {

0 commit comments

Comments
 (0)