Last active
May 26, 2021 11:48
-
-
Save wneessen/d97237e5c07633a4e2d0d3f6e6ec380b to your computer and use it in GitHub Desktop.
This file contains hidden or 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
## Shipping package | |
PROTO_ROOT_DIR = $(shell brew --prefix)/Cellar/protobuf/3.14.0/include | |
PROJECT_NAME = TESTGRPC | |
## Dart requires you to manually ship all google provided proto files too. | |
_gendart: | |
@mkdir -p model/gen/ship/dart | |
@protoc --dart_out=grpc:model/gen/ship/dart -I proto proto/server.proto --plugin=protoc-gen-dart=$$HOME/.pub-cache/bin/protoc-gen-dart | |
@protoc -I$(PROTO_ROOT_DIR) --dart_out=model/gen/ship/dart $(PROTO_ROOT_DIR)/google/protobuf/*.proto --plugin=protoc-gen-dart=$$HOME/.pub-cache/bin/protoc-gen-dart | |
_gengo: | |
@mkdir -p model/gen | |
@protoc -I=proto/ --go_out=plugins=grpc:model/gen proto/server.proto --plugin=protoc-gen-go=$$HOME/go/bin/protoc-gen-go | |
gen: _gengo _gendart | |
build: gen | |
@env GOOS=linux GOARCH=amd64 go build -o server | |
install: gen | |
@cp config_template.json config.json |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment