Skip to content

Commit 79aec49

Browse files
authored
Update code generate to use google/golang instead of gogo (#18)
* Update to use google.golang.org/protobuf instead of gogo/protobuf * Clean up unused things
1 parent 448c833 commit 79aec49

File tree

12 files changed

+1688
-788
lines changed

12 files changed

+1688
-788
lines changed

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@ debug
55
*.DS_Store
66
*.bak
77
*.log
8-
*.report
8+
*.report

Gopkg.lock

Lines changed: 0 additions & 221 deletions
This file was deleted.

Gopkg.toml

Lines changed: 0 additions & 13 deletions
This file was deleted.

Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,15 +8,15 @@ SRCROOT_IN_CONTAINER := /go/src/$(PROJECT_ROOT)
88
DOCKERPATH := /go/src
99
DOCKER_RUNNER := docker run --rm
1010
DOCKER_RUNNER += -v $(SRCROOT_ON_HOST):$(SRCROOT_IN_CONTAINER)
11-
DOCKER_GENERATOR := infoblox/atlas-gentool:v19.1
11+
DOCKER_GENERATOR := infoblox/atlas-gentool:latest
1212
GENERATOR := $(DOCKER_RUNNER) $(DOCKER_GENERATOR)
1313

1414
default: install
1515

1616
.PHONY: options
1717
options:
1818
@$(GENERATOR) \
19-
--gogo_out="Mgoogle/protobuf/descriptor.proto=github.com/gogo/protobuf/protoc-gen-gogo/descriptor:$(DOCKERPATH)" \
19+
--go_out=":$(DOCKERPATH)" \
2020
options/query_validate.proto
2121

2222
.PHONY: install

example/example.pb.atlas.query.validate.go

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,9 @@
1-
// Code generated by protoc-gen-gogo. DO NOT EDIT.
2-
// source: example/example.proto
1+
package example
32

4-
package example // import "github.com/infobloxopen/protoc-gen-atlas-query-validate/example"
5-
6-
import options "github.com/infobloxopen/protoc-gen-atlas-query-validate/options"
7-
import query "github.com/infobloxopen/atlas-app-toolkit/query"
8-
import _ "github.com/golang/protobuf/ptypes/wrappers"
9-
10-
// Reference imports to suppress errors if they are not otherwise used.
3+
import (
4+
query "github.com/infobloxopen/atlas-app-toolkit/query"
5+
options "github.com/infobloxopen/protoc-gen-atlas-query-validate/options"
6+
)
117

128
var ExampleMethodsRequireFilteringValidation = map[string]map[string]options.FilteringOption{
139
"/example.TestService/List": map[string]options.FilteringOption{

go.mod

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
module github.com/infobloxopen/protoc-gen-atlas-query-validate
2+
3+
go 1.16
4+
5+
require (
6+
github.com/grpc-ecosystem/grpc-gateway/v2 v2.5.0 // indirect
7+
github.com/infobloxopen/atlas-app-toolkit v0.24.1-0.20210416193901-4c7518b07e08
8+
google.golang.org/protobuf v1.27.1
9+
)

0 commit comments

Comments
 (0)