| User: editor -- 2008-05-22 << 145 147 >> |
| Hits: 4381 |
| Type: Batch file rename |
| Search all Batch file rename examples |
| Description: |
| How to rename files by removing the characters between '(' and ')'? |
| Input Sample: |
| file1(aaa bbb).txt file2(yes).txt file3(xxx xxx).txt ... |
| Output Sample: |
| rename "file1(aaa bbb).txt" "file1.txt" rename "file2(yes).txt" "file2.txt" rename "file3(xxx xxx).txt" "file3.txt" rename "..." "..." |
| Answer: |
| Hint: You need to Download and install "Replace Pioneer" on windows platform to finish following steps. |
| ======================= For version 2.1 1. open menu 'Tools->Batch Runner' 2. click 'Pick files' select multiplue files 3. sort these files by name or date or others, by clicking different column titles. 4. change 'set output filename' entry from ${FILENAME} to: and click 'Apply' at right. 5. click 'Rename', finish. ======================= For version 2.0 and above: 1. Run Menu "File->Load->DOS command output", enter "dir /b" as your DOS command, and enter your working directory, click 'OK', you will get all files listed in your editor's window. 2. Press ctrl-h to open 'Replace' dialog 1)Set 'Replace Unit' to 'Line' 2)Fill the window under 'Search for Pattern' to: 3)Fill the window under 'Replace with Pattern' to: 4)Click 'Replace' 3. save to r.bat and run r.bat. |
| Download Script: scripts/146.rst.zip |
Screenshot 1: Batch_Runner_Window |