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 / ramit
Hi Nagesh,
Thanks for the reply but I dont think this will work
as $file= myFile.txt
and mv $file $file.my will rename to myFile.txt.my
I found the solution by extracting basedirectory and
filename then renaming it to req. extension.
thanks
| Is This Answer Correct ? | 2 Yes | 4 No |
Post New Answer View All Answers
What is the difference between scripting and coding?
Set up a Sev 2 alert when the Primary WA service fails. A windows batch script needs to be created that will monitor the WA service on the Primary and when the service stops/fails a Sev 2 TT is generated for a particular team ?
How to print pid of the current shell?
Give some situations where typing error can destroy a program?
What is web script?
What command needs to be used to take the backup?
What is k shell?
How to print all the arguments provided to the script?
How do I edit a .sh file?
Why is a script important?
What are the advantages of using shell scripts?
What is sed in shell script?
Is shell script a programming language?
Is bash an operating system?
is this growing field and what is average package in this?