Git Product home page Git Product logo

pipes-rs's Introduction

pipes-rs

Bors enabled GitHub Actions CI status

An over-engineered rewrite of pipes.sh in Rust

pipes-rs preview

Installation

Install on any platform using Cargo:

cargo install --git https://github.com/lhvy/pipes-rs

Alternatively for macOS, install via Homebrew:

brew install lhvy/tap/pipes-rs

Alternatively for Windows, install via Scoop:

scoop bucket add extras
scoop install pipes-rs

Manual Download

Download compiled binaries from releases.

Windows Font Issues

There have been reports that some characters pipes-rs uses are missing on Windows, which causes them to appear as tofu. If you experience this issue, try using a font with a large character set, such as Noto Mono.

Keybindings

  • r: reset the screen
  • q or ^C: exit the program

Configuration

pipes-rs can be configured using TOML located at ~/.config/pipes-rs/config.toml. The following is an example file with the default settings:

bold = true
color_mode = "ansi" # ansi, rgb or none
palette = "default" # default, darker, pastel or matrix
rainbow = 0 # 0-255
delay_ms = 20
inherit_style = false
kinds = ["heavy"] # heavy, light, curved, knobby, emoji, outline, dots, blocks, sus
num_pipes = 1
reset_threshold = 0.5 # 0.0–1.0
turn_chance = 0.15 # 0.0–1.0

Color Modes

Mode Description
ansi pipe colors are randomly selected from the terminal color profile, default option
rgb pipe colors are randomly generated rgb values, unsupported in some terminals
none pipe colors will not be set and use the current terminal text color

Palettes

Palette Description
default bright colors – good on dark backgrounds, default option
darker darker colors – good on light backgrounds
pastel pastel colors – good on dark backgrounds
matrix colors based on Matrix digital rain – good on dark backgrounds

Pipe Kinds

Kind Preview
heavy ┃ ┃ ━ ━ ┏ ┓ ┗ ┛
light │ │ ─ ─ ┌ ┐ └ ┘
curved │ │ ─ ─ ╭ ╮ ╰ ╯
knobby ╽ ╿ ╼ ╾ ┎ ┒ ┖ ┚
emoji 👆 👇 👈 👉 👌 👌 👌 👌
outline ║ ║ ═ ═ ╔ ╗ ╚ ╝
dots • • • • • • • •
blocks █ █ ▀ ▀ █ █ ▀ ▀
sus ඞ ඞ ඞ ඞ ඞ ඞ ඞ ඞ

Due to emojis having a different character width, using the emoji pipe kind along side another pipe kind can cause spacing issues.

Options

There are also command line options that can be used to override parts of the configuration file:

Option Usage Example
-b toggles bold text -b true
-c sets the color mode -c rgb
-d sets the delay in ms -d 15
-i toggles if pipes inherit style when hitting the edge -i false
-k sets the kinds of pipes, each kind separated by commas -k heavy,curved
-p sets the number of pipes on screen -p 5
-r sets the percentage of the screen to be filled before resetting -r 0.75
-t chance of a pipe turning each frame -t 0.15
--palette sets the color palette, RGB mode only --palette pastel
--rainbow sets the number of degrees per frame to shift the hue of each pipe, RGB mode only --rainbow 5

Credits

Contributors

pipes-rs is maintained by lhvy and lunacookies; any other contributions via PRs are welcome! Forks and modifications are implicitly licensed under the Blue Oak Model License 1.0.0. Please credit the above contributors and pipes.sh when making forks or other derivative works.

Inspiration

This project is based off of pipes.sh.

pipes-rs's People

Contributors

dependabot[bot] avatar lhvy avatar lunacookies avatar sitiom avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.