To publish the npm package, you'll need an npm account, and you'll need to be added to the list of maintainers by one of the current RoverUI maintainers.
- Checkout a release branch of some kind: (e.g.
release-2.0.4
ornew-v2.1.4
) - Following semver as your version guide, use the script
yarn new-version [value]
to bump the version. Seeyarn version
docs for more info- For
patch
:yarn new-version --patch
- For
minor
:yarn new-version --minor
- For
major
:yarn new-version --major
- For other:
yarn new-version --new-version 3.4.11
- For
- Open a PR for that branch
- Once you have at least one PR approval from an admin and no pending requests for changes, you can merge in to master.
- After your pull request is merged, follow this process:
git checkout master && git fetch -p && git reset --hard origin/master
yarn publish
- Ask an admin to push your new version's tag to GitHub.
If you're an admin, you can commit directly to master
. The process is much more streamlined.
- Reset your master:
git checkout master && git fetch -p && git reset --hard origin/master
yarn version --patch
(or whatever version bump you are making)yarn publish
(also pushes new tag to GitHub)git push
to push yourmaster
branch with the updated CHANGELOG.md generated by our publish scripts
After your tag is published, you should create a GitHub release from it.
- Find your tag, and compare it to the previous version by tag. Here's an example.
- From the Releases page, draft a new release.
- The title should be the same as the tag name, i.e. "v3.0.0"
- The description should be broken out into sections matching the conventional commit types, i.e. "Breaking changes", "Features", "Fixes", etc.
- You should be able to copy the list of features, fixes, etc. from the changelog, assuming your deploy followed the instructions.
- Ideally, the commits should be human-readable and clear, but you may want to do some light editing.
- When you're satisfied, publish the release.
By default, our Storybook docs are published automatically using . If there is an issue with this release or you need to publish this manually, use the following command:
yarn storybook:deploy
You should only do this if you're an admin. Instructions based loosely on Prereleases and Npm
Edit the version in package.json
manually. Pre-release versions should be named in this format:
v{MAJOR}.0.0-alpha.{BUILD}
"MAJOR" is the intended major version. Each time you deploy a new alpha build, increment the "BUILD" number.
For example, v4.0.0-alpha.1
is the first iteration of what will one day become v4.
Then, from the command line:
gco -b v{MAJOR}.0.0 # E.g. gco -b v5.0.0
yarn update-changelog
git add .
git commit -m "Deploying v{MAJOR}.0.0-alpha.{BUILD}" # E.g. git commit -m "Deploying v5.0.0-alpha.2"
git push
git tag v{MAJOR}.0.0-alpha.{BUILD} # E.g. git tag v5.0.0-alpha.2
git push --tags
npm publish --tag next