Skip to content

Commit b7fec80

Browse files
authored
chore(ci): fix package publish next COMPASS-6860 (#4817)
* chore: make sure all plugins are published * chore: split version-next and package-next so we can run them separately and retry publish * chore(compass-aggregations): fix types
1 parent b7d0093 commit b7fec80

File tree

8 files changed

+30
-18
lines changed

8 files changed

+30
-18
lines changed

.evergreen/functions.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -560,7 +560,11 @@ functions:
560560
echo "//registry.npmjs.org/:_authToken=$NPM_TOKEN" >> .npmrc
561561
npm config list
562562
echo "Publishing packages as $(npm whoami)"
563-
git update-index --assume-unchanged .npmrc
563+
npm run version-packages-next
564+
# unstage after lerna staged version
565+
git reset
566+
# mark files as unchanged so that lerna can publish
567+
git update-index --assume-unchanged $(git diff --name-only HEAD)
564568
bash ".evergreen/retry-with-backoff.sh" npm run publish-packages-next
565569
fi
566570

package-lock.json

Lines changed: 8 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,8 @@
4343
"where": "monorepo-where",
4444
"create-workspace": "node ./scripts/create-workspace.js",
4545
"update-evergreen-config": "node .evergreen/template-yml.js",
46-
"publish-packages-next": "npx lerna publish from-package \"0.0.0-next-$(git rev-parse HEAD)\" --force-publish --exact --no-git-tag-version --no-private --dist-tag next --pre-dist-tag next --no-verify-access --no-git-reset --yes",
46+
"version-packages-next": "npx lerna version \"0.0.0-next-$(git rev-parse HEAD)\" --exact --no-private --no-git-tag-version --force-publish --no-push --yes",
47+
"publish-packages-next": "npx lerna publish from-package --no-private --dist-tag next --pre-dist-tag next --yes",
4748
"prepare": "husky install",
4849
"snyk-test": "node scripts/snyk-test.js",
4950
"pregenerate-vulnerability-report": "npm run compile -w packages/compass && npm run snyk-test",

packages/compass-aggregations/src/modules/pipeline-builder/pipeline-parser/pipeline-parser.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,10 @@ export default class PipelineParser {
239239
}
240240

241241
function getLineOnlySourceLocation(line: number) {
242-
return { start: { line, column: 0 }, end: { line, column: 0 } };
242+
return {
243+
start: { line, column: 0 },
244+
end: { line, column: 0 },
245+
} as t.SourceLocation;
243246
}
244247

245248
function adjustStageLoc(stage: t.Node, line: number) {

packages/compass-app-stores/package.json

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,12 @@
66
"name": "MongoDB Inc",
77
"email": "[email protected]"
88
},
9-
"private": true,
109
"bugs": {
1110
"url": "https://jira.mongodb.org/projects/COMPASS/issues",
1211
"email": "[email protected]"
1312
},
1413
"homepage": "https://github.com/mongodb-js/compass",
15-
"version": "0.5.2",
14+
"version": "7.0.0",
1615
"repository": {
1716
"type": "git",
1817
"url": "https://github.com/mongodb-js/compass.git"
@@ -81,5 +80,8 @@
8180
},
8281
"peerDependencies": {
8382
"mongodb-instance-model": "^12.9.2"
83+
},
84+
"publishConfig": {
85+
"access": "public"
8486
}
8587
}

packages/compass-explain-plan/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@
6666
"react": "^17.0.2"
6767
},
6868
"devDependencies": {
69-
"@mongodb-js/compass-field-store": "^0.3.1",
69+
"@mongodb-js/compass-field-store": "^9.0.0",
7070
"@mongodb-js/eslint-config-compass": "^1.0.8",
7171
"@mongodb-js/mocha-config-compass": "^1.3.0",
7272
"@mongodb-js/prettier-config-compass": "^1.0.1",

packages/compass-field-store/package.json

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,12 @@
66
"name": "MongoDB Inc",
77
"email": "[email protected]"
88
},
9-
"private": true,
109
"bugs": {
1110
"url": "https://jira.mongodb.org/projects/COMPASS/issues",
1211
"email": "[email protected]"
1312
},
1413
"homepage": "https://github.com/mongodb-js/compass",
15-
"version": "0.3.1",
14+
"version": "9.0.0",
1615
"repository": {
1716
"type": "git",
1817
"url": "https://github.com/mongodb-js/compass.git"
@@ -77,5 +76,8 @@
7776
"reflux-state-mixin": "github:mongodb-js/reflux-state-mixin",
7877
"sinon": "^9.2.3",
7978
"xvfb-maybe": "^0.2.1"
79+
},
80+
"publishConfig": {
81+
"access": "public"
8082
}
8183
}

packages/compass/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -183,14 +183,14 @@
183183
"@electron/remote": "^2.0.11",
184184
"@mongodb-js/atlas-service": "^0.3.0",
185185
"@mongodb-js/compass-aggregations": "^9.13.0",
186-
"@mongodb-js/compass-app-stores": "^0.5.2",
186+
"@mongodb-js/compass-app-stores": "^7.0.0",
187187
"@mongodb-js/compass-collection": "^4.12.0",
188188
"@mongodb-js/compass-crud": "^13.12.0",
189189
"@mongodb-js/compass-database": "^3.12.0",
190190
"@mongodb-js/compass-databases-collections": "^1.12.0",
191191
"@mongodb-js/compass-explain-plan": "^6.12.0",
192192
"@mongodb-js/compass-export-to-language": "^8.12.0",
193-
"@mongodb-js/compass-field-store": "^0.3.1",
193+
"@mongodb-js/compass-field-store": "^9.0.0",
194194
"@mongodb-js/compass-find-in-page": "^4.12.0",
195195
"@mongodb-js/compass-home": "^6.13.0",
196196
"@mongodb-js/compass-import-export": "^7.12.0",

0 commit comments

Comments
 (0)