⚡ RAW INTERFACE // postsonde
⚡ RAW INTERFACE // postsonde
Stateless Unix-style URL dispatcher & terminal omnibox for Newsboat, w3m, mpv, etc. and shell workflows. Unix Philosophy:term-⇄-link▸acts strictly as a stateless, zero-overhead link dispatcher—it opens papers directly in Zathura orpdftotextrather than piping into heavyweight literature workspaces (likepapr), keeping your tools fast, modular,
Stateless Unix Philosophy: Unlike classic URL openers (
urlview,urlscan) that simply dump every link into one browser—or bloated all-in-one suites that lock your data into proprietary databases—⚡term-⇄-link▸is a zero-state dispatcher. It inspects each URL and routes it straight to the best lightweight Unix tool for the job (mpv,wiki-tui,w3m,zathura, orpiper), keeping every tool modular, fast, and decoupled.
Keep your entire reading, search, and media workflow inside the terminal—without ever touching a bloated GUI browser.
Modern web browsing is slow, noisy, and full of trackers. ⚡term-⇄-link▸ acts as an intelligent Unix-style dispatcher between your terminal apps (Newsboat, w3m, or your shell) and specialized lightweight CLI/TUI tools:
- 🧠 Zero-Click Smart Routing: Videos and podcasts launch straight into
mpvwith pre-buffering, Wikipedia articles open natively inwiki-tui, GitHub & GitLab repo links render theirREADME.mdright in the terminal, ArXiv papers &.pdflinks open in your PDF viewer (orpdftotext), and standard web articles land in a cleanrdrview+w3mReader View. - 🦆 Built-In Terminal Omnibox: No URL on hand? Type keywords into
tm—term-linksearches DuckDuckGo (ddgr) right inside your terminal, lets you pick a result, and returns you cleanly to the search list when you're done. - 🔒 Privacy & Offline First: Reads input privately without polluting
~/.bash_history, strips tracking parameters automatically, opens Private/Incognito windows on demand, exports clean text-only Markdown or PDFs, and reads articles aloud offline using neural Piper TTS voices.
[ Newsboat ('o') ] ──┐
[ w3m ('M' / Alt+M)] ┼──▶ ⚡term-⇄-link▸ (Strip Trackers)
[ tm (Omnibox) ] ──┘ │
│ ├──▶ *.wikipedia.org ──▶ 📚 wiki-tui
▼ (Keywords) ├──▶ github / gitlab.com ──▶ 🐙 Rendered README (w3m)
🦆 DuckDuckGo (ddgr) ────────────┼──▶ ArXiv / .pdf ──▶ 📄 PDF Viewer | pdftotext
├──▶ Video / Audio ──▶ 🎬 mpv (yt-dlp + 150MB cache)
└──▶ Web / Articles ──▶ ⌨️ Numpad Action Menu
- 🔮 Private Omnibox (
tm): Enter URLs or search queries without leaving traces in~/.bash_history—or pressEnterto grab your clipboard automatically. - 🦆 DuckDuckGo Terminal Search (
ddgr): Type regular search terms instead of a URL to browse the top 9 results right inside your terminal (with automaticw3mHTML fallback). - 📚 Wikipedia Auto-Router (
wiki-tui): Automatically detects*.wikipedia.org/wiki/...links, parses the language code and article title, and opens them directly inwiki-tui. - 🐙 GitHub & GitLab Repo README Preview: Opening a
://github.com<user>/<repo>or://gitlab.com<user>/<repo>link fetchesREADME.mddirectly and renders it cleanly viapandoc+w3m(orless) in your terminal. - 📄 ArXiv & Direct PDF Reader (
PDF_VIEWER/pdftotext): Automatically convertsarxiv.org/abs/...links to.pdf, downloads the file temporarily, and opens it in your configured * 📄 ArXiv & Direct PDF Reader (pdftotext/PDF_VIEWER): Automatically convertsarxiv.org/abs/...links to.pdfand extracts readable layout text intolessviapdftotext(poppler-utils, installed byinstall.sh). Recommended upgrade: Install Zathura (sudo apt install zathura zathura-pdf-poppler) and setPDF_VIEWER="zathura"in your config—⚡term-⇄-link▸will then download PDFs temporarily, open them natively in Zathura, and auto-clean them on exit. - 👽 Reddit & Newsboat RSS: Rewrites
reddit.comlinks to://reddit.comautomatically. (Note: Reddit blocks most unauthenticated web/search requests—for reliable terminal reading without an account, subscribe to subreddits via RSS directly in Newsboat, e.g.https://reddit.com.) - 🧹 Tracking Stripper: Removes
utm_*,fbclid,gclid,dclid,msclkid,igshid,si, andref=rssbefore opening or copying any URL.
- ⚡ Instant Fast-Path: Direct media files (
.mp4,.mp3,.m3u8,.flac,.opus) and major platforms (YouTube, Arte, ZDF, ARD, Vimeo, Odysee, Twitch, Dailymotion) bypass slow simulation checks and launch immediately. - 🚀 Direct Stream Resolving & Cache: Resolves streams via
yt-dlp -gwith unthrottled client options and a 150 MB / 60s read-ahead cache for smooth, stutter-free playback. - 🎞️ Clean Alternate-Screen Player (
MPV_SPINNER): Runsmpvin an isolated alternate terminal buffer (smcup/rmcup) with an animated top spinner & bottomAV:status bar—leaving zero terminal residue on exit. RunMPV_SPINNER=0 tmanytime for raw, unmodifiedmpvconsole logs. - 🛡️ Autoplay Ad-Blocker & HD Fallback: Disables
yt-dlp's generic extractor (--ies "default,-generic") so news articles with embedded ad clips still open in Reader View, while extracting hiddenog:videoHD streams (e.g. tagesschau.de).
For standard web articles and links, ⚡term-⇄-link▸ renders a centered, adaptive Dracula TUI Numpad Menu (Enter triggers 1 Reader View by default):
| Key | Action | Description |
|---|---|---|
1 |
📖 Reader View (w3m) |
(Default) Distraction-free article reading via rdrview + w3m. |
2 |
🌐 Full w3m |
Opens the complete webpage in w3m with full link & external browser support. |
3 |
🕵️ Browser (Private) | Opens in Incognito/Private mode (Brave, Firefox, LibreWolf, Chrome, Chromium, Vivaldi, Zen, Floorp, Edge). |
4 |
📋 Copy URL | Copies the cleaned, tracker-free URL to your clipboard (wl-copy, xclip, or xsel). |
5 |
📝 Save minimal MD | Exports a clean, image-free GitHub-Flavored Markdown file to SAVE_DIR. |
6 |
🌍 Browser (Normal) | Opens the link in your default desktop browser. |
7 |
🔊 Read aloud (TTS) | Auto-detects the article language (26+ languages) and reads it aloud offline via Piper TTS. |
8 |
📄 Save clean PDF | Generates a clean, text-only PDF with table of contents via pandoc + weasyprint in SAVE_DIR. |
9 |
Forces any URL or embedded media stream straight into mpv. |
|
0 |
❌ Back | Exits cleanly back to search results, Newsboat, w3m, or the input prompt. |
When browsing inside w3m (opened via Option 2 Full w3m), pipe pages or individual links back into ⚡term-⇄-link▸—or straight to your GUI browser:
Shortcut in w3m |
Action | Notes |
|---|---|---|
Shift + M |
Send current page to ⚡term-⇄-link▸ |
Works in Full w3m (2). (In Reader View 1, w3m reads from stdin.) |
Alt + Shift + M (or Esc → Shift + M) |
Send link under cursor to ⚡term-⇄-link▸ |
Ideal for browsing lists and opening individual papers, repos, or videos. |
9 + Shift + M |
Open current page in GUI browser | Uses w3m's extbrowser9 slot (xdg-open). |
Why no heavy literature manager pipe? Following the Unix philosophy,
⚡term-⇄-link▸opens papers directly in Zathura orpdftotextrather than piping into full workspace apps (likepapr), keeping your reading flow instant and stateless.
- Direct Search: Type
arxiv Attention Is All You Needintmto jump straight into a paper's PDF. - Browsing New Submissions: Open a category feed such as
arxiv.org/list/cs.AI/recentand pick2(Fullw3m) in the Numpad menu. - Navigate to any paper's
[html]link and pressAlt + Shift + M(orEsc→Shift + M) to send it to⚡term-⇄-link▸—from there you can read it cleanly (1), listen to it (7), or export a formatted PDF with table of contents (8).
Customize behavior persistently without editing the script itself by creating ~/.config/term-link/config (see config.example):
# ~/.config/term-link/config
MPV_SPINNER=1 # 1 = clean alternate screen + spinner, 0 = raw mpv console logs
SAVE_DIR="$HOME/Downloads/Articles" # Target folder for Markdown & PDF exports
# PDF_VIEWER="zathura" # Recommended: lightweight Vim-key PDF viewer (press Ctrl+R in Zathura for Dark Mode)
# Recommended optional PDF viewer (instead of terminal pdftotext | less):
# Install via: sudo nala install zathura zathura-pdf-poppler (Tip: press Ctrl+R inside Zathura for Dark Mode)
# PDF_VIEWER="zathura"- Reload shell config once after setup:
source ~/.bashrc
- Newsboat (
nb): Launch Newsboat with the rainbow banner and pressoon any article to open it in⚡term-⇄-link▸. (Multiple⚡term-⇄-link▸instances can run simultaneously alongside Newsboat.) - Private Omnibox (
tm):tm→ Paste a URL, pressEnterfor clipboard, or type keywords to search DuckDuckGo.MPV_SPINNER=0 tm→ Temporarily disable the alternate player screen to inspect rawmpvlogs.
Built to run effortlessly on low-spec hardware—including Raspberry Pi (even Pi 3 / Zero 2 W) and headless SSH sessions:
- ⚡ Ultra-Low Footprint: Core tools (
bash,w3m,rdrview,pdftotext,ddgr) consume only a few megabytes of RAM—no bloated browser engine required. - 🎧 Automatic Headless / SSH Audio Mode: When running over SSH or on a displayless system (
$DISPLAYand$WAYLAND_DISPLAYunset),⚡term-⇄-link▸automatically passes--no-videotompvand requests audio-only streams (bestaudio/best), saving CPU, RAM, and bandwidth. - 🎚️ Manual Audio-Only Override (
MPV_NO_VIDEO=1): Force audio-only playback anytime—even on a desktop—viaMPV_NO_VIDEO=1 tmor persistently in~/.config/term-link/config. - 🗣️ ARM-Optimized Offline TTS: Powered by Piper TTS, designed specifically for fast neural voice synthesis on Raspberry Pi / ARM boards.
Make sure Newsboat is closed, open your terminal, and run:
bash <(curl -fsSL https://raw.githubusercontent.com/postsonde/term-link/main/install.sh)Note: Uses
bash <(...)so interactive prompts work properly. Do not run withsudo—the installer prompts forsudoautomatically when needed. PressEnterfor defaults or0to abort anytime.
git clone https://://github.com/postsonde/term-link.git && cd term-link && ./install.shUSAGE: ./install.sh [OPTION]
(no option) Interactive setup: deps, voices, newsboat, w3m & aliases.
-s, --status Check binaries, piper voices, newsboat & bashrc.
-u, --uninstall Remove term-link, newsboat/w3m hooks & bashrc aliases.
-h, --help Show help message and exit.
term-link— Main URL router & omnibox script (installed to~/.local/bin/term-link).install.sh— Interactive installer, dependency checker & uninstaller.config.example— Sample configuration file for~/.config/term-link/config.
🄯
© postsonde
[Status: Active | postsonde.github.io | License: GNU GPLv3 | Simulated Gemini/Web Hybrid]
