diff options
author | EuAndreh <eu@euandre.org> | 2022-08-12 18:54:53 -0300 |
---|---|---|
committer | EuAndreh <eu@euandre.org> | 2022-08-12 18:54:53 -0300 |
commit | 9a3a2e87235098d67072848589764e7d25832bf1 (patch) | |
tree | eba32bf99f8f02af6d1fe06224e0019339c625a9 | |
parent | bin/assert-arg: Add helper utility (diff) | |
download | dotfiles-9a3a2e87235098d67072848589764e7d25832bf1.tar.gz dotfiles-9a3a2e87235098d67072848589764e7d25832bf1.tar.xz |
bin/color: Add "Examples" section to help string
-rwxr-xr-x | bin/color | 18 |
1 files changed, 17 insertions, 1 deletions
@@ -12,15 +12,31 @@ usage() { help() { cat <<-'EOF' - Options: -c COLOR -h, --help show this message + Print the given text with a color. + The available colors are: EOF list_colors | sed 's/^/ /' + + cat <<-'EOF' + + Examples: + + Print "banana" in yellow: + + $ color -c yellow 'banana' + banana + + Print "grass" in green, with a newline: + + $ color -c green 'grass\n' + grass + EOF } |