This is the documentation that will be used by the maintainers. If you have ideas on how to do things better, please let us know by creating an issue or PR 😉.
We have several labels that can be used to organize issues and PRs on this repo and also to make the changelog generation easier. All the labels and their descriptions can be read here. Any other PRs that hasn't labeled with one of these will not be shown on the changelog. Please take a look at the table below
Label | Section |
---|---|
enhancement | Implemented enhancements |
bug | Fixed bugs |
documentation | Documentation changes |
meta | Meta changes |
To fully release a new version, you need to have access to the @materializecss organization on the npmjs. Then, please follow the steps below:
-
In your local copy of Materialize, go into the dev Branch with
git checkout v2-dev
and pull the newest version withgit pull origin v2-dev
to have the newest version from the server. Run Tests and check if everything works. -
Create a new Release branch with
git checkout -b release-2.X.X-alpha
. In case something happend or needs to be changed during the release it is better to keep the release on its own branch. -
Run
npm run release -- --oldver=<current_version> --newver=<new_version>
What this command does is that it will replace any occurrences of "<current_version>" with the "<new_version>". So for example, if the current release is1.0.0
, and then the planned release is1.1.0
, the command would benpm run release -- --oldver=1.0.0 --newver=1.1.0
-
Verify that the version is correctly replaced and files were generated in:
- package.json
- src/index.ts
- dist/js
- dist/css
-
Add Commit with message "chore: release 2.X.X-alpha". Then push to server.
-
Create a Pull Request (PR) (example so that we can verify nothing goes wrong, address the feedback from the reviewers if there is any
-
Create a new (draft) release on GitHub
- Click generate Release notes automatically and select previeous version (commit-lint of commit-messages is important here)
- Upload the
materialize-v<new_version>.zip
from the bin-folder - Create a new tag together with the release
-
Merge the Pull Request if all checks pass and there were no concerns.
- Set the draft release to public.
-
Checkout and pull the new main-branch locally, merge it back into the dev-branch. Then push to server. Explanation here
git pull origin main git checkout v2-dev git pull origin v2-dev git merge main git push origin v2-dev
-
Publish the release on npmjs
- If you never logged in on npm, please do
npm login
first and enter your credentials - Then run
npm publish
and follow the instructions there
- Done! Yay new version 🥳