Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit e15dd2f

Browse files
committedMar 1, 2025·
Get rid of more yarn-isms
1 parent 1167448 commit e15dd2f

File tree

20 files changed

+29
-32
lines changed

20 files changed

+29
-32
lines changed
 

‎.gitattributes

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
yarn.lock linguist-generated
1+
pnpm-lock.yaml linguist-generated

‎.gitignore

-1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,5 @@ docs
55
!packages/eslint-plugin-khan/docs
66
!.vscode
77
.DS_Store
8-
yarn-error.log
98
*.tsbuildinfo
109
utils/**/*.d.ts

‎CONTRIBUTING.md

+7-7
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ To work in the `wonder-stuff` repository, follow these steps:
2525

2626
1. Clone the repository
2727
`git clone git@github.com:Khan/wonder-stuff.git`
28-
2. Install `yarn` (see [🔗yarnpkg.com](https://yarnpkg.com))
29-
3. Run `yarn install` to install the dependencies
28+
2. Install `pnpm` (see [🔗pnpm](https://pnpm.io))
29+
3. Run `pnpm install` to install the dependencies
3030

3131
You can now work on `wonder-stuff`. We prefer [🔗Visual Studio Code](https://code.visualstudio.com/) as our development environment (it's cross-platform and awesome), but please use what you feel comfortable with (we'll even forgive you for using vim).
3232

@@ -46,17 +46,17 @@ We love code reviews. If there are open pull requests, please feel free to revie
4646

4747
To ensure code quality, we use prettier, TypeScript, eslint, and jest. These are all executed automatically on commit, so don't worry if you forget to run them before you commit. They are also executed when you submit, edit, or push to a pull request to ensure the contribution meets our code quality standard.
4848

49-
To execute these operations outside of a pull request or commit operation, you can use `yarn`.
49+
To execute these operations outside of a pull request or commit operation, you can use `pnpm`.
5050

51-
- `yarn typecheck`
52-
- `yarn lint`
53-
- `yarn test`
51+
- `pnpm typecheck`
52+
- `pnpm lint`
53+
- `pnpm test`
5454

5555
💭**REMEMBER** If you would like to contribute code changes to the project, first make sure there's a corresponding issue for the change you wish to make.
5656

5757
## 📦 Build And Publish
5858

59-
Anyone can create a local build of the distributed code by running `yarn build`.
59+
Anyone can create a local build of the distributed code by running `pnpm build`.
6060

6161
### Publishing
6262

‎build-settings/check-type-definitions.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
* files instead. Since we don't want to ship source code in every package,
99
* we want to guard against this.
1010
*
11-
* This script should be run after `yarn build:types`. It will scan the type
11+
* This script should be run after `pnpm build:types`. It will scan the type
1212
* definitions of each package for any types that are being incorrectly
1313
* imported from other the source code of other packages, and flag them,
1414
* exiting with a non-zero status code if any are found.

‎package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@
9898
"lint": "pnpm run lint:ci .",
9999
"lint:ci": "eslint --ext .ts --ext .js",
100100
"lint:pkg-json": "pnpm npmPkgJsonLint ./packages/wonder-stuff-*",
101-
"publish:ci": "pnpm run lint:pkg-json && node utils/pre-publish-check-ci.js && git diff --stat --exit-code HEAD && yarn build && yarn build:types && changeset publish",
101+
"publish:ci": "pnpm run lint:pkg-json && node utils/pre-publish-check-ci.js && git diff --stat --exit-code HEAD && pnpm run build && pnpm run build:types && changeset publish",
102102
"test": "pnpm jest",
103103
"typecheck": "tsc",
104104
"nochangeset": "pnpm changeset add --empty",

‎packages/eslint-config-khan/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Shared Khan Academy eslint configuration.
44

55
## Quick Start
66

7-
- `yarn add @khanacademy/eslint-config`
7+
- `(yarn|pnpm) add --save-dev @khanacademy/eslint-config`
88
- Update your .eslintrc.js file to:
99
- extend `"@khanacademy"`
1010
- include settings for `"import/resolver"`

‎packages/eslint-plugin-khan/demo/README.md

+2-4
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,9 @@ the custom eslint rules this plugin provides.
55

66
After making a change to the plugin source code, you'll need to take following steps to
77
update the demo:
8-
- run `yarn build` from the root directory of the repository
8+
- run `pnpm install` and `pnpm build` from the root directory of the repository
99
- `cd packages/eslint-plugin-khan/demo`
10-
- `rm node_modules`
11-
- `yarn install`
12-
- `yarn eslint .`
10+
- `pnpm eslint .`
1311

1412
Your editor/IDE should report eslint errors that accurately reflect the changes you made
1513
to the plugin.

‎packages/wonder-stuff-ci/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
"main": "dist/index.js",
1818
"types": "dist/index.d.ts",
1919
"scripts": {
20-
"test": "bash -c 'yarn --silent --cwd \"../..\" test ${@:0} $($([[ ${@: -1} = -* ]] || [[ ${@: -1} = bash ]]) && echo $PWD)'"
20+
"test": "bash -c 'pnpm --silent --dir \"../..\" test ${@:0} $($([[ ${@: -1} = -* ]] || [[ ${@: -1} = bash ]]) && echo $PWD)'"
2121
},
2222
"devDependencies": {
2323
"@types/node": "^20.9.1",

‎packages/wonder-stuff-core/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
"main": "dist/index.js",
1818
"types": "dist/index.d.ts",
1919
"scripts": {
20-
"test": "bash -c 'yarn --silent --cwd \"../..\" test ${@:0} $($([[ ${@: -1} = -* ]] || [[ ${@: -1} = bash ]]) && echo $PWD)'"
20+
"test": "bash -c 'pnpm --silent --dir \"../..\" test ${@:0} $($([[ ${@: -1} = -* ]] || [[ ${@: -1} = bash ]]) && echo $PWD)'"
2121
},
2222
"devDependencies": {
2323
"@khanacademy/ws-dev-build-settings": "workspace:*"

‎packages/wonder-stuff-i18n/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
"main": "dist/index.js",
1818
"types": "dist/index.d.ts",
1919
"scripts": {
20-
"test": "bash -c 'yarn --silent --cwd \"../..\" test ${@:0} $($([[ ${@: -1} = -* ]] || [[ ${@: -1} = bash ]]) && echo $PWD)'"
20+
"test": "bash -c 'pnpm --silent --dir \"../..\" test ${@:0} $($([[ ${@: -1} = -* ]] || [[ ${@: -1} = bash ]]) && echo $PWD)'"
2121
},
2222
"dependencies": {
2323
"ancesdir": "^5.0.1",

‎packages/wonder-stuff-i18n/src/bin/all-i18n-strings.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
*
77
* USAGE:
88
*
9-
* yarn all-i18n-strings file.js
10-
* yarn all-i18n-strings "src/*.js"
9+
* pnpm all-i18n-strings file.js
10+
* pnpm all-i18n-strings "src/*.js"
1111
*/
1212
import {getFilesToExtractFrom, getPoItemMap} from "../utils/pofile-utils";
1313

‎packages/wonder-stuff-i18n/src/bin/gen-potfile.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@
1010
* USAGE:
1111
*
1212
* # Extract strings from all JS files and export to a shared POT file
13-
* yarn gen-potfile "javascript/*.{js,jsx}" > JavaScript.pot
13+
* pnpm gen-potfile "javascript/*.{js,jsx}" > JavaScript.pot
1414
*
1515
* # Extract strings from a specific file and output to STDOUT
16-
* yarn gen-potfile javascript/about/about.jsx
16+
* pnpm gen-potfile javascript/about/about.jsx
1717
*/
1818
import {
1919
getFilesToExtractFrom,

‎packages/wonder-stuff-render-environment-jsdom/examples/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,5 @@ run the following command from the root folder, where `<EXAMPLE>` is the name
66
of the example folder.
77

88
```shell
9-
yarn example <EXAMPLE>
9+
pnpm example <EXAMPLE>
1010
```

‎packages/wonder-stuff-render-environment-jsdom/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
"types": "dist/index.d.ts",
1919
"scripts": {
2020
"example": "bash -c 'RUNNER=\"./examples/$0/run.ts\"; KA_LOG_LEVEL=silly NODE_ENV=development babel-watch --config-file ../../babel.config.js \"$RUNNER\" --extensions .ts'",
21-
"test": "bash -c 'yarn --silent --cwd \"../..\" test ${@:0} $($([[ ${@: -1} = -* ]] || [[ ${@: -1} = bash ]]) && echo $PWD)'"
21+
"test": "bash -c 'pnpm --silent --dir \"../..\" test ${@:0} $($([[ ${@: -1} = -* ]] || [[ ${@: -1} = bash ]]) && echo $PWD)'"
2222
},
2323
"dependencies": {
2424
"@khanacademy/wonder-stuff-core": "workspace:*",

‎packages/wonder-stuff-render-server/examples/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,5 @@ run the following command from the root folder, where `<EXAMPLE>` is the name
66
of the example folder.
77

88
```shell
9-
yarn example <EXAMPLE>
9+
pnpm example <EXAMPLE>
1010
```

‎packages/wonder-stuff-render-server/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
"types": "dist/index.d.ts",
1919
"scripts": {
2020
"example": "bash -c 'RUNNER=\"./examples/$0/run.ts\"; KA_LOG_LEVEL=silly NODE_ENV=development babel-watch --config-file ../../babel.config.js \"$RUNNER\" --extensions .ts'",
21-
"test": "bash -c 'yarn --silent --cwd \"../..\" test ${@:0} $($([[ ${@: -1} = -* ]] || [[ ${@: -1} = bash ]]) && echo $PWD)'"
21+
"test": "bash -c 'pnpm --silent --dir \"../..\" test ${@:0} $($([[ ${@: -1} = -* ]] || [[ ${@: -1} = bash ]]) && echo $PWD)'"
2222
},
2323
"dependencies": {
2424
"@khanacademy/wonder-stuff-core": "workspace:*",

‎packages/wonder-stuff-render-server/src/requests-from-cache.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -58,12 +58,12 @@ export const asUncachedRequest = (
5858
};
5959

6060
// NOTE(kevinb): This is necessary to workaround the followoing error when running
61-
// `yarn build:types`:
61+
// `pnpm build:types`:
6262
// TS4078: Parameter 'response' of exported function has or is using private name 'Response'.
6363
type SAResponse = Response;
6464

6565
// TODO(kevinb): Figure out how to move this into its own .d.ts file and have it
66-
// work with both `yarn typecheck` and `yarn build:types`.
66+
// work with both `pnpm typecheck` and `pnpm build:types`.
6767
declare module "superagent" {
6868
interface SuperAgentRequest {
6969
cacheWhenEmpty(cacheWhenEmpty: boolean): this;

‎packages/wonder-stuff-sentry/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
"CHANGELOG.md"
2222
],
2323
"scripts": {
24-
"test": "bash -c 'yarn --silent --cwd \"../..\" test ${@:0} $($([[ ${@: -1} = -* ]] || [[ ${@: -1} = bash ]]) && echo $PWD)'"
24+
"test": "bash -c 'pnpm --silent --dir \"../..\" test ${@:0} $($([[ ${@: -1} = -* ]] || [[ ${@: -1} = bash ]]) && echo $PWD)'"
2525
},
2626
"dependencies": {
2727
"@khanacademy/wonder-stuff-core": "workspace:*"

‎packages/wonder-stuff-server/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
"main": "dist/index.js",
1818
"types": "dist/index.d.ts",
1919
"scripts": {
20-
"test": "bash -c 'yarn --silent --cwd \"../..\" test ${@:0} $($([[ ${@: -1} = -* ]] || [[ ${@: -1} = bash ]]) && echo $PWD)'"
20+
"test": "bash -c 'pnpm --silent --dir \"../..\" test ${@:0} $($([[ ${@: -1} = -* ]] || [[ ${@: -1} = bash ]]) && echo $PWD)'"
2121
},
2222
"dependencies": {
2323
"@khanacademy/wonder-stuff-core": "workspace:*"

‎packages/wonder-stuff-testing/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
"main": "dist/index.js",
1818
"types": "dist/index.d.ts",
1919
"scripts": {
20-
"test": "bash -c 'yarn --silent --cwd \"../..\" test ${@:0} $($([[ ${@: -1} = -* ]] || [[ ${@: -1} = bash ]]) && echo $PWD)'"
20+
"test": "bash -c 'pnpm --silent --dir \"../..\" test ${@:0} $($([[ ${@: -1} = -* ]] || [[ ${@: -1} = bash ]]) && echo $PWD)'"
2121
},
2222
"dependencies": {
2323
"@khanacademy/wonder-stuff-core": "workspace:*"

0 commit comments

Comments
 (0)
Please sign in to comment.