Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Semantic release tech talk

Sponsored · SiteGround - Reliable hosting with speed, security, and support you can count on. →

Semantic release tech talk

Apiary internal tech talk about Semantic release

Jakub Mikulas

June 10, 2016

Transcript

16 slides
  1. Semantic-release Automated package publishing Takes care of publishing and versioning.

    Helps with keeping changes trackable. Scary docs https://github.com/semantic-release/semantic-release But in reality, it's pretty simple
  2. ☞ feat: A new feature ☞ fix: A bug fix

    ☞ docs: Documentation only changes ☞ style: Changes that do not affect the meaning of the code ☞ refactor: A code change that neither fixes a bug nor adds a feature ☞ perf: A code change that improves performance ☞ test: Adding missing tests ☞ chore: Changes to the build process or tools
  3. How do they know? Semantic-release will decide on next version

    number according to type of commits you are merging. For example - docs won't even release - bug will do a patch You can note a breaking change (thus forcing major) by adding text BREAKING CHANGE in your commit message You can also do dry-run before pushing.
  4. Getting it to the repo See this PR as a

    reference github.com/apiaryio/bob/pull/8 ➀ Install deps (semantic-release, commitizen, cz- conventional-changelog, condition-circle) ➁ Setup GH_TOKEN and NPM_TOKEN (with CLI tool) ➂ Update package.json (crazy, raqe-inducing part) ➃ Add npm run semantic-release || true to CI deploy step
  5. End notes ☞ Video tutorial on setup: https://egghead.io/lessons/javascript- how-to-write-a-javascript-library-automating-releases-with- semantic-release

    ☞ Semantic-release is also fully pluggable ☞ Your versioning should start at 1.0.0 (per npm recommendation)

More Decks by Jakub Mikulas

Other Decks in Technology