-
Notifications
You must be signed in to change notification settings - Fork 17.7k
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
x/exp/cmd/gorelease: accept any release version when inferring base version of untagged repo #40267
Comments
It seems like it's better to require an explicit Could you say more about why you wouldn't start with |
I´m adding experimental support for I´m afraid I don´t have a good answer for why someone would use this parameter, I´m just a man-in-the-middle, but I guess people don´t like to start a project with a low minor version for the fear of not getting adoption due to the inmaturity connotations associated to low I´ve done a quick manual github search looking for initial version patterns in popular libraries and most of them starts with
It is easy for my to add some lines of code in the pipeline to check if the repo doesn´t have any tag and add an explicit As a data point, I had to dive into the code to understand why it was failing when using |
Sorry for the slow response to this. My understanding of the bug is this:
Could you elaborate on this, @qmuntal ? Could you provide the error message you're seeing, and maybe describe what's confusing about it so that we can analyse whether some error messages can be made more explicit? (is it the "could not find base version" message above?) |
After a quick chat with Jay, we're going to:
|
Change https://golang.org/cl/320229 mentions this issue: |
@jadekler What I was seeing is the "could not find base version" error message. The change done in CL320229 will improve the situation, thanks for that. |
Change https://golang.org/cl/349997 mentions this issue: |
As part of #40267, 'go install' is now fully responsible for building and installing executables. 'go get' will only be used to change versions in go.mod. The -d flag no longer has any effect; its behavior is the default. When 'go get' is invoked inside a module on a main package outside of the main module, it no longer prints any warning. In 1.16-1.17, we suggested using -d in this situation, but we want 'go get example.com/cmd' to be able to upgrade a tool dependency without needing -d to suppress the warning. For #43684 Change-Id: I9daf29c123a5a0e382aa326d62721cb26fc26c19 Reviewed-on: https://go-review.googlesource.com/c/go/+/349997 Trust: Jay Conrod <[email protected]> Run-TryBot: Jay Conrod <[email protected]> TryBot-Result: Go Bot <[email protected]> Reviewed-by: Bryan C. Mills <[email protected]>
gorelease
should always fallback tonone
when inferring the base version in repositories without available versions.The current implementation only fallbacks to
none
whenreleaseVersion
isx.0.0
|0.0.1
|0.1.0
and fails one other situations. This behavior is not a semver requirement and despite being a good practice it may be too strict for modules which are required to start the version with other minor or patch numbers for whatever business, technical or legacy reason.The text was updated successfully, but these errors were encountered: