Renaming lots of files? This trick will save you hours!
Let’s say you have 100 files that are named incorrectly, and you need to change a specific part of it’s name.
The Question would be:
How do I rename several files at the same time?
Answer: You can use a command line interface tool (cli) named Ranger. This tool will allow you to use your favorite text editor, Nano or Vim, to rename files in bulk.
Here are the steps:
Step 0. Ensure you have Ranger installed, if you don’t know how to install it, you can check this article.
Step 1.
In a new terminal, call ranger
and select all the files you want to rename with the spacebar.
Step 2.
Once the files are selected, type :bulkrename
this will open you an editor with the names of the files in it.
Step 3. You can start editing the file names, all changes you make to the names will be applied to the actual filenames of your files, once you’re done, just close and save it.
You will be prompted two times asking if you want to save and close.
Visual Example: