examples: update Go example (#7217)
Update the Go example to use Go modules: Move the example into a directory containing a go.mod file, change the installation instructions to use "go install". Update the go_package option in addressbook.proto to an actual module path. Update examples to use the google.golang.org/protobuf/proto module.pull/9137/head
parent
42db8a3f96
commit
c8dfe32b5a
9 changed files with 41 additions and 39 deletions
@ -0,0 +1,5 @@ |
||||
module github.com/protocolbuffers/protobuf/examples/go |
||||
|
||||
go 1.14 |
||||
|
||||
require google.golang.org/protobuf v1.27.1 |
@ -0,0 +1,6 @@ |
||||
github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= |
||||
github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= |
||||
golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= |
||||
google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= |
||||
google.golang.org/protobuf v1.27.1 h1:SnqbnDw1V7RiZcXPx5MEeqPv2s79L9i7BJUlG/+RurQ= |
||||
google.golang.org/protobuf v1.27.1/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= |
Loading…
Reference in new issue