Skip to content

FJRG2007/prunex

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

79 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

PRUNEX & PRUNEX STUDIO

OS-agnostic system optimizer in Rust. A single binary that detects ghost processes, prunes orphan apps, trims caches (incl. browsers), enforces RAM limits, manages startup entries, schedules tasks, and self-updates from GitHub releases - on Windows, Linux, and macOS.

Quickstart Β Β β€’Β Β  Discord Β Β β€’Β Β  All Features Β Β β€’Β Β  Install Β Β β€’Β Β  FAQ

build-and-publish Latest release License

Rust Edition Windows Linux macOS

PRUNEX STUDIO PREVIEW


Platform support

Prunex compiles + runs on Windows, Linux, and macOS, but the only OS we actively test against is Windows 11. Everything else listed here is best-effort: builds pass CI for every platform on every release, but real-world testing on macOS / Linux is community-driven.

OS Latest stable / LTS Testing status Notes
Windows 11 None yet β€” currently in beta / testing βœ… Actively tested Primary development target. All Gaming Mode / Pulse / Crosshair features are validated here first.
Windows 10 None ⚠ Not officially supported May work, may not. The Win10 WebView2 runtime + older Win32 APIs sometimes diverge from Win11 behaviour in ways we don't catch in CI. Use at your own risk β€” no guaranteed fixes for Win10-only bugs.
macOS (any) None ❌ Not tested Compiles in CI. No human has verified the Studio UI, Pulse overlay transparency, or Crosshair behaviour on a real Mac. Bug reports + fix PRs welcome.
Linux (any distro) None ❌ Not tested Compiles in CI. WebKitGTK / X11 vs Wayland edge cases are likely to surface. Bug reports + fix PRs welcome.

Every Prunex release is currently a beta β€” there's no stable / LTS designation yet on any OS. The version number (0.0.x) reflects that. If you want a release that's been smoke-tested on a human's machine before publication, stick to Windows 11. For everything else, treat each release as alpha.

If you hit a Windows 10–specific issue: feel free to open it on GitHub, but priority is "won't fix unless trivial". The right fix for Win10 users is upgrading to Win11 or running Prunex in a Win11 VM.


What it does

prunex is a single Rust binary that bundles a handful of small optimizations every desktop user eventually wants but few apps deliver as one tool. Each card below maps to one subcommand β€” everything is opt-in and reversible.

πŸ‘» Ghost Process Hunter

Detects background workers still running after their parent app has closed (Discord helpers, Oculus services, vendor telemetry). One-shot scan with ghosts, or watch as a daemon with a configurable grace period before each kill.

πŸš€ Launchpad

Define an ordered launch sequence in a TUI β€” path, args, cwd, pre/post delays, optional post-launch keystrokes. Run on demand with prunex launchpad run, or register one user-scope login task that fires the whole sequence. Replaces ad-hoc Python / batch startup scripts.

🎬 Startup Manager

List, enable, or disable programs that the OS itself auto-starts at login β€” Windows registry Run keys + Startup folders, Linux .desktop files, macOS LaunchAgents. Interactive TUI plus a scriptable CLI.

🧹 Cache Cleanup (experimental)

Per-OS allowlist: %TEMP%, XDG cache, Chrome / Edge / Brave / Firefox / Safari HTTP caches, thumbnail caches, Mesa shader cache, macOS DiagnosticReports. Skips browser caches automatically while the browser is running. Top contributors are previewed inline before deletion.

🩻 Orphan Detection (experimental)

Finds broken application registrations left behind by buggy uninstallers β€” Windows registry Uninstall keys whose target files are gone, Linux .desktop files pointing to deleted binaries, macOS .app bundles missing their executable.

βš–οΈ RAM Limits (experimental)

Per-process RAM thresholds. The watch daemon polls memory and either warns or kills when a runaway process (e.g. Epic Games Launcher) blows past the cap. Limits are case-insensitive substrings, configurable via prunex limit add or the onboarding wizard.

