I want to know the command that will convert upper-case characters to lower-case characters and lower-case characters to upper-case characters.
It has to work in the shell of Unix machines.
tr A-Za-z a-zA-Z
(unfortunately, ascii only)
cat file1 | tr 'a-zA-Z' 'A-Za-z'
You could pipe your file into perl with the answer provided here:
Perl, using tr function to convert uppercase to lowercase and vice-versa at the same time?
To get lowercase: sed -i 's/\(.*\)/\L\1/' somefilename
To get uppercase: sed -i 's/\(.*\)/\U\1/' somefilename