sbb-tui: Swiss Transport Timetables Right in Your Terminal
If you've ever tried checking Swiss train schedules from the command line, you know the pain. Open a browser, find the SBB app, type your stations, wait for the page to load—it’s fine, but it breaks flow. Especially if you're already deep in a terminal session and just want to know when the next train to Bern leaves.
That's exactly why sbb-tui exists. It’s a terminal user interface (TUI) built in Rust that gives you live Swiss transport timetables without leaving your shell. No browser. No app. Just your terminal and a clean, keyboard-friendly interface.
What It Does
sbb-tui connects to the Swiss Federal Railways (SBB) public API and displays real-time departure and arrival information for any station in Switzerland. You search for a station, it shows you the next connections, including delays, platform changes, and even track numbers.
It’s built as a TUI — think htop or ranger — so you navigate entirely with your keyboard. Up/down arrows to scroll, Enter to select a connection for details, and q to quit. It’s fast, lightweight, and respects your terminal’s color scheme.
Why It’s Cool
A few things make this worth trying:
- Zero dependencies beyond Rust – No Electron, no web view, no API keys to configure. Install with
cargo install sbb-tui, and you’re off. - Offline-friendly for API failures – The tool caches the last known schedule data. If network hiccups happen, you still see something useful.
- Keyboard-first UX – Designed for people who live in the terminal. Tab autocompletes station names, and you can filter connections by time or platform.
- Clean codebase – The repo is small, well-structured, and the author provides a clear
--helpand config file for customizing behavior like default stations or language (DE/FR/IT/EN).
Use cases? Commuters checking their daily route without opening a browser. Developers integrating train data into scripts (you can pipe it with --json output). Travelers in Switzerland who want quick info without data-heavy apps.
How to Try It
All you need is Rust installed:
cargo install sbb-tui
Then:
sbb-tui
Or specify a station directly:
sbb-tui --station "Zürich HB"
You’ll see a live l