Skip to content

feat(ci): automate build and releases #215

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 15 commits into from
Nov 26, 2019
Merged

Conversation

bcarroll22
Copy link
Contributor

What:

This pull request allows new versions of PRC to automatically increment and release new versions to NPM and Github based on parsing the commit messages. It also runs the tests in all currently supported stable versions of node and makes sure lint rules pass. Finally, whenever the build is triggered by a weekly chron job, the tests will run using react@next as requested by the React team.

Why:

Manually releasing can be tedious, and automating the process really improves efficiency. Additionally, if the releases happen automatically, folks who create pull requests to fix an issue they're seeing with their use case, we can quickly get them a release that fixes the issue. The faster we can release, the better we support ourselves and our users.

How:

This mostly relies on semantic-release and commitizen. As long as the format is followed, everything will be automated for us. The only thing we have to do differently is make sure that any merge commit follows the conventional commit format, which is very easy to follow. As long as the parser sees a conventional commit on a build, it will:

  • Increment the version number
  • Publish a new build to NPM
  • Publish the release artifact to Github
  • Generate a changelog using the messages of the commits

Checklist:

  • Documentation added/updated (N/A)
  • Typescript definitions updated (N/A)
  • Tests added and passing (N/A)
  • Ready to be merged

So for example, the current version of PRC is v1.23.3. When this is merged, my commit message would be something like:

feat(ci): automate build and releases

So, when merged, this will:

  • Increment the version of the package to v1.24.0
  • Publish v1.24.0 to NPM
  • Publish the dist artifact of v1.24.0 to Github
  • Include the commit messages from the release in the release's notes

@bcarroll22 bcarroll22 force-pushed the feature/travis-improvements branch from 719537c to 45b7482 Compare November 26, 2019 16:53
@mrbinky3000 mrbinky3000 merged commit f27cc2a into master Nov 26, 2019
@mrbinky3000 mrbinky3000 deleted the feature/travis-improvements branch November 26, 2019 18:43
@bcarroll22
Copy link
Contributor Author

🎉 This PR is included in version 1.24.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants