]> git.refcnt.org Git - colorize.git/commitdiff
Add examples to man page
authorSteven Schubiger <stsc@refcnt.org>
Sat, 23 Feb 2019 18:56:20 +0000 (19:56 +0100)
committerSteven Schubiger <stsc@refcnt.org>
Sat, 23 Feb 2019 18:56:20 +0000 (19:56 +0100)
colorize.1

index 9bd2229c2e97dbe4b0f6ea88db61d080bd4b1225..3b114dd63de46e5a0d7585834bb6480687f3eb09 100644 (file)
@@ -1,4 +1,4 @@
-.TH COLORIZE 1 "2018-01-31" "colorize v0.64" "User Commands"
+.TH COLORIZE 1 "2019-02-23" "colorize v0.64" "User Commands"
 .SH NAME
 colorize \- colorize text on terminal with ANSI escape sequences
 .SH SYNOPSIS
@@ -62,5 +62,21 @@ as follows:
 40-47,49 (background colors)
 .IP * 4
 0 (reset)
+.SH EXAMPLES
+.TP
+$ \fBcolorize green /etc/motd\fR
+Print file /etc/motd with green as foreground color
+.TP
+$ \fBcolorize green/black /etc/motd\fR
+Print file /etc/motd with green as foreground and black as background color
+.TP
+$ \fBcolorize green /etc/motd | colorize --clean\fR
+Print input from stdin with color escape sequences omitted
+.TP
+$ \fBgit log -1 -p --color | colorize --clean-all\fR
+Print input from stdin with all color escape sequences omitted
+.TP
+$ \fBcolorize --attr=bold green /etc/motd\fR
+Print file /etc/motd with bold green as foreground color
 .SH AUTHOR
 Steven Schubiger <stsc@refcnt.org>