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

tag go module v0.1.0 #10

Closed
enr0n opened this issue Jan 1, 2020 · 1 comment
Closed

tag go module v0.1.0 #10

enr0n opened this issue Jan 1, 2020 · 1 comment
Assignees

Comments

@enr0n
Copy link
Collaborator

enr0n commented Jan 1, 2020

Moving to Go modules is straight forward, but one thing to consider is whether this package should change its import path. Right now, we do not use the canonical import path (a vestige from before moving the package to its final home). This means that if your source files are goimports -s-ed, then you have:

import (
        vici "github.com/strongswan/govici"
)

Since this is not best practice for a package, I would like to use migration to Go modules as an opportunity to make sure this package does follow best practices.

I think the simplest option is to initialize the go module as github.com/strongswan/govici, and move the existing *.go files to vici/ sub-directory. This does mean that existing users of the package will have to change their import paths to github.com/strongswan/govici/vici when they uprev to v0.1.0.

@enr0n enr0n self-assigned this Jan 1, 2020
enr0n added a commit that referenced this issue Jan 1, 2020
Initialize go module as github.com/strongswan/govici, and set minimum Go
version to 1.11.

While migrating to modules, create subdirectory vici/ so that the
package can have a canonical import path. While this does require users
to change their import path, the impact is minimal.

Finally, update any references to the old import path in README.md and
docs/getting_started.md.

Related: #10

Signed-off-by: Nick Rosbrook <nr@enr0n.net>
enr0n added a commit that referenced this issue Jan 6, 2020
Initialize go module as github.com/strongswan/govici, and set minimum Go
version to 1.11.

While migrating to modules, create subdirectory vici/ so that the
package can have a canonical import path. While this does require users
to change their import path, the impact is minimal.

Finally, update any references to the old import path in README.md and
docs/getting_started.md.

Related: #10

Signed-off-by: Nick Rosbrook <nr@enr0n.net>
@enr0n
Copy link
Collaborator Author

enr0n commented Jan 6, 2020

@enr0n enr0n closed this as completed Jan 6, 2020
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

1 participant