Bulk Rename help

Please check the FAQ (https://www.xyplorer.com/faq.php) before posting a question...
Post Reply
wa1tesefa1c0n
Posts: 2
Joined: 19 Nov 2021 18:43

Bulk Rename help

Post by wa1tesefa1c0n »

Hey all good day!

I've been using XYPlorer recently to clean up files I have. I've been removing duplicate files. While doing this, I noticed several of my files were restored from a backup. I don't recall when but when it took place, several of my files have had a date added in parenthesis. For example, textfile.txt is now textfile (2017_02_23 04_46_43 UTC).txt

Is there a way to search all my files that have (%Year%_%month%_%date%_%time%) in the name of the file?
If there is, do you have any suggestions for me?

Once I find those files, I'll want to do a bulk rename to remove (%Year%_%month%_%date%_%time%). Is there a way to target the rename to do this?

Appreciate any suggestions or advice, thanks!

highend
Posts: 13274
Joined: 06 Feb 2011 00:33

Re: Bulk Rename help

Post by highend »

Switch the mode to regexp (in the search panel) and use this as the name:
[ ]\(\d{4}_\d{2}_\d{2} \d{2}_\d{2}_\d{2} UTC\)

Select all matches, right click context menu - rename special - regexp rename...

[ ]\(\d{4}_\d{2}_\d{2} \d{2}_\d{2}_\d{2} UTC\) > 


There is a trailing space after the >!
One of my scripts helped you out? Please donate via Paypal

admin
Site Admin
Posts: 60357
Joined: 22 May 2004 16:48
Location: Win8.1 @100%, Win10 @100%
Contact:

Re: Bulk Rename help

Post by admin »

Tip: Wrap the C-Tags in Pre-Tags to preserve the trailing space. (I did that for you.)

wa1tesefa1c0n
Posts: 2
Joined: 19 Nov 2021 18:43

Re: Bulk Rename help

Post by wa1tesefa1c0n »

highend wrote: 19 Nov 2021 20:54 Switch the mode to regexp (in the search panel) and use this as the name:
[ ]\(\d{4}_\d{2}_\d{2} \d{2}_\d{2}_\d{2} UTC\)

Select all matches, right click context menu - rename special - regexp rename...

[ ]\(\d{4}_\d{2}_\d{2} \d{2}_\d{2}_\d{2} UTC\) > 


There is a trailing space after the >!
Wow, I can't believe it. This works without very much effort at all. Thank you so very much!

-Wa1teseFa1c0n

Post Reply