Skip to main content

Interactive TUI for exploring and cleaning up processes - find orphans, memory hogs, and kill them

Project description

procclean

Interactive TUI for exploring and cleaning up processes - find orphans, memory hogs, and kill them.

License Release Python 3.14+ Linux

Features

  • Memory overview - Real-time total/used/free/swap display
  • Multiple views - All processes, Orphaned, Process Groups, High Memory (>500MB)
  • Orphan detection - Finds processes whose parent died (PPID=1)
  • Tmux awareness - Won't flag tmux processes as orphan candidates
  • Batch operations - Select multiple processes and kill them at once
  • Process grouping - Find duplicate/similar processes consuming resources
  • CLI mode - Scriptable commands with JSON/CSV/Markdown output

Installation

uv tool install git+https://github.com/kjanat/procclean

Or run directly:

uvx git+https://github.com/kjanat/procclean

Usage

TUI Mode (default)

procclean

CLI Commands

procclean list                      # List processes (table)
procclean list -f json|csv|md       # Different output formats
procclean list -s mem|cpu|pid|name|cwd  # Sort by field
procclean list -o                   # Orphans only
procclean list -m                   # High memory only
procclean list -k                   # Killable orphans only
procclean list --cwd                # Filter by current directory
procclean list --cwd /path/to/dir   # Filter by specific cwd

procclean groups                    # Show process groups

procclean kill <PID> [PID...]       # Kill process(es)
procclean kill -f <PID>             # Force kill (SIGKILL)
procclean kill --cwd /path -y       # Kill all in cwd (skip confirm)
procclean kill -k -y                # Kill all killable orphans
procclean kill -k --preview         # Preview what would be killed

procclean mem                       # Show memory summary

TUI Keybindings

Key Action
q Quit
r Refresh
k Kill selected (SIGTERM)
K Force kill (SIGKILL)
o Show orphans
a Show all
g Show groups
w Filter by selected cwd
W Clear cwd filter
Space Toggle selection
s Select all visible
c Clear selection
1 Sort by memory
2 Sort by CPU
3 Sort by PID
4 Sort by name
5 Sort by cwd
! Reverse sort order

Views

  • All Processes - All user processes sorted by memory usage
  • Orphaned - Processes with PPID=1 (parent died)
  • Process Groups - Similar processes grouped together
  • High Memory - Processes using >500MB RAM

Output Formats

CLI supports multiple output formats via -f:

  • table - Human-readable table (default)
  • json - JSON array for scripting
  • csv - CSV for spreadsheets
  • md - Markdown table

Requirements

  • Python 3.14+
  • Linux (uses /proc filesystem)

Development

git clone https://github.com/kjanat/procclean
cd procclean
uv sync
uv run pre-commit install

Run tests:

uv run pytest

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

procclean-1.2.0.tar.gz (19.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

procclean-1.2.0-py3-none-any.whl (26.7 kB view details)

Uploaded Python 3

File details

Details for the file procclean-1.2.0.tar.gz.

File metadata

  • Download URL: procclean-1.2.0.tar.gz
  • Upload date:
  • Size: 19.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.9.21 {"installer":{"name":"uv","version":"0.9.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for procclean-1.2.0.tar.gz
Algorithm Hash digest
SHA256 f6bb8e864751a1707c2f8c91e0fe5f2514ff1e5489ac4c25568ce445c35e9e69
MD5 a72e64ae13a3856aac07712e678c3667
BLAKE2b-256 224e9c692a1f945ea9ba0b6d21ce40809eed110e1e371bd2f1b3be624c5a6a70

See more details on using hashes here.

File details

Details for the file procclean-1.2.0-py3-none-any.whl.

File metadata

  • Download URL: procclean-1.2.0-py3-none-any.whl
  • Upload date:
  • Size: 26.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.9.21 {"installer":{"name":"uv","version":"0.9.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for procclean-1.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 a9ebacd0d05416451fdc6af91c0a188e260df995b9e07e257f9cad6a62c6167a
MD5 cf1ce9e2fda8aa5586a63e8a962201ec
BLAKE2b-256 7f23bb013540771e9de4ba56b0d65a506b2a1e645bfbdf9c5db7d66e1c13b08b

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page