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

Debian: Versioning issue with v2 in build path #1750

Closed
utkarsh2102 opened this issue Jun 29, 2020 · 2 comments
Closed

Debian: Versioning issue with v2 in build path #1750

utkarsh2102 opened this issue Jun 29, 2020 · 2 comments

Comments

@utkarsh2102
Copy link
Contributor

Hi,

I see the following line in the release notes:

Note for package maintainers: build paths were changed in this version to conform with the go.mod specification for projects with a semantic version >=2.0.0 (see #1638). If you are building micro, it is highly recommended that you use the provided makefile, or update your build scripts to build with the new v2 path for build tags.

And with this, I added this: https://salsa.debian.org/go-team/packages/micro/-/commit/9b9c01a89177acb9629f385ec14293eee1a1cb0b
However, this reintroduces the previous bug which tampers with the versioning.
So after the above commit, if I try to check the version, I get:

➜ micro --version     
Version: 0.0.0-unknown

So I reverted this for now, and now when I check the version, I get:

➜ micro --version
Version: 2.0.6

which is what it should be!

I am not sure what's wrong, the debian/rules (which is a Makefile) could be found here:
https://salsa.debian.org/go-team/packages/micro/-/blob/debian/sid/debian/rules

@zyedidia
Copy link
Owner

Does the go.mod file used in the build start with the line

module github.com/zyedidia/micro/v2

This defines the build path as having v2 in it.

@utkarsh2102
Copy link
Contributor Author

Ah, crap! I am so stupid!
You're right, I am not sure why I changed the -ldflags 🤦‍♂️

In Debian, we just take the source as it is (without any changes) so we didn't require any change.
Thanks for this and sorry for the noise! 🤦‍♂️

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