Skip to content

Commit 0112e8a

Browse files
committed
Switching to yarn
1 parent c4b57b4 commit 0112e8a

File tree

22 files changed

+8766
-5762
lines changed

22 files changed

+8766
-5762
lines changed

.eslintignore

+1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ dist
33
build
44
node_modules
55
coverage
6+
/.yarn
67
/doc
78
/components/assistive-playwright-server/src/validation.js
89
test-reports

.github/workflows/ci.yml

+19-19
Original file line numberDiff line numberDiff line change
@@ -60,20 +60,20 @@ jobs:
6060
- uses: actions/cache@v3
6161
with:
6262
path: |
63-
~/.pnpm-store
63+
.yarn/cache
6464
~/.ms-playwright
65-
key: pnpm-${{ hashFiles('pnpm-lock.yaml') }}
65+
key: yarn-${{ hashFiles('yarn.lock') }}
6666
restore-keys: |
67-
pnpm-
67+
yarn-
6868
- run: |
69-
npm i -g pnpm
69+
corepack enable
7070
echo "PLAYWRIGHT_BROWSERS_PATH=$HOME/.ms-playwright" >> $GITHUB_ENV
71-
pnpm config set store-dir ~/.pnpm-store
72-
- run: pnpm install --frozen-lockfile
73-
- run: pnpm lint
74-
- run: pnpm format:check
75-
- run: pnpm apidoc
76-
- run: pnpm test -r
71+
- run: yarn install --immutable
72+
- run: yarn workspaces foreach -tv run build
73+
- run: yarn lint
74+
- run: yarn format:check
75+
- run: yarn apidoc
76+
- run: yarn workspaces foreach -tv run test
7777
- name: "Download software"
7878
run: cd ./vagrant/win10-chromium-nvda && ./download.sh
7979
- uses: nick-fields/retry@3e91a01664abd3c5cd539100d10d33b9c5b68482 # v2.8.2
@@ -91,7 +91,7 @@ jobs:
9191
command: |
9292
export VM_SETTINGS="$(node -e 'console.log(JSON.stringify(require("./vagrant/win10-chromium-nvda/vm-config.json").nvda.vmSettings))')" &&
9393
. ./vagrant/win10-chromium-nvda/vm-skip-keys.sh &&
94-
pnpm nyc-apw-tester -l debug -k $NVDA_SKIP_KEYS --vm-settings '$VM_SETTINGS'
94+
yarn nyc-apw-tester -l debug -k $NVDA_SKIP_KEYS --vm-settings "$VM_SETTINGS"
9595
- uses: nick-fields/retry@3e91a01664abd3c5cd539100d10d33b9c5b68482 # v2.8.2
9696
name: "test assistive-playwright (jaws, chromium)"
9797
with:
@@ -100,11 +100,11 @@ jobs:
100100
command: |
101101
export VM_SETTINGS="$(node -e 'console.log(JSON.stringify(require("./vagrant/win10-chromium-nvda/vm-config.json").jaws.vmSettings))')" &&
102102
. ./vagrant/win10-chromium-nvda/vm-skip-keys.sh &&
103-
pnpm nyc-apw-tester -l debug -k $JAWS_SKIP_KEYS --vm-settings '$VM_SETTINGS'
104-
- run: pnpm nyc-apw-test
103+
yarn nyc-apw-tester -l debug -k $JAWS_SKIP_KEYS --vm-settings "$VM_SETTINGS"
104+
- run: yarn nyc-apw-test
105105
name: "test assistive-playwright-test"
106106
- run: |
107-
pnpm nyc-awd-server -l debug -c ./vagrant/win10-chromium-nvda/vm-config.json --pid-file assistive-webdriver.pid &> assistive-webdriver.log &
107+
yarn nyc-awd-server -l debug -c ./vagrant/win10-chromium-nvda/vm-config.json --pid-file assistive-webdriver.pid &> assistive-webdriver.log &
108108
while ! nc -z 127.0.0.1 3000; do sleep 1; done
109109
name: "Start assistive-webdriver server"
110110
- uses: nick-fields/retry@3e91a01664abd3c5cd539100d10d33b9c5b68482 # v2.8.2
@@ -114,15 +114,15 @@ jobs:
114114
max_attempts: 5
115115
command: |
116116
. ./vagrant/win10-chromium-nvda/vm-skip-keys.sh &&
117-
pnpm nyc-awd-tester -m nvda -k $NVDA_SKIP_KEYS -l debug
117+
yarn nyc-awd-tester -m nvda -k $NVDA_SKIP_KEYS -l debug
118118
- uses: nick-fields/retry@3e91a01664abd3c5cd539100d10d33b9c5b68482 # v2.8.2
119119
name: "test assistive-webdriver (jaws, chromium)"
120120
with:
121121
timeout_minutes: 30
122122
max_attempts: 5
123123
command: |
124124
. ./vagrant/win10-chromium-nvda/vm-skip-keys.sh &&
125-
pnpm nyc-awd-tester -m jaws -k $JAWS_SKIP_KEYS -l debug
125+
yarn nyc-awd-tester -m jaws -k $JAWS_SKIP_KEYS -l debug
126126
- run: |
127127
ASSISTIVE_WEBDRIVER_PID=$(cat ./assistive-webdriver.pid)
128128
echo "Sending SIGINT to $ASSISTIVE_WEBDRIVER_PID"
@@ -135,17 +135,17 @@ jobs:
135135
if: ${{ always() }}
136136
- run: cat vboxwebsrv.log
137137
if: ${{ always() }}
138-
- run: pnpm nyc-report
138+
- run: yarn nyc-report
139139
if: matrix.ENABLE_COVERAGE == '1'
140140
- uses: codecov/codecov-action@d9f34f8cd5cb3b3eb79b3e4b5dae3a16df499a70 #v3.1.1
141141
with:
142142
file: ./coverage/lcov.info
143143
if: matrix.ENABLE_COVERAGE == '1'
144144
- if: matrix.ENABLE_COVERAGE == '0' && github.event_name == 'push' && startsWith(github.ref, 'refs/tags/release/')
145-
name: pnpm publish
145+
name: yarn publish
146146
run: |
147147
echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}" > ~/.npmrc
148-
pnpm publish -r --no-git-checks
148+
yarn workspaces foreach -tv npm publish --tolerate-republish
149149
- if: matrix.ENABLE_COVERAGE == '0' && github.event_name == 'push' && startsWith(github.ref, 'refs/tags/release/')
150150
uses: actions/checkout@v3
151151
with:

