Skip to content

Commit

Permalink
chore: replace meteor yarn with meteor npm run to fix issue with …
Browse files Browse the repository at this point in the history
…incompatibility of yarn and old meteor node.js version

Issue:
[METEOR-TSC] C:\Users\user\AppData\Roaming\nvm\v18.20.4\node_modules\corepack\dist\yarn.js:2
[METEOR-TSC] process.env.COREPACK_ENABLE_DOWNLOAD_PROMPT??='1'
[METEOR-TSC]                                            ^^^
[METEOR-TSC]
[METEOR-TSC] SyntaxError: Unexpected token '??='
  • Loading branch information
nytamin committed Dec 9, 2024
1 parent 7a5dc15 commit a668b44
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 18 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/audit.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ jobs:
run: |
yarn
cd meteor
meteor yarn validate:prod-dependencies
meteor npm run validate:prod-dependencies
env:
CI: true

Expand Down Expand Up @@ -57,7 +57,7 @@ jobs:
run: |
yarn
cd meteor
meteor yarn run validate:all-dependencies
meteor npm run validate:all-dependencies
env:
CI: true

Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/node.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ jobs:
# setup zodern:types. No linters are setup, so this simply installs the packages
meteor lint
meteor yarn ci:lint
meteor npm run ci:lint
env:
CI: true

Expand Down Expand Up @@ -85,7 +85,7 @@ jobs:
# setup zodern:types. No linters are setup, so this simply installs the packages
meteor lint
NODE_OPTIONS="--max-old-space-size=6144" meteor yarn unitci --force-exit
NODE_OPTIONS="--max-old-space-size=6144" meteor npm run unitci --force-exit
env:
CI: true
- name: Send coverage
Expand Down
8 changes: 4 additions & 4 deletions meteor/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,18 +10,18 @@
"debug": "meteor run",
"libs:syncVersions": "node scripts/libs-sync-version.js",
"libs:syncVersionsAndChangelogs": "node scripts/libs-sync-version-and-changelog.js",
"postinstall": "meteor yarn run prepareForTest",
"postinstall": "meteor npm run prepareForTest",
"prepareForTest": "node ../scripts/fixTestFibers.js",
"inject-git-hash": "node ./scripts/generate-version-file.js",
"unit": "jest",
"unitci": "jest --maxWorkers 2 --coverage",
"unitcov": "jest --coverage",
"test": "meteor yarn check-types && meteor yarn unit",
"test": "meteor npm run check-types && meteor npm run unit",
"watch": "jest --watch",
"update-snapshots": "jest --updateSnapshot",
"ci:lint": "meteor yarn check-types && meteor yarn lint",
"ci:lint": "meteor npm run check-types && meteor npm run lint",
"cov-open": "open-cli coverage/lcov-report/index.html",
"cov": "meteor yarn unitcov && meteor yarn cov-open",
"cov": "meteor npm run unitcov && meteor npm run cov-open",
"license-validate": "node ../scripts/checkLicenses.js --allowed=\"MIT,BSD,ISC,Apache,Unlicense,CC0,LGPL,CC BY 3.0,CC BY 4.0,MPL 2.0,Python 2.0\" --excludePackages=timecode,rxjs/ajax,rxjs/fetch,rxjs/internal-compatibility,nw-pre-gyp-module-test,rxjs/operators,rxjs/testing,rxjs/webSocket,undefined,i18next-conv,@fortawesome/fontawesome-common-types,argv,indexof,custom-license,private,public-domain-module,@sofie-automation/corelib,@sofie-automation/shared-lib,@sofie-automation/job-worker",
"lint": "run lint:raw .",
"lint:raw": "eslint --ext .ts --ext .js --ext .tsx --ext .jsx",
Expand Down
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,13 @@
"unit:packages": "cd packages && run unit",
"check-types:meteor": "cd meteor && run check-types",
"test:meteor": "cd meteor && run test",
"lint:meteor": "cd meteor && meteor yarn lint",
"unit:meteor": "cd meteor && meteor yarn unit",
"meteor:run": "cd meteor && meteor yarn start",
"lint:meteor": "cd meteor && meteor npm run lint",
"unit:meteor": "cd meteor && meteor npm run unit",
"meteor:run": "cd meteor && meteor npm run start",
"lint": "run lint:meteor && run lint:packages",
"unit": "run unit:meteor && run unit:packages",
"validate:release": "yarn install && run install-and-build && run validate:release:packages && run validate:release:meteor",
"validate:release:meteor": "cd meteor && meteor yarn validate:prod-dependencies && meteor yarn license-validate && meteor yarn lint && meteor yarn test",
"validate:release:meteor": "cd meteor && meteor npm run validate:prod-dependencies && meteor npm run license-validate && meteor npm run lint && meteor npm run test",
"validate:release:packages": "cd packages && run validate:dependencies && run test",
"meteor": "cd meteor && meteor",
"docs:serve": "cd packages && run docs:serve",
Expand Down
11 changes: 5 additions & 6 deletions scripts/run.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ function watchPackages() {
{
command: config.uiOnly
? `yarn watch ${EXTRA_PACKAGES.map((pkg) => `--ignore ${pkg}`).join(
" "
)}`
" "
)}`
: "yarn watch",
cwd: "packages",
name: "PACKAGES-TSC",
Expand All @@ -31,15 +31,14 @@ function watchWorker() {
function watchMeteor() {
return [
{
command: "meteor yarn watch-types --preserveWatchOutput",
command: "meteor npm run watch-types --preserveWatchOutput",
cwd: "meteor",
name: "METEOR-TSC",
prefixColor: "blue",
},
{
command: `meteor yarn debug${config.inspectMeteor ? " --inspect" : ""}${
config.verbose ? " --verbose" : ""
}`,
command: `meteor npm run debug${config.inspectMeteor ? " --inspect" : ""}${config.verbose ? " --verbose" : ""
}`,
cwd: "meteor",
name: "METEOR",
prefixColor: "cyan",
Expand Down

0 comments on commit a668b44

Please sign in to comment.