Skip to main content

Module output

Module output 

Source

Functions§

clean_path
Helper to strip Windows UNC \\?\ prefix, macOS /private/ prefix, and collapse double slashes.
condense_tool_output
Reduce a package manager’s failure output to the part that says what went wrong.
create_progress_bar
A determinate progress bar for a pass whose total is known up front.
create_spinner
Create an animated terminal loading spinner for long-running operations.
format_bytes
Format bytes into human-readable string (e.g., “1.2 GB”, “450 MB”)
format_bytes_styled
A byte figure styled as “space you got back” — the number this tool exists for.
format_seconds
A duration in seconds, at the precision a person would actually say it in.
pad_display
Left-align s in a column exactly cells terminal columns wide.
plural
Pick the singular or plural form for a count.
print_attribution
Print the one-line credit, if anything is going to read it.
print_banner
Print the dev-prune ASCII art banner
print_dimmed
Print a line in the terminal’s dimmed style, with no marker glyph.
print_error
Print an error message (red X)
print_header
Print a section header
print_info
Print an info message (dimmed arrow)
print_notice
Print a notice to stderr.
print_success
Print a success message (green checkmark)
print_warning
Print a warning message (yellow exclamation)
print_wrapped
Print an explanatory paragraph, wrapped to the terminal and indented under indent.
shared_note
The suffix explaining bytes a prune does not free because a package-manager store hardlinks them (pnpm, bun). Empty when there is nothing to explain, so call sites can append it unconditionally.
styled_adapter
A package-manager name, deliberately left in the terminal’s default colour.
styled_path
A filesystem path, styled. One place to change if cyan-on-cyan ever clashes.
truncate_display
Truncate s to at most cells terminal columns, marking the cut with an ellipsis.