phrase / phrase-cli

CLI for the Phrase API
https://developers.phrase.com
MIT License
42 stars 6 forks source link

Major semver tag #145

Open jimmymcpeter opened 2 months ago

jimmymcpeter commented 2 months ago

Would it be possible to add and maintain a major semver tag? For example, as of writing this, v2 would match the latest 2.25.0 release. If you release 2.26.0 next week, then v2 would then be updated to match that. I currently use the Phrase CLI from the phrase/setup-cli GitHub Action and am trying to reduce the manual update maintenance.

theSoenke commented 2 months ago

Hi @jimmymcpeter, maybe this could also be solved by introducing a latest version in the setup-cli GitHub action. And major CLI versions would then also be a major GitHub action version. But in your case do you actually always need the latest feature of the CLI? Most updates introduce for example new endpoints but if you don't always need the most recent API additions older v2 version might be sufficient as well

jimmymcpeter commented 2 months ago

Hi, unfortunately I wouldn't use latest because it doesn't avoid major semver (breaking) changes. I'd prefer to pass version: 2.x to the phrase/setup-cli action if you didn't want to do a v2 tag on the phrase-cli repo. The actions/setup-node action supports semver like this along with aliases like latest if you want to take a look -- https://github.com/actions/setup-node/blob/main/src/distributions/installer-factory.ts#L15

But in your case do you actually always need the latest feature of the CLI?

To sum it up, I'd like to get minor and patches automatically. Dependabot can't automate this since you must pass an explicit version to phrase/setup-cli. Every time you release a new CLI, my logs are constantly printing "Please consider updating the Phrase Strings CLI client (xxxx < 2.26.0). You can get the latest version from https://phrase.com/cli." until I go update the version by hand.