Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

25 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

pipesr icon

CONTRIBUTORS FORKS STARS

CRATES.IO DOWNLOADS

Animated terminal pipes screensaver written in Rust

pipesr preview

Tip

Русская версия: README-RU.md

Features

  • Smooth terminal animation with configurable pipes, colors, and glyph sets
  • Multiple color modes (ansi, rgb, argb) with named palettes and rainbow shift
  • Screen coverage tracking for intelligent reset timing
  • Interactive runtime controls for speed, color, and visual behavior
  • Two executables:
    • pipesr for interactive animation
    • pipesr-bench for throughput benchmarking
  • Benchmark modes:
    • core (algorithm only, no terminal output)
    • full-render (full draw pipeline in terminal)

Installation

Install from crates.io

cargo install pipesr

Install from source

git clone https://github.com/WhoSowSee/pipesr.git
cd pipesr
cargo install --path .

This installs the pipesr and pipesr-bench binaries into your Cargo bin directory.

Build

cargo build --release

Usage

# Run installed binary
pipesr

# With runtime options
pipesr -p 4 -R -f 100

# Help and version
pipesr -h
pipesr -v

# Generate default config
pipesr -g

Runtime Keys

  • ~ - toggle keyboard reference
  • p / o - increase/decrease turn chance (0.0..1.0)
  • f / d - increase/decrease FPS (1..720)
  • b - toggle bold
  • c - toggle color
  • k - toggle keep color/type when crossing edges
  • r - manual screen reset
  • 0..9 - switch pipe type to the matching -t/--type index
  • q, Ctrl+Q, Ctrl+C - quit

Config file

pipesr loads persistent settings from:

~/.config/pipesr/config.toml

Merge priority:

CLI options > config file > built-in defaults

-s, --turn-chance [0.0-1.0] turn probability (default: 0.08) -r, --reset-threshold [0.0-1.0] screen coverage threshold for reset, 0 = no reset (default: 0.5)

pipes = 4
framerate = 60.0
turn_chance = 0.1
reset_threshold = 0.5
random_start = true
no_bold = false
no_color = false
color_mode = "ansi" # ansi | rgb | argb
palette = "terminal" # terminal | github | kanagawa | material-ocean | gruvbox | catppuccin | tokyonight | nord | ayu
rainbow = false
keep_color_type = true
type = [0, 2]
type_custom = ["fedcba9876543210"]
color = [1, 2, "#AF"] # requires color_mode = "ansi"

Pipe Types

Index Name Preview
0 heavy ┃ ━ ┏ ┓ ┗ ┛
1 light │ ─ ┌ ┐ └ ┘
2 curved │ ─ ╭ ╮ ╰ ╯
3 outline ║ ═ ╔ ╗ ╚ ╝
4 ascii | + -
5 diagonal | / \\ -
6 dots . . . . . .
7 round . o . o . o
8 mixed - \\ / |
9 knobby ╿ ╼ ┍ ┑ ┕ ┙

Select at runtime with -t <index> or switch live with keys 0-9. Custom sets can be added via -T (exactly 16 characters) or type_custom in config.

pipesr CLI Options

-p, --pipes [1-N]                    number of pipes (default: 1)
-t, --type [0-N]                     pipe type index (repeatable)
-T, --type-custom [16 chars]         custom pipe type (repeatable)
-c, --color [0-255|#HEX]             color index, decimal or hex (repeatable)
-m, --color-mode [ansi|rgb|argb]     color mode (default: ansi)
-P, --palette                        named color palette (default: terminal)
                                     palettes: terminal | github | kanagawa | material-ocean
                                             gruvbox | catppuccin | tokyonight | nord | ayu
-w, --rainbow                        shift colors between frames
-f, --framerate [FPS]                frames per second (default: 60)
-s, --turn-chance [0.0-1.0]          turn probability (default: 0.08)
-r, --reset-threshold [0.0-1.0]      screen coverage threshold for reset, 0 = no reset (default: 0.5)
-R, --random-start                   randomize initial position/direction
-B, --no-bold                        disable bold
-C, --no-color                       disable color
-n, --no-config                      ignore config.toml and use built-in defaults as the base
-K, --keep-color-type                keep color/type on edge crossing
-g, --generate-config                write default config file to the standard config path
-h, --help                           help
-v, --version                        version

Examples:

# 4 pipes, random start, higher FPS
pipesr -p 4 -R -f 100

# custom palette + no auto reset
pipesr -c 1 -c 2 -c 4 -r 0.0

# RGB mode with animated palette shift
pipesr --color-mode rgb --palette tokyonight

# an advanced generated truecolor palette
pipesr --color-mode argb --palette catppuccin --rainbow

# custom pipe set (exactly 16 chars)
pipesr -T "fedcba9876543210" -t 10

rgb uses the fixed theme colors directly
argb generates an expanded truecolor palette from the selected theme, which gives smoother hue transitions and denser rainbow cycling

Benchmark (pipesr-bench)

Run core benchmark:

pipesr-bench

Run full terminal rendering benchmark:

pipesr-bench --mode full-render -n 20 -l 200000

Pass pipesr options through benchmark:

pipesr-bench --mode core -- -p 4 -R

Benchmark options

-l, --limit N                        generated chars per run (default: 1000)
-n, --runs N                         benchmark runs (default: 5)
-W, --width N                        logical width (default: 80)
-H, --height N                       logical height (default: 24)
-m, --mode core|full-render          benchmark mode (default: core)
-u, --humanize                       human-readable throughput
-L, --label TEXT                     output label
-h, --help                           help
-v, --version                        version

Output format:

{label} [{mode}]: {cps} c/s

Example:

custom [core]: 19600156 c/s

catppuccin

© 2026-present WhoSowSee

LICENSE

About

Colorful Rust-powered terminal pipes screensaver with palettes, runtime controls, and a built-in benchmark

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages