[SOLVED] bulk rename with nemo

Quick to answer questions about finding your way around Linux Mint as a new user.
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions use the other forums in the support section.
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
samiel60

[SOLVED] bulk rename with nemo

Post by samiel60 »

I'm on a LM 19 with defalut Nemo 3.8.6
I've a lot of *.TTF files, and I'd like to change in *.ttf the extension.
I found this guide:
https://community.linuxmint.com/tutorial/view/1935
but if press F2 after selecting files, nothing happens.
Is bulk renaming now present in nemo,
or have I to add or to do anything else?

thanx
s
Last edited by samiel60 on Sun Jan 06, 2019 5:00 pm, edited 1 time in total.
gm10

Re: bulk rename with nemo

Post by gm10 »

That guide is outdated, read the comments.
samiel60

Re: bulk rename with nemo

Post by samiel60 »

so there is no way to rename with nemo?
is it necessary to appeal to console or install thunar?
User avatar
Moem
Level 22
Level 22
Posts: 16238
Joined: Tue Nov 17, 2015 9:14 am
Location: The Netherlands
Contact:

Re: bulk rename with nemo

Post by Moem »

The Software Manager offers some decent rename tools. I have installed and used GPRename and found it easy enough to use, and effective.
Image

If your issue is solved, kindly indicate that by editing the first post in the topic, and adding [SOLVED] to the title. Thanks!
gm10

Re: bulk rename with nemo

Post by gm10 »

samiel60 wrote: Thu Oct 18, 2018 5:35 pm so there is no way to rename with nemo?
is it necessary to appeal to console or install thunar?
That's not what I said. Did you actually read the guide and the comments to it? Both taken together tell you how to do it.
MintBean

Re: bulk rename with nemo

Post by MintBean »

Install Thunar, then in Nemo on the menu edit > preferences > behaviour > bulk rename, enter

Code: Select all

thunar --bulk-rename
and you can then select multiple files and right click->rename.
phd21
Level 20
Level 20
Posts: 10104
Joined: Thu Jan 09, 2014 9:42 pm
Location: Florida

Re: bulk rename with nemo

Post by phd21 »

Hi samiel60,

I just read your post and the good replies to it. Here are my thoughts on this as well.

There are some superb renaming applications that can easily be installed and used like Krename, Gwenrename, pyrenamer, gprename, etc...

There are also many file managers available as well.

While researching this, I did come across this:

nemo is unable to rename files · Issue #1853 · linuxmint/nemo
https://github.com/linuxmint/nemo/issues/1853

Hope this helps ...
Phd21: Mint 20 Cinnamon & KDE Neon 64-bit Awesome OS's, Dell Inspiron I5 7000 (7573, quad core i5-8250U ) 2 in 1 touch screen
User avatar
smurphos
Level 18
Level 18
Posts: 8498
Joined: Fri Sep 05, 2014 12:18 am
Location: Irish Brit in Portugal
Contact:

Re: bulk rename with nemo

Post by smurphos »

phd21 wrote: Thu Oct 18, 2018 7:21 pm pyrenamer
....is a dead project and not available in the default repos for Mint 19 - still available in 18.3 of course. Its a shame as it was my preferred CLI add-on for bulk rename in nemo and a nice GUI renamer in it's own right.

Currently I us GPrename with a nemo custom action. Highlight multiple files in a folder and right click will give a bulk rename option in nemo's context menu. Running it will open the GPrename GUI in that folder.

Code: Select all

cat ~/.local/share/nemo/actions/bulk-rename.nemo_action
[Nemo Action]
Name=Bulk Rename
Comment=Multiple Rename with GPRename.  The action gets executed for the marked or the higher level directory.
Exec=gprename %F
Selection=m
Extensions=any;
EscapeSpaces=true
Dependencies=gprename;
Image
For custom Nemo actions, useful scripts for the Cinnamon desktop, and Cinnamox themes visit my Github pages.
phd21
Level 20
Level 20
Posts: 10104
Joined: Thu Jan 09, 2014 9:42 pm
Location: Florida

