diff options
Diffstat (limited to 'HelloApp')
-rw-r--r-- | HelloApp/HelloApp.fsproj | 13 | ||||
-rw-r--r-- | HelloApp/Program.fs | 12 | ||||
-rw-r--r-- | HelloApp/README.md | 16 |
3 files changed, 41 insertions, 0 deletions
diff --git a/HelloApp/HelloApp.fsproj b/HelloApp/HelloApp.fsproj new file mode 100644 index 0000000..54be4a7 --- /dev/null +++ b/HelloApp/HelloApp.fsproj @@ -0,0 +1,13 @@ +<Project Sdk="Microsoft.NET.Sdk"> + <PropertyGroup> + <OutputType>Exe</OutputType> + <TargetFramework>netcoreapp2.0</TargetFramework> + </PropertyGroup> + <ItemGroup> + <Compile Include="Program.fs" /> + </ItemGroup> + <ItemGroup> + <ProjectReference Include="..\HelloLib\HelloLib.fsproj" /> + <ProjectReference Include="..\HelloGrpc\HelloGrpc.csproj" /> + </ItemGroup> +</Project>
\ No newline at end of file diff --git a/HelloApp/Program.fs b/HelloApp/Program.fs new file mode 100644 index 0000000..cbb161d --- /dev/null +++ b/HelloApp/Program.fs @@ -0,0 +1,12 @@ +open HelloLib
+
+[<EntryPoint>]
+let main argv =
+ let server = Greeting.Serve ()
+ let client = Greeting.MakeClient ()
+
+ client.SayHelloAsync(new HelloNet.Api.HelloRequest(Greetee = "world")).ResponseAsync.Wait()
+
+ server.ShutdownAsync().Wait()
+
+ 0
diff --git a/HelloApp/README.md b/HelloApp/README.md new file mode 100644 index 0000000..0b1f71a --- /dev/null +++ b/HelloApp/README.md @@ -0,0 +1,16 @@ +# About + +This project demonstrates how to build a gRPC service with F# on .NET +Core 2.0. + +# How to Build + +```sh +dotnet build +``` + +# How to Run + +```sh +dotnet HelloApp/bin/Debug/netcoreapp2.0/HelloApp.dll +``` |