Hey r/linux
I wrote RTFM, a pure Zsh plugin designed to bridge the gap between "encountering a terminal error" and "fixing it" without leaving the shell.
While it’s currently optimised for the Arch ecosystem, the core philosophy is about reducing context switching.
Instead of just printing a "command not found" error, RTFM identifies the fix and drops it directly into your command buffer.
What makes it different?
- Interactive fzf Integration: If a binary is missing, it searches official and AUR repos. Selecting a package prepares the install command (e.g., sudo pacman -S ...) in your prompt for review.
- No Auto-Execution: It uses print -z to hand the command back to the user. You remain in control, nothing runs until you hit Enter.
- Smart Error Handling: It detects /var/lib/pacman/db.lck and offers an interactive prompt to clear it immediately.
- Zero Overhead: Written as a lazy loaded Zsh function (autoload). It won't bloat your .zshrc startup time or require a Python/Ruby runtime.
Why I wrote it:
I wanted something faster than a manual Wiki lookup but more precise than a general "typo guesser."
It’s designed for users who want to stay in the flow but still "Read The F... Manual" (hence the name).
GitHub: RTFM
I’m currently looking for feedback on the logic.
I'm also exploring making the backend distro agnostic (apt/dnf support) if there's interest from the wider community.
[link] [comments]
SOCIAL SHARE CARD GENERATOR