Re: bulk rename with nemo

Post by phd21 »

HI smurphos,

I have not had time yet to boot into Cinnamon 19.x to test the file manager renaming, but that is a good suggestion for people using the Cinnamon file manager "Files" (Nemo) that are having trouble with renaming files. Can you give more detailed instructions on how to do this for the less experienced users?

Here is my attempt at more detailed instructions for doing this.

install gprename

Code: Select all

sudo apt install gprename
Open a console terminal to create a new file manager "Action" text file using the "xed" text editor for renaming files in bulk using "gprename".

Code: Select all

sudo xed ~/.local/share/nemo/actions/bulk-rename.nemo_action
Now click "Select All" in the code box below and copy the highlighted text and paste that into the new text file, save the file, exit the text editor, exit the console terminal, restart the file manager.

Code: Select all

[Nemo Action]
Name=Bulk Rename
Comment=Multiple Rename with GPRename.  The action gets executed for the marked or the higher level directory.
Exec=gprename %F
Selection=m
Extensions=any;
EscapeSpaces=true
Dependencies=gprename;
To use: Highlight multiple files in a folder within the file manager and right click will give a bulk rename option in nemo's context menu. Running it will open the GPrename GUI in that folder.


FYI: "Krename" can easily be installed through the Software Manager or Synaptic Package Manager (SPM) and could easily rename files for this as well as more complex renaming functions.

Hope this helps ...
Phd21: Mint 20 Cinnamon & KDE Neon 64-bit Awesome OS's, Dell Inspiron I5 7000 (7573, quad core i5-8250U ) 2 in 1 touch screen
phd21
Level 20
Level 20
Posts: 10104
Joined: Thu Jan 09, 2014 9:42 pm
Location: Florida

Re: bulk rename with nemo

Post by phd21 »

Hi samiel60,

There have been some new good replies to your post ...

I forgot to mention that most file managers can rename multiple files by filename, but it is very unusual (uncommon) for most file managers to be able to change multiple files extensions like from ".TTF" to ".ttf".

And the suggestion from "smurphos" works well (Thanks), although you have to reselect the files once the "gprename" program comes up (Ctrl+A = select all), recommend changing "gprename" options to "auto preview".

As I stated before, there are other file managers available and there is nothing wrong with having more than one installed. If anyone wants to try the superb Dolphin file manager, then see the post below:

Previous post with instructions for install Dolphin file manager
Can't get an image preview at file manager
viewtopic.php?f=208&t=268018&p=1460132#p1460132


Hope this helps ...
.
LM_Cinn19_FileManager_Bulk_Rename1.jpg
.
LM_Cinn19_FileManager_Bulk_Rename2.jpg
.
. click to view animated gif image
Krename1-2-3.gif
Phd21: Mint 20 Cinnamon & KDE Neon 64-bit Awesome OS's, Dell Inspiron I5 7000 (7573, quad core i5-8250U ) 2 in 1 touch screen
User avatar
smurphos
Level 18
Level 18
Posts: 8498
Joined: Fri Sep 05, 2014 12:18 am
Location: Irish Brit in Portugal
Contact:

Re: bulk rename with nemo

Post by smurphos »

phd21 wrote: Fri Oct 19, 2018 11:23 am Can you give more detailed instructions on how to do this for the less experienced users?

Here is my attempt at more detailed instructions for doing this.
Hi phd21,

Good instructions but i've made a couple of amendments

