Skip to main content

pipes.py

A Python implementation of the classic pipes.sh. Watch colorful pipes grow and spread across your terminal in mesmerizing patterns.

Python License Version

Buy Me a Coffee Traktir Saya Kopi

What's new in v2.0.0 ?!

Major rewrite. Here's what changed:

Tooling:

  • Poetry → uv
  • Added mypy (strict type checking)
  • Added ruff (linter)
  • Reorganized from src/pipes/py/ to src/pipes/

Code:

  • Split into modules instead of one big file
  • Full type hints
  • Better architecture

Breaking:

  • Needs Python 3.10+
  • Module path changed (but CLI is same)

All CLI arguments work the same. Config format is backwards compatible.

Install

pip install pipes-py

Build from source:

git clone https://github.com/elliottophellia/pipes.py
cd pipes.py
uv build
pip install dist/pipes_py-2.0.0-py3-none-any.whl

Usage

pipes-py                    # basic
pipes-py -p 5 -f 60         # 5 pipes at 60 fps
pipes-py -R -P 2            # random start with curved pipes
pipes-py -p 3 -C -B         # 3 pipes, no color, no bold

Options

-p, --pipes N         number of pipes (default: 1)
-f, --fps N           frames per second, 20-100 (default: 75)
-s, --steady N        steadiness, 5-15 (default: 13)
-r, --limit N         character limit before screen reset
-R, --random          start pipes at random positions
-B, --no-bold         disable bold characters
-C, --no-color        disable colors
-P N                  pipe style 0-9 (default: 0)
-K, --keep-style      keep pipe style when wrapping around screen
-S, --save-config     save current settings as default
-v, --version         show version

Quit with ? or ESC.

Interactive keys

While running:

  • O - decrease steadiness (more turns)
  • P - increase steadiness (fewer turns)
  • D - decrease FPS (slower)
  • F - increase FPS (faster)
  • B - toggle bold
  • C - toggle color
  • K - toggle keep style on wrap

Pipe styles

10 styles available:

  • 0 - heavy box-drawing (┃┏┓┛━)
  • 1 - curved (│╭╮╯─)
  • 2 - light box-drawing (│┌┐┘─)
  • 3 - double box-drawing (║╔╗╝═)
  • 4 - knobby (|+-+)
  • 5 - angles (|/-)
  • 6 - dots (.o...)
  • 7 - dots with o (.ooo.)
  • 8 - slashes (-/|)
  • 9 - mixed Unicode (╿┍┑┚╼)

Try them: pipes-py -P 1 -p 3

Config

Config location:

  • Linux/macOS: ~/.config/pipes-py/config.json
  • Windows: %LOCALAPPDATA%\pipes-py\config.json
{
  "pipes": 1,
  "fps": 75,
  "steady": 13,
  "limit": 2000,
  "random_start": false,
  "bold": true,
  "color": true,
  "keep_style": false,
  "colors": [1, 2, 3, 4, 5, 6, 7, 0],
  "pipe_types": [0]
}

Use -S to save current settings or edit the file directly.

Dev

git clone https://github.com/elliottophellia/pipes.py
cd pipes.py
uv sync
uv run python -m pipes

# checks
uv run ruff check src/pipes
uv run mypy src/pipes

# build
uv build

Code is in src/pipes/:

  • types.py - enums/dataclasses
  • config.py - file I/O
  • renderer.py - drawing
  • pipes.py - state
  • __main__.py - CLI

License

This project is licensed under the Creative Commons Attribution Share Alike 4.0 International (CC-BY-SA-4.0). For more information, please refer to the LICENSE file included in this repository.

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/AmazingFeature)
  3. Write your amazing code
  4. Make sure pass ruff check and mypy first
  5. Commit your changes (git commit -m 'Add some AmazingFeature')
  6. Push to the branch (git push origin feature/AmazingFeature)
  7. Open a Pull Request

Metadata

Release files for pipes-py 2.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pipes-py 2.0.0
File Size Uploaded
pipes_py-2.0.0.tar.gz 25.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pipes-py 2.0.0
File Interpreter ABI Platform
pipes_py-2.0.0-py3-none-any.whl Python 3 none any Details

Total release size: 41.4 kB

Release files / pipes_py-2.0.0.tar.gz

Download URL pipes_py-2.0.0.tar.gz
Size 25.7 kB
Tags Source
SHA-256 checksum
How to use checksums
4a7c8456e7e4b8781b97cc918e77a61f1c434c03f21fed41f0f5e18f92acd930
BLAKE2b-256 checksum
How to use checksums
debb863bb639fbed9cb5e35be1ceaff530cf883769cfae2d4bd7698112757663
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.9.9 {"installer":{"name":"uv","version":"0.9.9"},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / pipes_py-2.0.0-py3-none-any.whl

Download URL pipes_py-2.0.0-py3-none-any.whl
Size 15.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
dc43e35f566e4a78912868615b5647340fb32b2c5d6a1e0ff7bde56384583868
BLAKE2b-256 checksum
How to use checksums
d9077e4ce2cf3954303e4a6c294df1a91f8e05c3d7c5bdb17d1b1f705b3085e8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.9.9 {"installer":{"name":"uv","version":"0.9.9"},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release history Release notifications | RSS feed

This release

2.0.0 This release

2 release files

1.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page