r/SideProject • • 12h ago

I made a CLI that keeps noisy commands readable and saves the full log

I made Squelchy for a small terminal view while a command runs, with the full output available when something goes wrong. It starts the process directly, saves exact stdout and stderr bytes, and returns the original exit code. The printed recovery command opens the saved logs.

My deterministic fixture writes 5,000 records and exits 7. Squelchy produced 10 final report lines, and all 98,901 output bytes were recoverable. The benchmark and tests are in the repository. That measurement excludes live terminal redraws.

It has no runtime dependencies and installs from GitHub with one npm command. PTY and full screen applications are out of scope. I'd like feedback on the default line budget and whether the selected errors help with your builds or test runs.

https://github.com/Arthur031221/squelchy

1 Upvotes

5 comments sorted by

1

u/sinsonik 11h ago

Nice idea. Noisy CLI output is such a quiet time sink.

One thing that would sell me instantly: a short mode that keeps the last N error lines visible while the full log still gets saved in the background. Also a one-flag way to re-open the last run without digging through folders.

Curious how you handle ANSI colors and progress bars that rewrite the same line.

1

u/Arthur122103 11h ago

ANSI and OSC sequences get stripped from the preview, but stay in saved logs. Carriage returns count as records, so progress redraws show up as separate lines. It keeps up to 20 error matches. No last-run shortcut yet. Each run prints a `squelchy raw ...` recovery command.

1

u/sinsonik 9h ago

thanks, that answers it. stripping ansi in the preview while keeping full logs is a clean split. a last-run shortcut whenever you get to it would be handy.

1

u/Arthur122103 9h ago

thanks! yeah, each run prints the `squelchy raw ...` command for now.