Arshia001 / FSharp.GrpcCodeGenerator

A protoc plugin to enable generation of F# code + supporting libraries
MIT License
81 stars 9 forks source link

Is it possible to use this tool passing an URL #14

Closed 64J0 closed 2 years ago

64J0 commented 2 years ago

Hello, I want to use this tool in order to generate F# code from protobuf files. Btw, it would be cool to not need to download this protobuf file locally. Is there a way to do it packaged with this tool?

Arshia001 commented 2 years ago

Hi.

Do you want to use .proto files from a remote source? It's currently not possible, and I'm not sure that would be a great idea anyway. What if the remote file changes? It'd break your build.

64J0 commented 2 years ago

Make sense @Arshia001. My idea was to pick some files from Github, this way we could specify which file version through the URL, but the repository might change and the story be re-written. Also, the idea is not to run this operation in a continuous fashion, but in a batch operation triggered manually from time to time (months gap I expect).

64J0 commented 2 years ago

Check this out for more context: https://github.com/64J0/Fubernetes/issues/2

Arshia001 commented 2 years ago

I highly recommend either pulling the files into your own project or using a packaging solution that supports versioning (such as Paket with a custom Nuget repository). Paket has an option to pull remote files into your project, you may also be able to use that, though I couldn't help you with it as I haven't used that feature for exactly the reason I gave before.

64J0 commented 2 years ago

Great, thanks for the tips @Arshia001.