How to translate lower case to upper?
How could I translate lower case to upper case by using commands on Linux S.US.E,Â
Output should be seen on file not on terminal. What command should be used?
Answer in simple way.
How could I translate lower case to upper case by using commands on Linux S.US.E,Â
Output should be seen on file not on terminal. What command should be used?
Answer in simple way.
You can do it by writing a program on shell script and creating a file. Output will be seen on the file o extension .caps. Which will be auto generated at run time.
Let me give you a demo program so that you can get familiar of it. Take it as tutorial.Â
Write command for creating shall script. Let’s name it as a.sh. write a program within it.
Â
#!/big/bash ( this is bang line)
For file
Do
tr a-z A-Z <$file>$file.caps
done
(Program ended. Now you need to come out from this mode by pressing ctrl+D)
Now gives user rights.
Chmod +x a.sh
Â
Â
Now create a file on desktop manually by write click on vacant space. Go to new and click on file. Named that file as a. write your note on fila a.
 ./a.sh a
Â
Â
Since, a.sh is shell script and a is a file name.
You will see the output. When click on the .caps file. Which is auto generated. In this file you will see your note in caps or upper case or capital letters. that will be your required output.
Â
Â
First create a text file in your desktop manually named Test.txt, then jump to the command line and use the below command shown to get the output in File Test.txt
$ echo chris| tr ‘[:lower:]’ ‘[:upper:]’  > Test.txt
Result will be CHRIS, which will be shown in the file Test.txt.