Skip to content

Latest commit

 

History

History
149 lines (106 loc) · 4.45 KB

README.md

File metadata and controls

149 lines (106 loc) · 4.45 KB

Coverage Downloads Release License

Docker Color Output is a lightweight tool that enhances Docker's command output by adding vibrant, customizable colors. It processes the standard output through a pipeline, making it easier to read and more visually appealing.

Features 🚀

  • Cross-Platform Support: Works on macOS, Linux, and Windows.
  • Customizable Color Schemes: Easily adjust the colors to your preference.
  • Pipeline Integration: Transforms Docker command outputs into colorful, structured displays.

Installation 👨‍💻

You can find all compiled binaries on the releases page.

Mac 🍏

brew install dldash/core/docker-color-output

Linux 🐧

sudo add-apt-repository ppa:dldash/core
sudo apt update
sudo apt install docker-color-output

Windows 🪟

Download the Windows build from the releases page.

Configuration ⚙️

Easily tailor the color scheme to match your personal preferences. Simply run docker-color-output with the-c flag and provide the path to your custom configuration file. You can override any subset of the default colors—any color setting not specified in your file will automatically revert to the default.

docker-color-output -c ~/.config/docker-color-output/config.json
Default Configuration File
{
  "colors": {
    "reset": "\u001b[0m",
    "black": "\u001b[0;30m",
    "darkGray": "\u001b[1;30m",
    "red": "\u001b[0;31m",
    "lightRed": "\u001b[1;31m",
    "green": "\u001b[0;32m",
    "lightGreen": "\u001b[1;32m",
    "brown": "\u001b[0;33m",
    "yellow": "\u001b[1;33m",
    "blue": "\u001b[0;34m",
    "lightBlue": "\u001b[1;34m",
    "purple": "\u001b[0;35m",
    "lightPurple": "\u001b[1;35m",
    "cyan": "\u001b[0;36m",
    "lightCyan": "\u001b[1;36m",
    "lightGray": "\u001b[0;37m",
    "white": "\u001b[1;37m"
  }
}

Silent Mode 🔇

Silent Mode ensures a cleaner output by suppressing error messages. When enabled, if an error occurs, the tool will simply pass through the original Docker output without displaying any error notifications.

docker ps | docker-color-output -s

Usage 📚

Enhance your Docker workflow with these handy aliases and enjoy vibrant outputs.

Aliases 🪄

Utilize the bash functions provided in aliases.sh to streamline your commands.

docker images 💡

di # alias
docker images [--format] | docker-color-output

docker images

docker ps 💡

dps # alias
docker ps [-a] [--format] | docker-color-output

docker ps

docker compose ps 💡

Note

The latest version supports docker compose 2.x.

dcps # alias
docker compose ps | docker-color-output

docker compose ps

docker stats 💡

ds # alias
docker stats [--no-stream] | docker-color-output

docker stats

License 📜

This project is licensed under the MIT License.