Sunday, February 15, 2009

Linux : tr (translate) command

I made a good use of the translate command recently to get month-name
in upper case. I needed this in a shell script. Here's the command

date +%b | tr [a-z] [A-Z]

Output: FEB

Learn more about tr using the following command

man tr

2 comments:

Anonymous said...

hello... hapi blogging... have a nice day! just visiting here....

Anonymous said...
This comment has been removed by a blog administrator.