Removed one optional sudo (Mint's apt will prompt for password without explicitly using sudo) and one unnecessary sudo (the nemo action file is in the users home folder and is user owned). Even if it was a root location in Mint 18.x gksudo xed should be used or in Mint 19 xed admin:///

Just a note that if the user navigates to ~/.local/share/nemo/actions in Nemo and clicks the 'More Info' button in the Info bar it opens a commented template for making a custom nemo action in the default text editor. That's a nice touch from the devs for this particular feature.
phd21 wrote: Fri Oct 19, 2018 11:23 aminstall gprename

Code: Select all

apt install gprename
Open a console terminal to create a new file manager "Action" text file using the "xed" text editor for renaming files in bulk using "gprename".

Code: Select all

xed ~/.local/share/nemo/actions/bulk-rename.nemo_action
Now click "Select All" in the code box below and copy the highlighted text and paste that into the new text file, save the file, exit the text editor, exit the console terminal, restart the file manager.

Code: Select all

[Nemo Action]
Name=Bulk Rename
Comment=Multiple Rename with GPRename.  The action gets executed for the marked or the higher level directory.
Exec=gprename %F
Selection=m
Extensions=any;
EscapeSpaces=true
Dependencies=gprename;
To use: Highlight multiple files in a folder within the file manager and right click will give a bulk rename option in nemo's context menu. Running it will open the GPrename GUI in that folder.
For custom Nemo actions, useful scripts for the Cinnamon desktop, and Cinnamox themes visit my Github pages.
teamspoad

Re: bulk rename with nemo

Post by teamspoad »

SIMPLE ANSWER:. Install thunar (no need to run it), then enter simple code into nemo preferences, under bulk rename, as follows:

thunar --bulk-rename

This works, with f2 (w/o any code or regestering), on my mint 19 with nemo 3.8.6
It's really quick, easy, works well, has preview, string options, and gui. It JUST works

Steps:

Sudo apt install thunar
Close terminal, no need to open or use thunar
-now open up Nemo and go to preferences
---edit-->preferences -->behavior (top tab)
-------at the bottom, "command to invoke when renaming multiple items", enter:

thunar --bulk-rename

Close preferences and THAT'S IT!
How did everyone make this so difficult?

---------- The END ------

Another similar, fun, and easy thing to do is install scripts in nemo.
Simply make scripts executable and add them to nemos script library. Great collection of them , search web:

Ultimate nemo scripts pack

With them you can try 100s of things from right click in nemo, like picture adjustments, file conversions, compression, server comm, the list is huge and powerful. You can organise your favorites. But you have to make the scripts executable or they wont show up in nemo.
arso96

Re: bulk rename with nemo

Post by arso96 »

Hello,
I don't understand why nobody commented here to say "Thank You!" :)
Yep, I'm new to linux and been wondering what's that option about. I use FileBot for bulk renaming (awesome app btw) but they are for my multimedia files.
Just wanted to let you know that your explanation and descriptions are so neat. I hope your scripts are as good too, I am going to check and will give my feedback later maybe :)
Now heading to your other tutorials even though I'm not particularly in need ;)
Regards
Last edited by SMG on Tue Nov 01, 2022 8:48 pm, edited 2 times in total.
Reason: Removed links from post.
srq2625

Re: bulk rename with nemo

Post by srq2625 »

I know you are looking for a GUI solution, but there's a simple terminal solution:
  1. Open a terminal window
  2. Change to the folder hosting the files with a command of the form: cd /path/to/folder
  3. I believe the command would be

    Code: Select all

    rename 's/\.TTF$/.ttf/' *.TTF
  4. Inspect the file names in the file manager of your choice
  5. Close the terminal window
ismail783
Level 2
Level 2
Posts: 99
Joined: Tue Jul 10, 2018 10:34 am

Re: [SOLVED] bulk rename with nemo

Post by ismail783 »

There is an awesome solution. The solution is https://www.inviska.com/rename/

It is released under the GPLv2+ licence

I wrote to the author of this application regarding it's integration with Nemo. My question is quoted bellow -
How to integrate Inviska Rename with Nemo's bulk rename feature?

For example, to use Thuner's bulk rename we follow the following procedure -

Install Thunar, then in Nemo on the menu edit > preferences > behaviour > bulk rename, enter

