Runic.CommandLine.Processes 0.3.0-preview.1

This is a prerelease version of Runic.CommandLine.Processes.
dotnet add package Runic.CommandLine.Processes --version 0.3.0-preview.1
                    
NuGet\Install-Package Runic.CommandLine.Processes -Version 0.3.0-preview.1
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Runic.CommandLine.Processes" Version="0.3.0-preview.1" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Runic.CommandLine.Processes" Version="0.3.0-preview.1" />
                    
Directory.Packages.props
<PackageReference Include="Runic.CommandLine.Processes" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Runic.CommandLine.Processes --version 0.3.0-preview.1
                    
#r "nuget: Runic.CommandLine.Processes, 0.3.0-preview.1"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Runic.CommandLine.Processes@0.3.0-preview.1
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Runic.CommandLine.Processes&version=0.3.0-preview.1&prerelease
                    
Install as a Cake Addin
#tool nuget:?package=Runic.CommandLine.Processes&version=0.3.0-preview.1&prerelease
                    
Install as a Cake Tool

Runic.CommandLine.Processes

Runic.CommandLine.Processes runs local tools for command applications without building a shell command string. It preserves argument tokens, applies an executable policy before launch, bounds retained stdout/stderr, and returns a sanitized result for success, rejection, timeout, cancellation, and start failure.

Install

dotnet add package Runic.CommandLine.Processes --prerelease

The package targets net10.0 and brings Runic.CommandLine transitively. It is a preview package. Use it for trusted application-controlled automation, not as a browser-facing execution endpoint or operating-system sandbox.

Run an allowlisted tool

Constrain executable and working-directory roots, pass one argument per token, and inspect the resulting state:

var policy = new LocalExecutablePolicy(
    executableRoots: new[] { applicationToolsDirectory },
    workingDirectoryRoots: new[] { applicationDataDirectory });
var runner = new ProcessRunner(policy);
var request = new ProcessRequest(
    toolPath,
    new[] { "export", "--output", outputPath },
    workingDirectory: applicationDataDirectory,
    options: new ProcessExecutionOptions(
        timeout: TimeSpan.FromSeconds(30),
        standardOutputLimitBytes: 64 * 1024,
        standardErrorLimitBytes: 64 * 1024));

ProcessResult result = await runner.RunAsync(request, cancellationToken);

if (result.State == ProcessState.Exited && result.ExitCode == 0)
{
    return result.StandardOutput.Text;
}

throw new InvalidOperationException(
    $"Tool ended in {result.State} ({result.Fault?.Code ?? "no fault code"}).");

ProcessStartInfo.ArgumentList receives each argument separately—never join or quote them into a shell command. Both redirected streams are drained concurrently even after their retention caps; IsTruncated and ObservedByteCount distinguish retained text from the total observed output.

Security and failure behavior

Every request is evaluated by IExecutablePolicy. LocalExecutablePolicy checks configured roots and the runner launches the path it evaluated, but this does not eliminate operating-system races: a permitted file or symlink can be replaced between evaluation and start. When inputs cross a trust boundary, use an absolute allowlisted executable and a minimal child environment—inheritance can expose credentials.

Use ProcessState to handle terminal behavior and ProcessFaultCodes for stable diagnostics such as RCLI6001 (executable rejected), RCLI6002 (working directory rejected), and RCLI6005 (start failure). Policy messages and details are normalized before they reach a result to avoid leaking input.

Documentation and support

Read the Runic Command Line documentation, see process examples, or report an issue. Runic.CommandLine.Processes is maintained by Runic Artifex and licensed under the MIT License.

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.3.0-preview.1 38 9/11/2026
0.2.0-preview.1 51 9/9/2026