Skip to main content
Version: Next

pip CLI reference

ModularPipelines.Python provides strongly typed access to the pip CLI.

Executable prerequisite

This package does not install the pip executable. Install it separately and ensure pip is available on PATH.

Follow the executable's official documentation for installation instructions.

Package installation

dotnet add package ModularPipelines.Python

Resolve the service with context.Tools.Pip. Projects using C# 13 or another .NET language can use context.Tools.Get<ModularPipelines.Python.Services.IPip>() instead.

Module example

using ModularPipelines;
using ModularPipelines.Python.Options;

public class RunCommandModule : Module<CommandResult>
{
protected override async Task<CommandResult> ExecuteAsync(
IModuleContext context,
CancellationToken cancellationToken)
{
return await context.Tools.Pip.FreezeAsync(
new PipFreezeOptions(),
cancellationToken: cancellationToken);
}
}

Commands

CLI commandOptions record
pip cachePipCacheOptions
pip checkPipCheckOptions
pip configPipConfigOptions
pip downloadPipDownloadOptions
pip freezePipFreezeOptions
pip hashPipHashOptions
pip indexPipIndexOptions
pip inspectPipInspectOptions
pip installPipInstallOptions
pip listPipListOptions
pip searchPipSearchOptions
pip showPipShowOptions
pip uninstallPipUninstallOptions
pip wheelPipWheelOptions