How to rename all the files in a folder having specific
extension?
Example: I have some files with extension (.txt) in a folder
name 'Test'. I have to rename all the .txt files in a test
and its subdirectories to .my extension.
Answer Posted / jks
It can be done using the xargs command of Unix ...
cd to the dir containing the *.txt files
$ls *.txt | xargs -i mv \{\} \{\}.my
| Is This Answer Correct ? | 5 Yes | 15 No |
Post New Answer View All Answers
Why is used in shell scripting?
What is console line?
How to get the last line from a file using just the terminal?
What does sh mean?
How to check if the previous command was run successfully?
How to redirect both standard output and standard error to the same location?
Is shell a scripting language?
What is the difference between grep and egrep?
How do I stop script errors?
What is computer cli?
one folder contains lot of students name but I want to fetch hello with every student name individually using shell script
What is web script?
What language is bash?
Explain about the slow execution speed of shells?
How do I run a .sh file?