I have two git repositories:
common this repository contains protobuf files (.proto), these files should be fetched via git submodule init from other vendor repository. There are also go files with directive: //go:generate protoc --proto_path=a/xxx --go_out=. --go_opt=paths=source_relative a/xxx/b.proto
main this repository contains main project, which imports the package from common. Then I call git submodule update --init and the go generate. After generate i can see the log: go: finding github.xxx.com/xxx latest
but the main go file shows some problems: build github.xxx.com/main: cannot load github.xxx.com/xxx/proto: module github.xxx.com/common@latest found, but does not contains package github.xxx.com/xxx/proto
It seems that the go generate command doesn't generate proto files. I think if I import something then these files are somewhere in cache. I'm not sure if my approach is possible.
Could you tell me if this solution is feasible or what I should change.