Skip to content

Instantly share code, notes, and snippets.

@fzankl
Created January 24, 2021 09:19
Show Gist options
  • Save fzankl/968192bb1357e86f8a0e0b81c5a595b4 to your computer and use it in GitHub Desktop.
Save fzankl/968192bb1357e86f8a0e0b81c5a595b4 to your computer and use it in GitHub Desktop.
Sample project file of a gRPC service in ASP.NET Core
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>netcoreapp3.1</TargetFramework>
</PropertyGroup>
<ItemGroup>
<Protobuf Include="..\..\protos\foo.proto" GrpcServices="Client">
<Link>Protos\foo.proto</Link>
</Protobuf>
</ItemGroup>
<ItemGroup>
<PackageReference Include="Google.Protobuf" Version="3.13.0" />
<PackageReference Include="Grpc.Net.Client" Version="2.33.1" />
<PackageReference Include="Grpc.Tools" Version="2.33.1">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
</ItemGroup>
</Project>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment