Click to See Complete Forum and Search --> : BASH headache


TGrimace
10-24-2002, 12:49 PM
Is there a quick and easy command to change all the text inside a text file to lower case (or upper case, it doesn't really matter to me)? It seems like I've done it before, but I can't figure out how to do it again.

TGrimace
10-24-2002, 01:23 PM
I just remembered how. For anyone else that is interested the command is:
cat FILENAME.txt | tr '[:upper:]' '[:lower:]' > NEWFILE.txt

uptimenotifier
10-24-2002, 01:27 PM
tr.

tr A-Z a-z < myfile
tr a-z A_Z < myfile