littlehorse-enterprises / littlehorse

This repository contains the code for the LittleHorse Server, CLI, and Java/Go/Python SDK's. Brought to you by LittleHorse Enterprises LLC
https://littlehorse.dev/
Other
64 stars 6 forks source link

Properly Tag `sdk-go` Releases #814

Open coltmcnealy-lh opened 1 month ago

coltmcnealy-lh commented 1 month ago

In GoLang, if you want to have properly tagged releases, you need to prefix the git tags with a v.

We currently don't do that since we are following Semantic Versioning. The result is that, when I do the following:

go get github.com/littlehorse-enterprises/littlehorse/sdk-go@0.9.0

my go.mod has the following entry:

require github.com/littlehorse-enterprises/littlehorse v0.0.0-20240516033734-7b120ed34cc9

It should look like:

require github.com/littlehorse-enterprises/littlehorse v0.9.0

Potential Fixes

The only way I know of to fix this is that we would have to add a new git tag for each release, prefixed with the v.

Things to Break

We will insist on Semantic Versioning for the rest of the project, which means no v prefix for our sdk-java, sdk-python, sdk-js, lh-standalone, lh-dashboard, and lh-server artifacts.

I just propose that we push a second tag with the v prefix in our local-dev/bump.sh script, and that we configure our release pipeline to ignore anything starting with a v. Everything else stays the same.

mijailr commented 1 month ago

We can use just one tag v0.9.x and make the components that don't need the prefix to ignore it while building the artifacts. I would prefer to not have double tags.

coltmcnealy-lh commented 1 month ago

@mijailr I think I agree with you. Having two Git Tags would be wrong, but as long as we can properly tag everything else, we can still comply with semantic versioning.

@eduwercamacaro is this okay with you?

This ticket can wait until after the Stabilization Period but it should happen before 1.0.0.