Rdb: Ruby-Nachbau der MWC /rdb-Werkzeuge
This commit is contained in:
+54
@@ -0,0 +1,54 @@
|
||||
.TH cap "" "" "/rdb Command"
|
||||
.PC "Convert first letter of each word to upper case"
|
||||
\fBcap < \fItextfile\fR
|
||||
.PP
|
||||
.II "text^capitalize"
|
||||
.II "capitalize text"
|
||||
The command
|
||||
.B cap
|
||||
capitalizes the first letter of each word in
|
||||
.IR textfile .
|
||||
It writes its results to the standard output.
|
||||
.SH Example
|
||||
Assume that table
|
||||
.B Inventory
|
||||
has the following data:
|
||||
.DM
|
||||
Item Amount Cost Value Description
|
||||
---- ------ ---- ----- --------------
|
||||
1 3 50 150 rubber gloves
|
||||
2 100 5 500 test tubes
|
||||
3 5 80 400 clamps
|
||||
4 23 19 437 plates
|
||||
5 99 24 2376 cleaning cloth
|
||||
6 89 147 13083 bunsen burners
|
||||
7 5 175 875 scales
|
||||
.DE
|
||||
.PP
|
||||
As you can see, the column
|
||||
.B Descriptions
|
||||
has consists of words all in lower case.
|
||||
To capitalize the first letter of each word in
|
||||
.B Inventory
|
||||
file, type:
|
||||
.DM
|
||||
cap < Inventory
|
||||
.DE
|
||||
.PP
|
||||
This writes the following on the screen:
|
||||
.DM
|
||||
Item Amount Cost Value Description
|
||||
---- ------ ---- ----- --------------
|
||||
1 3 50 150 Rubber Gloves
|
||||
2 100 5 500 Test Tubes
|
||||
3 5 80 400 Clamps
|
||||
4 23 19 437 Plates
|
||||
5 99 24 2376 Cleaning Cloth
|
||||
6 89 147 13083 Bunsen Burners
|
||||
7 5 175 875 Scales
|
||||
.DE
|
||||
.SH "See Also"
|
||||
.B
|
||||
lowercase,
|
||||
uppercase
|
||||
.R
|
||||
Reference in New Issue
Block a user