Code: Select all

thunar --bulk-rename

His solution uses the appImage. Bellow I am paraphrasing his answer.

Unfortunately, Inviska Rename can't be configured to work with Nemo's bulk rename option.

Inviska Rename works with directories while Nemo sends a list of files.

What you could do is associate Inviska Rename with folders in Nemo. Right click on a folder, go to Open With and then Other Application...
1.png
1.png (14.18 KiB) Viewed 13693 times

In the box at the bottom enter your /path/to/Inviska_Rename-10.0-x86_64.AppImage and click Add to list and then click Cancel.
2.png

After that you could right-click on a folder in Nemo, go to Open With and select Inviska Rename. That folder would then open in Inviska Rename.
3.png
3.png (18.46 KiB) Viewed 13693 times
I'm not sure if that would be any use to you, but that's probably the best way to integrate Inviska Rename with Nemo.
For me this is already a great solution. However, if the Linux Mint team take the source code and make the changes so that it sends list of files to nemo then it will be even better (we would be able to select multiple files and press the sweet 😉 F2 button).

NOTE: CHECH MY NEXT POST WITH THE UPDATE FROM THE Inviska Rename AUTHOR WHERE HE HAS modified the source code to make Inviska Rename COMPATIBLE WITH NEMO
ismail783
Level 2
Level 2
Posts: 99
Joined: Tue Jul 10, 2018 10:34 am

Re: [SOLVED] bulk rename with nemo

Post by ismail783 »

Well! Well!! Well !!! What do we have here. I came back from my eid vacation and there was an email sitting on my inbox from the Inviska Rename author, Richard himself. And I quote -

I've modified Inviska Rename so it works slightly better with Nemo. You can specify the Inviska Rename AppImage as the Bulk Rename program in Nemo:
unnamed.png
You can then highlight files and choose rename:
un2.png
Inviska Rename will now start in the directory of the highlighted files:
un3.png
It's still not great, but it's a slight improvement. I've uploaded a modified build of version 10 at the below link. I'll also include the change in the next release.

https://www.inviska.com/files/temp/Invi ... 4.AppImage
original_tbird

Re: [SOLVED] bulk rename with nemo

Post by original_tbird »

Hi ismail783, I was looking at your post and the helpful tool. However, going to the Inviska site it appears that it is no longer active (replaced by an adult web site it appears?). I know you had access to the developer's contact information - would you be able to private message me the information, or reach out yourself to check on the status of things? I was hoping to ask him for a copy of his most recent builds and/or source code for Inviska Rename and MKVExtract. Thank you for your help, hopefully we can keep this great tool alive!
ismail783 wrote: Sat Aug 17, 2019 1:28 am Well! Well!! Well !!! What do we have here. I came back from my eid vacation and there was an email sitting on my inbox from the Inviska Rename author, Richard himself. And I quote -

I've modified Inviska Rename so it works slightly better with Nemo. You can specify the Inviska Rename AppImage as the Bulk Rename program in Nemo:



You can then highlight files and choose rename:



Inviska Rename will now start in the directory of the highlighted files:



It's still not great, but it's a slight improvement. I've uploaded a modified build of version 10 at the below link. I'll also include the change in the next release.

https://www.inviska.com/files/temp/Invi ... 4.AppImage
mickleberry

Re: bulk rename with nemo

Post by mickleberry »

MintBean wrote: Thu Oct 18, 2018 6:38 pm Install Thunar, then in Nemo on the menu edit > preferences > behaviour > bulk rename, enter

Code: Select all

thunar --bulk-rename
and you can then select multiple files and right click->rename.
This answer was a long time ago, and there's at least one other person on this page who suggested it.. i just want to say THANK YOU for a super easy fix. It worked perfectly for me and was very straightforward
a) install thunar
b) add thunar as bulk renaming app within Nemo

brilliant
Locked

Return to “Beginner Questions”