Skip to content

silenthooligan/stassh

Repository files navigation

sTaSSH

A native Wayland terminal emulator and SSH client, written in pure Rust. No Electron, no web runtime. The name reads "stash" and carries three meanings:

Cluster Meaning Pillar
TaSSH Terminal Performance: native, GPU-rendered, no Electron
sTaSSH SSH Security: pure Rust, no telemetry, keys stay local
sTaSSH Stash Organization: profiles, keys, themes in one place

Tagline: "Terminal. SSH. Organized. Fast."

Status

Daily-driver capable. Local shells, SSH (agent / key / vault auth), telnet, tabs, split panes, themes, a full settings surface, mouse selection and clipboard, and per-profile port forwarding all work. See docs/known-issues.md for the one open bug (a phantom second window on KWin/Wayland) and items deliberately deferred.

Features

Core

  • iced 0.13 + wgpu, native Wayland (Vulkan via wgpu)
  • Tabs (new / switch / close) and split panes (iced pane_grid)
  • Profiles: Local shell, SSH, Telnet. TOML-persisted, in-app editor, Quick Connect modal
  • Per-profile shell override (zsh, bash, fish, etc., from /etc/shells)
  • Pure-Rust SSH via russh: agent, vault-key, and key-file auth
  • SSH key vault (ed25519 generate / list / delete) under ~/.config/stassh/keys/
  • State persistence: window size, open tabs, last profile

Terminal fluency

  • Mouse selection with inverse highlight; Ctrl+Shift+C copy, Ctrl+Shift+V paste (iced clipboard)
  • OSC 8 hyperlinks: click to open via xdg-open
  • Dynamic tab titles from the OSC window title (follows cwd when the shell sets it)
  • Kitty keyboard protocol enabled; Shift / AltGr / layout reach the PTY
  • Mouse-wheel scrollback
  • Bell: none / visual flash / desktop notification / both

SSH foundations

  • Connect timeout, keepalive interval, keepalive max failures
  • zlib compression toggle
  • Host-key verification against known_hosts (Trust on first use / Strict / Accept all)
  • Local (-L) port forwarding per profile

Customization

  • 8 bundled themes plus an in-app theme editor (hex inputs with live swatches, 16-cell ANSI palette)
  • Font family picker (fontconfig), size, terminal padding, cursor style and blink rate

Settings persist to ~/.config/stassh/settings.toml. Profiles, themes, and window state live in their own TOML files in the same directory.

Build

Requires a Rust toolchain and the system libraries the iced/wgpu/winit stack links: wayland, libxkbcommon, vulkan-loader, fontconfig, freetype, expat.

cargo build --release
./target/release/stassh

The release profile is tuned for shipping (LTO fat, single codegen unit, stripped). A clean LTO build takes a couple of minutes.

Install (local, no root)

install -Dm755 target/release/stassh ~/.local/bin/stassh
install -Dm644 dist/stassh.desktop ~/.local/share/applications/stassh.desktop
for sz in 24 32 48 64 96 128 192 256; do
  install -Dm644 "dist/branding/logo-mark-${sz}.png" \
    ~/.local/share/icons/hicolor/${sz}x${sz}/apps/stassh.png
done
gtk-update-icon-cache -f -t ~/.local/share/icons/hicolor
update-desktop-database ~/.local/share/applications

Then launch stassh from a terminal or the application launcher.

Architecture

Single binary, Elm-style iced application. Module map:

Module Lines Responsibility
main.rs ~3600 App state, update/view, tab + pane management, key routing, rendering
prefs.rs ~2200 Preferences pane: profile editor, keys, themes, settings panels
terminal.rs ~840 PTY / SSH / telnet sessions, alacritty grid, snapshot rendering, selection, forwards
style.rs ~590 Design tokens and chrome style helpers
theme.rs ~370 Theme model, bundled themes, TOML load/save
settings.rs ~340 AppSettings model + load/save, font/shell enumeration
profile.rs ~250 Profile model (Local/SSH/Telnet), local forwards, TOML
ssh.rs ~225 russh connect, auth methods, host-key policy
vault.rs ~210 ed25519 key vault
input.rs ~140 Hotkey matching, key-to-bytes mapping
state.rs ~66 Persisted window/tab state

Terminal engine: alacritty_terminal (VT parser, grid, PTY). SSH: russh. Rendering: cells are drawn through iced rich_text with per-cell colors and backgrounds.

Packaging (void / xbps)

An xbps-src template lives at dist/void/srcpkgs/stassh/template, mirroring alacritty's shape (cargo build_style). To package after tagging a release:

  1. Tag the version on GitHub (e.g. v0.1.0).
  2. Copy the template into a void-packages clone: srcpkgs/stassh/template.
  3. ./xbps-src fetch stassh to compute the checksum, paste it into the template's checksum=.
  4. ./xbps-src pkg stassh, then xbps-install from the local repo.

Deliberately deferred

  • Remote (-R) and dynamic SOCKS (-D) port forwarding (local -L is done)
  • Bracketed-paste markers; word/line double-click selection modes
  • OSC 52 clipboard, OSC 7 cwd as a structured field (the OSC title covers the common case)
  • ProxyJump (bastion chains), agent forwarding toggle
  • Lua config, plugin host, inline images, built-in multiplexer, AI features (these are intentionally out of scope; see the project plan)

License

MIT. See LICENSE.

About

Self-contained modern Rust terminal with tabs, profiles, and themes (a void-friendly Tabby alternative)

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages