-
-
Notifications
You must be signed in to change notification settings - Fork 4
Conversation
The Go language is make Go modules its official dependency mechanism. https://www.kablamo.com.au/blog/2018/12/10/just-tell-me-how-to-use-go-modules This commit initializes Go modules and removes `govendor` references. Go modules can be vendored, but don't need to. This commit removes the `vendor/` directory.
Testing deploy to Heroku. Before:
After:
|
# Update Go dependencies | ||
govendor sync | ||
# Get dependencies | ||
go get -u ./... |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is the ./...
just an alias for the repo url?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The go get
command adds dependencies (which could be "modules" or "packages")
to the current development module and then builds and installs them.
It accepts arguments and its first step is to resolve which dependencies to add.
We could provide a single name as an argument like
go get golang.org/x/text
or we could provide patterns like
go get golang.org/x/perf/cmd/...
The argument is a pattern if it includes one or more ...
wildcards.
A pattern expands to all package directories found in the directory tree
with names matching the patterns.
So, go get -u ./...
is saying "get all the dependencies that are found
in this directory (./
) and recursively within that directory (...
)."
@@ -0,0 +1,6 @@ | |||
github.com/gorilla/feeds v0.0.0-20170611032206-fa8f5548eedb h1:ry27SfzOHgpUX1TXYh1W/kOUM7J+K8MdpRygT0DtHy0= |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this was automatically generated? (I don't know go
😹)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes! It is generated. FAQs — go.mod and go.sum
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't know go
, but I had some free time. 😸
The Go language is making Go modules its official dependency mechanism.
This commit initializes Go modules and removes
govendor
references.Go modules can be vendored, but don't need to.
This commit removes the
vendor/
directory.