-
Notifications
You must be signed in to change notification settings - Fork 944
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Pin pnpm version using corepack (#2602)
* Pin to pnpm 8 using corepack * Update CONTRIBUTING.md guide to mention pnpm / corepack --------- Co-authored-by: Tim Welch <[email protected]>
- Loading branch information
1 parent
fbfb882
commit 3a6a035
Showing
3 changed files
with
14 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -28,7 +28,7 @@ Once you've cloned a Turf repository, and have a terminal open and currenty in t | |
- enable pnpm as a package manager. Requires Node 16+. Alternatively just `npm install -g pnpm`. | ||
- `pnpm install` | ||
- install dependencies and build modules | ||
- `npm test` | ||
- `pnpm test` | ||
- run all tests and linters | ||
|
||
You're now ready to contribute. | ||
|
@@ -79,16 +79,16 @@ it will create a new folder inside `packages` with a simple boilerplate for your | |
tests. We prefer dynamic testing built from GeoJSON files placed in | ||
`./test/in` that are subsequently written to `./test/out` if your `REGEN` | ||
[environment variable is set](https://askubuntu.com/a/58828) to `true`. If | ||
`REGEN` is set to a different value, then running `npm t` will compare the | ||
`REGEN` is set to a different value, then running `pnpm t` will compare the | ||
output of the tests to the files already present in `./test/out`. | ||
* `types.ts` - A file that tests the custom TypeScript types declared in | ||
`index.d.ts`. | ||
* `package.json` - The [node](http://nodejs.org) metadata container file. | ||
Modules imported in `index.js` should be listed here under `dependencies`, | ||
and modules used in `test.js` and/or `bench.js` should be listed under | ||
`devDependencies`. `npm install` looks to this file to install dependencies | ||
`devDependencies`. `pnpm install` looks to this file to install dependencies | ||
in `./node_modules`. | ||
* `README.md` - This README is generated _automatically_ by running `npm run | ||
* `README.md` - This README is generated _automatically_ by running `pnpm run | ||
docs` from the project root level. **DO NOT edit this file**. | ||
* `LICENCE` - Like the README, this file should not be edited. | ||
* `test/` - This directory holds the GeoJSON files that provide data for | ||
|
@@ -244,7 +244,7 @@ Run the release commands, replace `7.0.0` with your version number | |
|
||
- API docs for each turf package are extracted from JSDoc comments in the source code into the top-level README.md files. README's are automatically updated on commit using via the pre-commit hook. | ||
|
||
Should you want to generate new README files manually, use `npm run docs`: | ||
Should you want to generate new README files manually, use `pnpm run docs`: | ||
- **inside a module:** will generate the docs for that module. | ||
- **main folder:** will generate docs for all modules. | ||
|
||
|
@@ -254,7 +254,7 @@ Should you want to generate new README files manually, use `npm run docs`: | |
|
||
```bash | ||
$ cd ./turf/packages/turf-center | ||
$ npm run docs | ||
$ pnpm run docs | ||
|
||
> @turf/[email protected] docs /Users/mac/Github/turf/packages/turf-center | ||
> node ../../scripts/generate-readmes | ||
|
@@ -266,9 +266,9 @@ Building Docs: @turf/center | |
|
||
```bash | ||
$ cd ./turf | ||
$ npm run docs | ||
> @5.0.0 docs /Users/mac/Github/turf | ||
> node ./scripts/generate-readmes | ||
$ pnpm run docs | ||
> @ docs /Users/mac/Github/turf | ||
> tsx ./scripts/generate-readmes | ||
|
||
Building Docs: @turf/along | ||
Building Docs: @turf/area | ||
|
@@ -286,8 +286,9 @@ Building Docs: @turf/boolean-clockwise | |
The [turfjs.org](http://turfjs.org/) website is managed in a [separate repo](https://github.com/Turfjs/turf-www) with its own [contributing guide](https://github.com/Turfjs/turf-www/blob/master/CONTRIBUTING.md). | ||
|
||
## Other Dependencies | ||
- Turf uses [pnpm](https://pnpm.io/) and [lerna](https://lernajs.io/) during the testing, packaging and publishing process. | ||
- Lerna and pnpm will be automatically installed when you run `npm install` in the root directory. | ||
- Turf uses [pnpm 8](https://pnpm.io/8.x) and [lerna](https://lernajs.io/) during the testing, packaging and publishing process. | ||
- Lerna will be automatically installed when you run `pnpm install` in the root directory. | ||
- Pnpm will need to be installed on your computer, installers are available via the pnpm website. When using [corepack](https://nodejs.org/api/corepack.html), this is automatically installed when running `pnpm`. | ||
|
||
## Financial contributions | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -28,6 +28,7 @@ | |
], | ||
"**/*": "prettier --write --ignore-unknown" | ||
}, | ||
"packageManager": "[email protected]+sha512.d1a029e1a447ad90bc96cd58b0fad486d2993d531856396f7babf2d83eb1823bb83c5a3d0fc18f675b2d10321d49eb161fece36fe8134aa5823ecd215feed392", | ||
"devDependencies": { | ||
"@monorepolint/cli": "0.5.0-alpha.132", | ||
"@monorepolint/config": "0.5.0-alpha.132", | ||
|