From bd51e1cbbf46b1e013dbada6b540d1772606503e Mon Sep 17 00:00:00 2001 From: Louis Seubert Date: Fri, 10 May 2024 21:41:08 +0200 Subject: [PATCH] chore: add project readme to describe the project --- Directory.Packages.props | 2 ++ README.md | 49 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 51 insertions(+) create mode 100644 README.md diff --git a/Directory.Packages.props b/Directory.Packages.props index 4d6906b..e61dff2 100644 --- a/Directory.Packages.props +++ b/Directory.Packages.props @@ -9,6 +9,8 @@ + + diff --git a/README.md b/README.md new file mode 100644 index 0000000..f53bcfa --- /dev/null +++ b/README.md @@ -0,0 +1,49 @@ +# `Geekeey.Extensions.Process` + +## Features + +## Getting Started + + +### Install the NuGet package: + +``` +dotnet add package Geekeey.Extensions.Process +``` + +You may need to add our NuGet Feed to your `nuget.config` this can be done by adding the following lines + +```xml + + + +``` + +### Configure + +The package adds a global using for the functions in the `Prelude` class when the `ImplicitUsings` is enabled in +the `.csproj` file. This global using is recommended but can also be removed, by removing +the `Geekeey.Extensions.Process.Prelude` value from the item group ``. For more information about that see +the `Project.props` file inside the project tree. + +### Usage + +```csharp +public static Task Main() +{ + var stdout = new StringBuilder(); + var cmd = Run("git").WithArguments(["config", "--get", "user.name"]) | stdout; + await cmd.ExecuteAsync(); + Console.WriteLine(stdout.ToString()); + return 0; +} +``` + +```csharp +public static Task Main() +{ + var cmd = Run("cat").WithArguments(["file.txt"]) | Run("wc"); + await cmd.ExecuteAsync(); + Console.WriteLine(stdout.ToString()); +} +``` \ No newline at end of file