.github/workflows/update.yml

-25
This file was deleted.

.gitignore

+9
Original file line numberDiff line numberDiff line change
@@ -10,3 +10,12 @@ node_modules
1010
/components/vm-providers/src/config.ts
1111
/doc/apidoc-output
1212
test-reports
13+
14+
# https://yarnpkg.com/getting-started/qa#which-files-should-be-gitignored (not using Zero-Installs):
15+
.pnp.*
16+
.yarn/*
17+
!.yarn/patches
18+
!.yarn/plugins
19+
!.yarn/releases
20+
!.yarn/sdks
21+
!.yarn/versions

.prettierignore

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ dist
33
build
44
node_modules
55
coverage
6-
/pnpm-lock.yaml
6+
/.yarn
77
/components/assistive-webdriver/config-schema.json
88
/components/assistive-playwright-server/src/validation.js
99
/doc/apidoc-input

.yarn/plugins/@yarnpkg/plugin-workspace-tools.cjs

+28
Large diffs are not rendered by default.

.yarn/releases/yarn-3.3.0.cjs

+807
Large diffs are not rendered by default.

.yarnrc.yml

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
nodeLinker: node-modules
2+
3+
plugins:
4+
- path: .yarn/plugins/@yarnpkg/plugin-workspace-tools.cjs
5+
spec: "@yarnpkg/plugin-workspace-tools"
6+
7+
yarnPath: .yarn/releases/yarn-3.3.0.cjs

components/assistive-playwright-client/package.json

+3-2
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@
3636
"assistive-playwright-server": "workspace:*",
3737
"jest": "29.3.1",
3838
"node-fetch": "3.3.0",
39+
"nyc": "15.1.0",
3940
"rollup": "3.5.1",
4041
"tslib": "2.4.1",
4142
"typescript": "4.9.3",
@@ -48,8 +49,8 @@
4849
"ws": "8.11.0"
4950
},
5051
"scripts": {
51-
"prepare": "pnpm build",
52-
"build": "node ../../tools/clean && pnpm build:rollup && pnpm build:dts && pnpm build:api",
52+
"prepack": "yarn build",
53+
"build": "node ../../tools/clean && yarn build:rollup && yarn build:dts && yarn build:api",
5354
"build:rollup": "rollup --failAfterWarnings -c",
5455
"build:dts": "tsc -p tsconfig.d.json",
5556
"build:api": "api-extractor run --config ./api-extractor.json --verbose",

components/assistive-playwright-server/package.json

+3-2
Original file line numberDiff line numberDiff line change
@@ -35,17 +35,18 @@
3535
"@types/yargs": "17.0.15",
3636
"jest": "29.3.1",
3737
"node-fetch": "3.3.0",
38+
"nyc": "15.1.0",
3839
"rollup": "3.5.1",
3940
"tslib": "2.4.1",
4041
"typescript": "4.9.3",
4142
"typescript-json-schema": "0.55.0",
4243
"wait-port": "1.0.4"
4344
},
4445
"scripts": {
45-
"prepare": "pnpm build",
46+
"prepack": "yarn build",
4647
"build:validation": "node ./generateValidation",
4748
"build:rollup": "rollup --failAfterWarnings -c",
48-
"build": "node ../../tools/clean && pnpm build:validation && pnpm build:rollup",
49+
"build": "node ../../tools/clean && yarn build:validation && yarn build:rollup",
4950
"test": "nyc --cwd ../.. jest"
5051
},
5152
"license": "MIT"

components/assistive-playwright-test-sample/playwright.config.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ const config: AssistivePlaywrightTestConfig = {
2323
forbidOnly: !!process.env.CI,
2424
retries: process.env.CI ? 5 : 0,
2525
webServer: {
26-
command: "npm start",
26+
command: "yarn start",
2727
cwd: __dirname,
2828
url: baseURL,
2929
reuseExistingServer: !process.env.CI

components/assistive-playwright-test/package.json

+3-2
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@
2727
"devDependencies": {
2828
"@microsoft/api-extractor": "7.33.6",
2929
"@playwright/test": "1.28.1",
30+
"@rollup/plugin-typescript": "10.0.1",
3031
"@types/uuid": "9.0.0",
3132
"rollup": "3.5.1",
3233
"tslib": "2.4.1",
@@ -40,8 +41,8 @@
4041
"@playwright/test": "^1.19.2"
4142
},
4243
"scripts": {
43-
"prepare": "pnpm build",
44-
"build": "node ../../tools/clean && pnpm build:rollup && pnpm build:dts && pnpm build:api",
44+
"prepack": "yarn build",
45+
"build": "node ../../tools/clean && yarn build:rollup && yarn build:dts && yarn build:api",
4546
"build:rollup": "rollup --failAfterWarnings -c",
4647
"build:dts": "tsc -p tsconfig.d.json",
4748
"build:api": "api-extractor run --config ./api-extractor.json --verbose && node fixApi"

components/assistive-playwright-tester/package.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -30,15 +30,15 @@
3030
"@rollup/plugin-typescript": "10.0.1",
3131
"@types/uuid": "9.0.0",
3232
"@types/yargs": "17.0.15",
33-
"playwright-core": "1.28.1",
3433
"node-fetch": "3.3.0",
34+
"playwright-core": "1.28.1",
3535
"rollup": "3.5.1",
3636
"tslib": "2.4.1",
3737
"typescript": "4.9.3",
3838
"wait-port": "1.0.4"
3939
},
4040
"scripts": {
41-
"prepare": "pnpm build",
41+
"prepack": "yarn build",
4242
"build": "node ../../tools/clean && rollup --failAfterWarnings -c"
4343
},
4444
"license": "MIT"

components/assistive-webdriver/package.json

+3-2
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@
6363
"jest": "29.3.1",
6464
"json-schema-to-typescript": "11.0.2",
6565
"node-fetch": "3.3.0",
66+
"nyc": "15.1.0",
6667
"p-queue": "7.3.0",
6768
"pngjs": "6.0.0",
6869
"rollup": "3.5.1",
@@ -74,8 +75,8 @@
7475
"selenium-webdriver": "*"
7576
},
7677
"scripts": {
77-
"prepare": "pnpm build",
78-
"build": "node ../../tools/clean && pnpm build:schema && pnpm build:rollup && pnpm build:dts && pnpm build:api",
78+
"prepack": "yarn build",
79+
"build": "node ../../tools/clean && yarn build:schema && yarn build:rollup && yarn build:dts && yarn build:api",
7980
"build:schema": "node build-config-schema.js && json2ts -i config-schema.json -o src/server/config.ts",
8081
"build:rollup": "rollup --failAfterWarnings -c",
8182
"build:dts": "tsc -p tsconfig.d.json",

components/text-to-socket-engine/package.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,9 @@
1919
"removeVoice.cmd"
2020
],
2121
"bin": {
22-
"text-to-socket-engine-register": "register.cmd",
23-
"text-to-socket-engine-unregister": "unregister.cmd",
2422
"text-to-socket-engine-add-voice": "addVoice.cmd",
25-
"text-to-socket-engine-remove-voice": "removeVoice.cmd"
23+
"text-to-socket-engine-register": "register.cmd",
24+
"text-to-socket-engine-remove-voice": "removeVoice.cmd",
25+
"text-to-socket-engine-unregister": "unregister.cmd"
2626
}
2727
}

components/vm-providers/package.json

+3-2
Original file line numberDiff line numberDiff line change
@@ -40,13 +40,14 @@
4040
"@types/uuid": "9.0.0",
4141
"jest": "29.3.1",
4242
"json-schema-to-typescript": "11.0.2",
43+
"nyc": "15.1.0",
4344
"rollup": "3.5.1",
4445
"tslib": "2.4.1",
4546
"typescript": "4.9.3"
4647
},
4748
"scripts": {
48-
"prepare": "pnpm build",
49-
"build": "node ../../tools/clean && pnpm build:schema && pnpm build:rollup && pnpm build:dts && pnpm build:api",
49+
"prepack": "yarn build",
50+
"build": "node ../../tools/clean && yarn build:schema && yarn build:rollup && yarn build:dts && yarn build:api",
5051
"build:schema": "json2ts -i config-schema.json -o src/config.ts",
5152
"build:rollup": "rollup --failAfterWarnings -c",
5253
"build:dts": "tsc -p tsconfig.d.json",

package.json

+11-5
Original file line numberDiff line numberDiff line change
@@ -10,27 +10,33 @@
1010
"babel-plugin-istanbul": "6.1.1",
1111
"eslint": "8.28.0",
1212
"eslint-config-prettier": "8.5.0",
13+
"jest": "29.3.1",
1314
"jest-environment-node": "29.3.1",
1415
"nyc": "15.1.0",
1516
"prettier": "2.8.0",
16-
"ts-jest": "29.0.3"
17+
"ts-jest": "29.0.3",
18+
"typescript": "4.9.3"
1719
},
1820
"scripts": {
1921
"format": "prettier .",
20-
"format:check": "pnpm format --check",
21-
"format:fix": "pnpm format --write",
22+
"format:check": "yarn format --check",
23+
"format:fix": "yarn format --write",
2224
"lint": "eslint .",
2325
"apidoc": "api-documenter markdown -i doc/apidoc-input -o doc/apidoc-output",
2426
"nyc-report": "nyc report --reporter=lcov",
2527
"nyc-awd-server": "nyc node components/assistive-webdriver/dist/server/bin.js",
2628
"nyc-awd-tester": "nyc node components/assistive-webdriver/dist/tester.js",
2729
"nyc-apw-tester": "nyc node components/assistive-playwright-tester/dist/index.js",
28-
"nyc-apw-test": "nyc node components/assistive-playwright-test-sample/node_modules/@playwright/test/cli.js test -c components/assistive-playwright-test-sample"
30+
"nyc-apw-test": "nyc node node_modules/@playwright/test/cli.js test -c components/assistive-playwright-test-sample"
2931
},
3032
"nyc": {
3133
"instrument": false,
3234
"sourceMap": false,
3335
"silent": true,
3436
"clean": false
35-
}
37+
},
38+
"packageManager": "yarn@3.3.0",
39+
"workspaces": [
40+
"components/*"
41+
]
3642
}

0 commit comments

Comments
 (0)