-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixes #11, add gRPC to/from DB type converter
- Loading branch information
Showing
5 changed files
with
832 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -14,19 +14,25 @@ internal/ml_metadata/proto/%.pb.go: api/grpc/ml_metadata/proto/%.proto | |
.PHONY: gen/grpc | ||
gen/grpc: internal/ml_metadata/proto/metadata_store.pb.go internal/ml_metadata/proto/metadata_store_service.pb.go | ||
|
||
internal/converter/generated/converter.go: internal/converter/*.go | ||
goverter -packageName generated -output ./internal/converter/generated/converter.go github.com/opendatahub-io/model-registry/internal/converter/ | ||
|
||
.PHONY: gen/converter | ||
gen/converter: gen/grpc gen/graph internal/converter/generated/converter.go | ||
|
||
.PHONY: gen/graph | ||
gen/graph: internal/model/graph/models_gen.go | ||
|
||
internal/model/graph/models_gen.go: api/graphql/*.graphqls gqlgen.yml | ||
go run github.com/99designs/gqlgen generate | ||
gqlgen generate | ||
|
||
.PHONY: vet | ||
vet: | ||
go vet ./... | ||
|
||
.PHONY: clean | ||
clean: | ||
rm -Rf ./model-registry internal/ml_metadata/proto/*.go internal/model/graph/models_gen.go | ||
rm -Rf ./model-registry internal/ml_metadata/proto/*.go internal/model/graph/models_gen.go internal/converter/generated/converter.go | ||
|
||
bin/go-enum: | ||
GOBIN=$(PROJECT_BIN) go install github.com/searKing/golang/tools/[email protected] | ||
|
@@ -58,7 +64,7 @@ build: gen vet lint | |
go build | ||
|
||
.PHONY: gen | ||
gen: gen/grpc gen/graph | ||
gen: deps gen/grpc gen/graph gen/converter | ||
go generate ./... | ||
|
||
.PHONY: lint | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.