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

pkgVersionFromGit indiscriminately say "latest tag" even if -git_revision is used #119

Open
anthonyfok opened this issue Nov 29, 2019 · 1 comment

Comments

@anthonyfok
Copy link
Member

anthonyfok commented Nov 29, 2019

(Note-to-self to fix a minor bug that I introduced myself.)

Since around dh-make-golang v0.2.0, pkgVersionFromGit() would print log messages like the following:

    log.Printf("Found latest tag %q", latestTag)
    log.Printf("WARNING: Latest tag %q is not a valid SemVer version\n", latestTag)
    log.Printf("Latest tag %q matches master", latestTag)

saying it is the "latest tag" even if the user had specify an older tag -git_revision.

For example, even if the actual latest release is v1.1.9, the log message claims v1.1.2 is the latest:

$ dh-make-golang make -git_revision v1.1.2 github.com/yuin/goldmark
2019/11/29 14:02:38 Downloading "github.com/yuin/goldmark/..."
2019/11/29 14:02:39 Determining upstream version number
2019/11/29 14:02:39 Found latest tag "v1.1.2"
2019/11/29 14:02:39 Latest tag "v1.1.2" matches master
2019/11/29 14:02:39 Package version is "1.1.2"
@anthonyfok anthonyfok added this to the v0.4.0 milestone Mar 3, 2020
@creekorful creekorful removed this from the v0.4.0 milestone Aug 2, 2021
@creekorful
Copy link
Member

(removing from milestone since already released)

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

No branches or pull requests

2 participants