-
Notifications
You must be signed in to change notification settings - Fork 25
Release Process
Stop all yarn start
or yarn serve
commands.
To release the latest code, you'll need the latest code 😄.
git checkout master
git pull
To ensure a clean release, you'll want to make sure that generated assets are created as cleanly as possible.
- The
npm publish
command will package up everything indist/
and publish to NPM. - The
npm run ghpages
command will push files inpublic/
.
# Clean up generated files
rm -rf dist public _tmp
The prepublish
script will handle recompiling assets before things get sent to NPM.
Development dependencies should be reinstalled to minimize the chances for unexpected errors.
yarn install:clean
The npm get registry
command should respond with the public NPM registry (https://registry.npmjs.org/
at the time of writing this document).
$ npm get registry
https://registry.npmjs.org/
This should be handled by the project .npmrc
configuration, but different versions of the npm
command may respond differently.
The npm whoami
command should respond with "helix-ui".
$ npm whoami
helix-ui
If npm whoami
returns a different value or no value, STOP!
Ask a HelixUI dev for help, before you continue.
Given that the release tasks will update package.json
, we want to make sure we stick to a feature branch workflow so that we can merge the version changes back into master
.
The name of this branch doesn't matter, but it does need to be based off master
.
A good naming convention to follow is release-{VERSION}
(e.g., release-v0.16.1
)
git checkout -t -b release-{VERSION}
npm already has logic built-in to bump the version number.
Run npm help version
for more information.
WARNING: npm currently does not have a dry run option. Start with premajor
, preminor
, or prepatch
to make sure everything is running smoothly before you publish.
npm version (major | minor | patch | premajor | preminor | prepatch | prerelease)
Say we're currently at 0.0.1
of HelixUI.
npm version prepatch # 0.0.2-rc.0
npm version prerelease # 0.0.2-rc.1
npm version patch # 0.0.2
npm version preminor # 0.1.0-rc.0
npm version prerelease # 0.1.0-rc.1
npm version minor # 0.1.0
npm version premajor # 1.0.0-rc.0
npm version prerelease # 1.0.0-rc.1
npm version major # 1.0.0
NOTE: This step requires npm whoami
to be set up correctly.
To publish new assets to NPM, just run:
npm publish
Check the version displayed for the helix-ui package on npmjs.com.
Check the output of:
npm view helix-ui version versions
Because npm version
uses and modifies package.json
, you'll need to merge changes back into master so that future releases will start with the correct version.
- Push your branch to github
- Submit a PR against the
master
branch - Merge the PR
- Delete version branch
Documentation is published separately from npm assets. This process can be run independently of the release to push updated documentation without the need to release new NPM assets.
There are two types of documentation:
- Production Docs
- Pre-release Docs
Documentation for functionality that is available on NPM.
URL: https://helixdesignsystem.github.io/helix-ui/
Publish the latest docs, you'll need the latest code.
git checkout master
git pull
npm run ghpages
Documentation for functionality that is not yet available on NPM.
URL: https://helix-ui.netlify.com
- Log in to https://app.netlify.com/
- Open the "helix-ui" site
- Navigate to "Deploys"
- From the "Trigger Deploy" dropdown menu, click "Deploy Site".
- Wait for Netlify to report status