πŸͺ„ Onboarding Wizard

Interactive cliclack flow that wires up watcher autostart, periodic cache cleanup (daily / weekly), and RAM limits in one pass. All registrations are user-scope β€” no admin / root prompt.

πŸ“¦ Config Import / Export

Round-trip everything prunex stores - limits, schedules, launchpad sequence, autostart flags - to a single TOML file. import re-syncs scheduled tasks automatically and warns loudly on OS mismatch or missing paths so a backup from one machine does not silently break on another.

🧹 Debloat (experimental)

Removes Windows pre-installed bloat, disables telemetry, ads, Copilot, Recall, taskbar / Start widgets, etc. Ports the full Win11Debloat catalog (101 features + 147 AppX packages, MIT-licensed verbatim). Smaller curated lists for Linux (Apport, Tracker, Snap, …) and macOS (Siri suggestions, Game Center, hot corners, …). Categorized ratatui TUI, --dry-run preview, optional system restore point.

πŸ–₯ Studio (Tauri UI)

Companion desktop app prunex-studio cloning Win11Debloat's WPF look (dark sidebar with category icons, accent left-bar, main pane with feature checkboxes, dry-run toggle, log panel). Same engine as the CLI - links prunex-core directly, no subprocess. Releases ship Windows installer + portable .exe, Linux AppImage, and macOS .dmg (Intel + Apple Silicon). Tauri auto-update wired up (signing key one-time setup).

πŸ”„ Self-Update

Checks GitHub Releases for newer versions and atomically replaces the running binary in place via self-replace. Picks the asset that matches your current target triple (Windows MSVC / Linux glibc / macOS Apple Silicon, …) and validates the size before swap.

πŸ”— PATH Setup

Registers the binary's directory on your User PATH so prunex is callable from any terminal. Windows uses the Environment API (no setx truncation, no admin); Unix appends a sentinel block to the right shell rc file (~/.bashrc / ~/.zshrc / fish / profile). Fully reversible via prunex path uninstall.

Warning

Subcommands marked experimental may fail or behave unexpectedly. They write to the registry, edit .desktop files, delete cache files, or kill processes. Use at your own risk β€” double-check with --dry-run / --check before applying anything destructive.


Supported platforms

OS Status Notes
Windows 10 1903+ / 11 (x64) Supported Auto-elevates via Start-Process -Verb RunAs for ops that need admin. User-scope subcommands (cache, limit, onboarding, path, update) never trigger UAC. Studio (Tauri UI) needs WebView2 - preinstalled on Win11; Win10 1903+ either has it via modern Edge or the installer auto-fetches.
Linux (glibc 2.35+, x64 / aarch64) Supported Autostart uses systemd --user. Cache cleanup follows the XDG basedir spec. CLI runs anywhere with a recent glibc; Studio additionally needs WebKitGTK 4.1 (Ubuntu 24.04+, Fedora 39+).
macOS 14+ (Apple Silicon) Supported Autostart uses LaunchAgents. Cache cleanup is conservative on ~/Library/Caches. Intel Macs are not built any more - the GitHub macos-13 runner pool is in deprecation, and modern macOS (14 / 15 / 26) only ships on Apple Silicon. Intel users can still build from source via cargo install --path ..
Other (BSD, illumos, …) Best-effort cache forces dry-run mode; scheduling and orphans are no-ops.

Install

From a release binary

Grab the asset for your platform from the latest release, drop it somewhere on disk, then register it on PATH:

./prunex path install

That writes the binary's directory to your User PATH (Windows: HKCU\Environment\Path via the [Environment]::SetEnvironmentVariable(..., 'User') API β€” not setx, which truncates at 1024 chars; Unix: a sentinel block in ~/.bashrc / ~/.zshrc / ~/.config/fish/config.fish / ~/.profile). Open a new terminal and prunex works.

From source

git clone https://github.com/FJRG2007/prunex
cd prunex
cargo install --path .

