diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index f48cd8d08..4d37aa7e5 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -62,11 +62,13 @@ To debug Prettier locally, you can either debug it in Node (recommended) or the - The easiest way to debug it in Node is to create a local test file with some example code you want formatted and either run it in an editor like VS Code or run it directly via `./bin/prettier.js `. - The easiest way to debug it in the browser is to build Prettier's website locally (see [`website/README.md`](website/README.md)). -## Other +## Pull requests The project uses ESLint for linting and Prettier for formatting. If your editor isn't set up to work with them, you can lint and format all files from the command line using `yarn fix`. -After opening a PR, describe your changes in a file in the `changelog_unreleased` directory following the template [`changelog_unreleased/TEMPLATE.md`](changelog_unreleased/TEMPLATE.md) and commit this file to your PR. You can use `./scripts/generate-changelog.mjs` to create changelog file. Please see comments of the script file for usage. +After opening a PR, describe your changes in a file in the `changelog_unreleased` directory following the template [`changelog_unreleased/TEMPLATE.md`](changelog_unreleased/TEMPLATE.md) and commit this file to your PR. You can use `yarn gen:changelog` to generate a changelog file. Please see comments of the script file for usage. + +## Other Take a look at [`commands.md`](commands.md) and, if you know Haskell, check out [Wadler's paper](http://homepages.inf.ed.ac.uk/wadler/papers/prettier/prettier.pdf) to understand how Prettier works. diff --git a/package.json b/package.json index 9d692bdca..6dbfd7dbf 100644 --- a/package.json +++ b/package.json @@ -180,6 +180,7 @@ "fix:prettier": "yarn lint:prettier --write", "build": "node ./scripts/build/build.js", "build:website": "node ./scripts/build-website.js", + "gen:changelog": "node ./scripts/generate-changelog.js", "debug": "node bin/prettier.js --ignore-path=.prettierignore" }, "c8": { diff --git a/scripts/generate-changelog.js b/scripts/generate-changelog.js old mode 100644 new mode 100755