1616 DEFAULT_BUILD_FILENAME := StealthIMFileAPI
1717endif
1818
19+ .PHONY : run
1920run : build
2021 ./bin/$(DEFAULT_BUILD_FILENAME )
2122
@@ -31,10 +32,10 @@ StealthIM.DBGateway/db_gateway_grpc.pb.go StealthIM.DBGateway/db_gateway.pb.go:
3132StealthIM.MSAP/msap_grpc.pb.go StealthIM.MSAP/msap.pb.go : proto/msap.proto
3233 $(PROTOCCMD ) --plugin=protoc-gen-go=$(PROTOGEN_PATH ) --plugin=protoc-gen-go-grpc=$(PROTOGENGRPC_PATH ) --go-grpc_out=. --go_out=. proto/msap.proto
3334
34-
35+ .PHONY : proto
3536proto : ./StealthIM.FileAPI/fileapi_grpc.pb.go ./StealthIM.FileAPI/fileapi.pb.go StealthIM.FileStorage/filestorage_grpc.pb.go StealthIM.FileStorage/filestorage.pb.go ./StealthIM.DBGateway/db_gateway_grpc.pb.go ./StealthIM.DBGateway/db_gateway.pb.go ./StealthIM.MSAP/msap_grpc.pb.go ./StealthIM.MSAP/msap.pb.go
3637
37-
38+ .PHONY : build
3839build : ./bin/$(DEFAULT_BUILD_FILENAME )
3940
4041./bin/StealthIMFileAPI.exe : $(GO_FILES ) proto
@@ -43,9 +44,11 @@ build: ./bin/$(DEFAULT_BUILD_FILENAME)
4344./bin/StealthIMFileAPI : $(GO_FILES ) proto
4445 GOOS=linux GOARCH=amd64 go build -ldflags=" -s -w" -o ./bin/StealthIMFileAPI
4546
47+ .PHONY : build_run build_linux
4648build_win : ./bin/StealthIMFileAPI.exe
4749build_linux : ./bin/StealthIMFileAPI
4850
51+ .PHONY : docker_run
4952docker_run :
5053 docker-compose up
5154
@@ -55,19 +58,23 @@ docker_run:
5558 zstd ./bin/StealthIMFileAPI.docker -19
5659 @rm ./bin/StealthIMFileAPI.docker
5760
61+ .PHONY : build_docker
5862build_docker : ./bin/StealthIMFileAPI.docker.zst
5963
64+ .PHONY : release
6065release : build_win build_linux build_docker
6166
67+ .PHONY : clean
6268clean :
63- @rm -rf ./StealthIM.FileStorage
64- @rm -rf ./StealthIM.FileAPI
69+ @rm -rf ./StealthIM.*
6570 @rm -rf ./bin
6671 @rm -rf ./__debug*
6772
73+ .PHONY : dev
6874dev :
6975 ./run_env.sh
7076
77+ .PHONY : debug_proto
7178debug_proto :
7279 cd test && python -m grpc_tools.protoc -I. --python_out=. --mypy_out=. --grpclib_python_out=. --proto_path=../proto fileapi.proto
7380
@@ -77,4 +84,5 @@ debug_proto:
7784 @echo " Rewrite File"
7885 @sed -i ' s/import fileapi_pb2/from . import fileapi_pb2/g' ./tool/stimfileapi/proto/fileapi_grpc.py
7986
87+ .PHONY : proto_t
8088proto_t : ./tool/stimfileapi/proto/fileapi_grpc.py ./tool/stimfileapi/proto/fileapi_pb2.py ./tool/stimfileapi/proto/fileapi_pb2.pyi
0 commit comments