我有一个包含许多.proto文件的protobuf文件夹,我可以使用这些文件进行编译
protoc -I=protobuf filename.proto --grpc-web_out=import_style=commonjs,mode=grpcwebtext:output这会将grpc_web_pb.js生成到/output文件夹中,但我正在寻找一种方法,以便不必为每个文件调用protoc,是否有类似通配符的东西?
我试过了
protoc -I=protobuf *.proto --grpc-web_out=import_style=commonjs,mode=grpcwebtext:output但这不起作用,使用no matches found: *.proto失败
发布于 2020-06-21 17:24:44
这对我来说很有效,也许只需将路径添加到您的.proto文件中:
protoc -I . --grpc-web_out=import_style=commonjs,mode=grpcwebtext:. ./*.protohttps://stackoverflow.com/questions/60765453
复制相似问题