Skip to content
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

Automate releasing #539

Merged
merged 6 commits into from Sep 13, 2019
Merged

Automate releasing #539

merged 6 commits into from Sep 13, 2019

Conversation

carhartl
Copy link
Member

@carhartl carhartl commented Sep 12, 2019

Another part of the ongoing effort of modernizing the codebase. Since we now need to provide different variants/distributions of the library (module/nonmodule including minified versions), we aim for fully automating publishing to npm, as to avoid errors during the process.

We start using release-it for fully automating both publishing to npm as well as creating releases on GitHub. Those GitHub releases do contain the minified sources, thus we're able to address #501.

  • Set up release-it
  • Adapt readme

@FagnerMartinsBrack
Copy link
Member

FagnerMartinsBrack commented Sep 12, 2019

I started doing something a long time ago but went nowhere cause I didn't finish it: https://github.com/js-cookie/js-cookie-release

This will allow for easier, automated bumping during releasing.
This configuration supplies publishing to npm along with making a
release on GitHub with additional assets to be uploaded (in particular
minified versions for both the module and nonmodule variants).
@carhartl carhartl marked this pull request as ready for review September 13, 2019 08:53
@carhartl
Copy link
Member Author

@FagnerMartinsBrack I see... I came across release-it, and it seems rather powerful, and as far as I can see it does all we need for our automated release process.

@FagnerMartinsBrack
Copy link
Member

My concern with a third party release tool is that history tells (as of Java Maven, some Grunt packages, etc.) that there seems to be no tool that can generalize all release process steps for all projects. At some point, the projects end up having either too many configurations or missing features that force project authors to automate their own process using a higher level language (bash, some node scripts, etc.).

In the case of release-it, it may or may not create that problem. js-cookie is pretty small so it should be easy to change in the future if we need to. In regards to NPM and NodeJS, they're pretty well integrated, so I guess there's a slim chance that the community follows enough conventions that allow it to fit into js-cookie so that we won't need to change the dependency at any time in the future

I guess we'll only know in hindsight 😆

This doesn't seem to provide value. We may have to craft release notes
manually for a GitHub release (thus we keep creating the release as a
draft).
@carhartl
Copy link
Member Author

Should we introduce a CHANGELOG.md file in the project, instead of crafting release notes for a GitHub release? Either way, this would be the only manual step left in the release process...

(Probably doesn't matter much, we won't be releasing all the time, with many changes..?!)

@carhartl
Copy link
Member Author

At some point, the projects end up having either too many configurations or missing features that force project authors to automate their own process using a higher level language (bash, some node scripts, etc.).

So far release-it provided everything I expected nicely and it's easy to use and configure, thus good enough (for me). I try to be a bit pragmatic and really really want to avoid a "not invented here" type of thing going on.

@carhartl
Copy link
Member Author

PS: And to me it's an improvement over a manual process in any case. Sorry for not picking up the work that had once been started on this.

@FagnerMartinsBrack
Copy link
Member

Sorry for not picking up the work that had once been started on this.

I'm glad you didn't. I'm not even sure that effort would give a meaningful ROI anyway

@FagnerMartinsBrack
Copy link
Member

Don't forget to move the latest tag to the latest release. That way it doesn't break README links relying on /latest

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

Successfully merging this pull request may close these issues.

None yet

2 participants