Skip to content
This repository has been archived by the owner on Jan 27, 2021. It is now read-only.

add module version to module path #25

Merged
merged 2 commits into from
Feb 4, 2020
Merged

add module version to module path #25

merged 2 commits into from
Feb 4, 2020

Conversation

C0rby
Copy link
Contributor

@C0rby C0rby commented Feb 4, 2020

The module version must be in the path. See https://github.com/golang/go/wiki/Modules#semantic-import-versioning for more information.

If the module is version v2 or higher, the major version of the module must be included as a /vN at the end of the module paths used in go.mod files (e.g., module github.com/my/mod/v2, require github.com/my/mod/v2 v2.0.1) and in the package import path (e.g., import "github.com/my/mod/v2/mypkg"). This includes the paths used in go get commands (e.g., go get github.com/my/mod/v2@v2.0.1. Note there is both a /v2 and a @v2.0.1 in that example. One way to think about it is that the module name now includes the /v2, so include /v2 whenever you are using the module name).

@C0rby C0rby requested a review from refs February 4, 2020 15:36
@update-docs
Copy link

update-docs bot commented Feb 4, 2020

Thanks for opening this pull request! The maintainers of this repository would appreciate it if you would create a changelog item based on your changes.

Copy link
Member

@refs refs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

True... this... 👍

@C0rby C0rby merged commit 8285d0f into master Feb 4, 2020
@delete-merged-branch delete-merged-branch bot deleted the bugfix/module-version branch February 4, 2020 16:06
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants