Skip to main content

Module adapters

Module adapters 

Source

Modules§

bun
cargo_adapter
go
gradle
maven
npm
pnpm
poetry
uv
venv
yarn

Structs§

BinaryCheckStatus
Information describing status of a required package manager binary.
BloatDir
Information about a bloat directory that can be pruned.
DirSizeBreakdown
A directory’s size split by what deleting it would actually free.
DriftReport
Packages sitting in a manager’s environment directory that its lockfile does not record — installs a post-prune restore would not bring back.
EnforcePolicy
What an adapter is allowed to do while enforcing a lockfile on this pass.

Traits§

PackageManager
The core trait that every package manager adapter must implement.

Functions§

binary_available
Check whether a package manager binary is present and runnable.
capture_command_with_timeout
Run a command and hand back what it printed on stdout, bounded by timeout.
detect_adapters
Detect which adapters apply to a given project directory.
dir_size
Calculate the total size of a directory recursively (in bytes).
dir_size_with_hardlinks
dir_size, but hardlink-aware.
enforce_two_tier
The one rule every adapter enforces, given the manager’s two spellings of the check.
get_all_adapters
Returns all registered package manager adapters.
lock_sync_or_verify
Two-tier lockfile enforcement using default timeout.
lock_sync_or_verify_with_timeout
Two-tier lockfile enforcement with configurable timeout.
lock_verify_or_generate
Lockfile enforcement for ecosystems whose “sync” command rewrites source manifests.
resolve_program
Resolve a program name into something Command::new can actually spawn.
run_command_with_timeout
Helper: run a command with a configurable timeout.
scan_required_binaries
Scan only the package manager binaries needed by candidate repos.
try_run_command
Helper: attempt a command but return true/false instead of Err.