cargo install puts the binary in ~/.cargo/bin/, which is already on PATH if you installed Rust via rustup.

Detailed build instructions (per-OS prerequisites, cross-compilation, release reproducibility) live in docs/developers/BUILD.md.


Quick tour

# detect ghost processes (default subcommand)
prunex
prunex ghosts --kill                # also terminate them, with confirmation
prunex ghosts --kill -y             # skip confirmation

# preview cache cleanup without deleting anything
prunex cache --clean --dry-run

# real cleanup - top contributors are shown inline in the prompt
prunex cache --clean

# configure a RAM limit on a buggy launcher
prunex limit add EpicGamesLauncher --max-ram-mb 4096 --action warn

# edit the launchpad (ordered launch sequence) in a TUI
prunex launchpad
prunex launchpad list                 # plain text, no TUI
prunex launchpad run                  # execute the sequence now
prunex launchpad run --dry-run        # preview, don't spawn
prunex launchpad autostart enable     # register sequence as a login task
prunex launchpad autostart disable    # remove the login task

# debloat the OS β€” Windows: 101 features + 147 apps; Linux/mac: smaller list
prunex debloat                                # bare = open the categorized TUI (Win)
prunex debloat list                           # show the catalog
prunex debloat list --apps                    # AppX bloat list (Win)
prunex debloat apply --preset-default --dry-run   # preview the recommended preset
prunex debloat apply --features DisableTelemetry,DisableCopilot
prunex debloat apply --features DisableTelemetry --revert    # undo it

# back up / restore the entire prunex configuration
prunex config export ./prunex-backup.toml
prunex config import ./prunex-backup.toml             # asks for confirmation
prunex config import ./prunex-backup.toml --dry-run   # preview only, no changes
prunex config import ./prunex-backup.toml --force -y  # CI-style, skip prompts

# run the interactive setup wizard
prunex onboarding

# register the binary on PATH
prunex path install

# check for updates
prunex update check
prunex update install               # download + atomic in-place swap

prunex --help and prunex <subcommand> --help show the full flag surface.


Architecture

prunex is a Cargo workspace of three crates (prunex-core engine library, prunex CLI binary, prunex-studio Tauri 2 desktop UI) with platform-specific code gated behind cfg attributes β€” no separate Windows / Unix build script. Scope, module map, CLI command reference, and Studio internals are documented in docs/developers/architecture/.

Highlights:

  • Everything that kills a process goes through one path (killer::kill) which is hard-blocked from terminating anything under a protected system directory (Windows\System32, /usr/sbin, /System/Library, …) regardless of how a feature decided to invoke it.
  • cache walks a per-OS allowlist; it never recurses into a directory not listed there. Symlinks are not followed. Files modified within min_age are skipped to avoid racing in-flight writes. Browser caches are skipped automatically when the browser is running.
  • Self-update fetches https://api.github.com/repos/FJRG2007/prunex/releases/latest, validates the asset size, writes the new binary alongside current_exe() (same filesystem β†’ atomic rename), then swaps in place via self-replace.
  • Scheduled tasks (autostart, periodic cache cleanup) are user-scope only: schtasks ONLOGON on Windows, systemd --user units on Linux, LaunchAgent plists on macOS. No admin prompt; reversible by the same user that ran prunex onboarding.

Configuration

User config lives at <config-dir>/prunex/config.toml:

OS Path
Windows %APPDATA%\prunex\config.toml
Linux $XDG_CONFIG_HOME/prunex/config.toml (default ~/.config/prunex/config.toml)
macOS ~/Library/Application Support/prunex/config.toml

Stores process limits, the autostart / cache-clean schedule, and the launchpad sequence. The path is stable per user (driven by dirs::config_dir()) so re-installs keep your configuration. Edit by hand or via prunex limit add/remove, prunex launchpad, and prunex onboarding.


License

See LICENSE.

Back to top πŸ”Ό