Skip to content
GlitchLinuxPublic

About

Transform your terminal output with stunning colored borders! A lightweight, dependency-free bash utility that makes your scripts, logs, and command outputs visually organized and eye-catching.

Resources

Stars

2 stars

Watchers

0 watching

Forks

Latest commit

Β 

History

20 Commits

Folders and files

NameName
Last commit message
Last commit date
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

🎨 BORDERIZE - Beautiful Terminal Text Borders

Transform your terminal output with stunning colored borders! A lightweight, dependency-free bash utility that makes your scripts, logs, and command outputs visually organized and eye-catching.

Version Bash License

borderize-figlet2

✨ Features

  • πŸš€ Instant beautification - Pipe any text or command through borderize
  • 🎨 Dual color support - Customize both border AND text colors
  • 🌈 16.7 million colors - Full 24-bit color (hex code) support
  • πŸ“¦ Zero dependencies - Pure bash, works everywhere
  • ⚑ Lightning fast - No overhead, instant rendering
  • πŸ”§ Multiple input modes - Pipe, file, text, or interactive
  • πŸ’» System-wide installation - One command to rule them all

Basic Usage

# Simple text with default green border
echo "Hello World" | borderize | lolcat
lolcat-borderize
# Custom border color (hex)
echo "Warning!" , "Alert!" , "Success!" | borderize -FF0000

borderize-success borderize-alert borderize-warning

 Installation

# Download the script
wget https://raw.githubusercontent.com/GlitchLinux/BORDERIZE/refs/heads/main/borderize

# Make it executable & Move to PATH
sudo chmod +x borderize && sudo mv borderize /usr/local/bin/

# Verify installation
borderize --help

 Usage Examples

Command Output Styling

# Disk usage with gold border
df -h | borderize -FFD700
borderize-diskusage
# System information with style
uname -a | borderize -ffffff -FF00B8
uname-borderize

Combine with Other Tools

# With figlet and lolcat for ASCII art
figlet -f smslant BORDERIZE | borderize-neon | lolcat
lolcat+figlet
# Multi-line text
borderize -t "Line 1\nLine 2\nLine 3" -00FF00
line-borderize

Command Mode

# Execute and borderize
borderize -c "date" -FF00FF

# Complex commands
borderize -c "ls -la | head -5" -00FFFF -FFFF00

File Input

# Borderize file contents
borderize /etc/hostname -FFA500

# With custom colors
cat /etc/os-release | borderize -567645 -443893

Interactive Mode

# Start interactive mode
borderize

# With custom colors
borderize -FF1493 -00CED1

# Type or paste text, press Ctrl+D to apply border

🎨 Color Schemes

Pre-defined Themes

# Create aliases in ~/.bashrc
alias borderize-neon='borderize -FF00FF -00FFFF'
alias borderize-matrix='borderize -00FF00 -32CD32'
alias borderize-fire='borderize -FF4500 -FFFF00'
alias borderize-ocean='borderize -0080FF -00CED1'
alias borderize-royal='borderize -800080 -FFD700'
alias borderize-dark='borderize -333333 -FFFFFF'

Popular Color Combinations

lolcat-table
Style Command Description
Error -FF0000 -FFFFFF Red border, white text
Success -00FF00 -FFFFFF Green border, white text
Warning -FFA500 -FFFF00 Orange border, yellow text
Info -0080FF -FFFFFF Blue border, white text
Neon -FF00FF -00FFFF Magenta border, cyan text
Matrix -00FF00 -32CD32 Green border, lime text
Gold -FFD700 -FFFFFF Gold border, white text
Ocean -00CED1 -0080FF Turquoise border, blue text

πŸ“š Advanced Usage

In Scripts

#!/bin/bash

# Status messages with semantic colors
echo "βœ“ Task completed" | borderize -00FF00 -FFFFFF
echo "⚠ Warning: Low disk space" | borderize -FFA500 -FFFF00
echo "βœ— Error: Connection failed" | borderize -FF0000 -FFFFFF

# Section headers
echo "=== BACKUP STARTING ===" | borderize -00CED1
perform_backup
echo "=== BACKUP COMPLETE ===" | borderize -00FF00

System Monitoring

#!/bin/bash
# monitoring.sh

echo "SYSTEM STATUS" | borderize -FFD700 -FFFFFF
uptime | borderize -00FFFF
echo ""
echo "MEMORY USAGE" | borderize -FFD700 -FFFFFF
free -h | borderize -00FFFF
echo ""
echo "DISK USAGE" | borderize -FFD700 -FFFFFF
df -h | borderize -00FFFF

Git Hooks

# .git/hooks/pre-commit
#!/bin/bash
echo "Running pre-commit checks..." | borderize -FFFF00

Log Monitoring

# Highlight errors in real-time
tail -f /var/log/syslog | grep ERROR | borderize -FF0000 -FFFFFF

πŸ”§ Options Reference

Option Description Example
-h, --help Show help message borderize --help
-t "text" Borderize given text borderize -t "Hello"
-c command Execute and borderize command borderize -c "ls -la"
-RRGGBB Set border color (hex) borderize -FF0000
-RRGGBB (2nd) Set text color (hex) borderize -FF0000 -FFFFFF

🎯 Features in Detail

Dynamic Border Detection

  • Automatically adjusts border width to fit content
  • Detects variables ($) and uses open-ended borders with ❖ symbols
  • Fixed borders for static content with proper corner characters

Color Support

  • 24-bit true color - Use any hex color code
  • Dual color mode - Separate colors for border and text
  • Fallback support - Defaults to green if invalid hex provided

Input Methods

  1. Pipe: command | borderize
  2. File: borderize filename.txt
  3. Direct text: borderize -t "text"
  4. Command execution: borderize -c "command"
  5. Interactive: Just run borderize

πŸ’‘ Tips & Tricks

Quick Testing

# Test color combinations quickly
echo "TEST" | borderize -$(openssl rand -hex 3) -$(openssl rand -hex 3)

Watch Commands

# Monitor with borders updating every 2 seconds
watch -n 2 'df -h | borderize -00FFFF'

MOTD (Message of the Day)

# Add to /etc/update-motd.d/
echo "Welcome to $(hostname)" | borderize -00CED1 -FFFFFF

πŸ“‹ Requirements

  • Bash 4.0+ (for associative arrays and modern features)
  • Terminal with 24-bit color support (most modern terminals)
  • Unix-like system (Linux, macOS, WSL)

πŸ› Troubleshooting

Colors not showing?

  • Ensure your terminal supports 24-bit colors
  • Try: echo -e "\033[38;2;255;0;0mRed Text\033[0m"

Command not found?

  • Verify installation: which borderize
  • Check PATH: echo $PATH | grep -q /usr/local/bin && echo "OK"

Interactive mode issues?

  • Make sure to press Ctrl+D on a new line
  • Use Ctrl+C to cancel

🀝 Contributing

Found a bug or have a feature idea? Contributions are welcome!

  1. Fork the repository
  2. Create your feature branch
  3. Commit your changes
  4. Push to the branch
  5. Open a Pull Request

πŸ“œ License

MIT License - feel free to use in your projects!

πŸš€ What's Next?

  • Add more border styles (double, dotted, ASCII art)
  • Background color support
  • Animation effects
  • Config file support for saved themes
  • Multi-box layouts

Make your terminal output beautiful! 🎨

If you find this useful, give it a ⭐ on GitHub!

About

Transform your terminal output with stunning colored borders! A lightweight, dependency-free bash utility that makes your scripts, logs, and command outputs visually organized and eye-catching.

Resources

Stars

2 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages