This procedure list is inspired by Eleventy's release instructions.
-
Create a new release branch. The
main
branch should already contain all changes to be included in the release.git s main git pull # Replace X, Y, and Z with the correct numbers for # the version about to be released. git s -c release/vX.Y.Z
-
Check that dependencies are up to date.
npm outdated
[!TIP] All of the
prettier-<version>
dependencies will show up as outdated. This is expected. -
Make sure the lockfile is fresh.
rm -rf node_modules rm -f package-lock.json npm install
-
Run an audit and fix issues.
npm audit
-
Make sure
npm run lint
runs okay. -
Make sure
npm run test
runs okay. -
Update
version
in package.json. -
Check in all changes and commit.
-
Tag the new version
git tag vX.Y.Z
-
Push release branch to GitHub and create a PR to
main
. Make sure to also push tags.git push --tags -u origin <branch-name>
-
Make sure the PR checks run successfully.
-
Publish to NPM
npm publish
-
Create a GitHub release from the new tag.
-
On this branch, update the changelog by copy-pasting the release description from GitHub. Commit and push the changes.
-
Merge the PR.