Move specific filename content to beginning of file name

Javascript renaming examples. Javascript renaming is supported in version 3 or newer.

Move specific filename content to beginning of file name

Postby ldearley » Fri Oct 21, 2016 6:21 pm

Hi this is my first post here but I am a long time geek; though I only varely dabble in scripting.

Here is my goal.

I have a series of folders full of files. Each file has a number or series of numbers embedded in parenthesis. I would like to rename these files and move either just the numbers or the parenthesis and everything within to the front of the file name.

Current Name
"File name yadda yadda (30, 26 etc).ext"

Target Name
Option 1: "30,26 etc File Name yadda yadda.ext"
Option 2: "(30, 26 etc) File Name yadda yadda.ext"

Thanks ahead of time!
ldearley
 
Posts: 1
Joined: Fri Oct 21, 2016 6:10 pm

Re: Move specific filename content to beginning of file name

Postby therube » Fri Oct 21, 2016 9:01 pm

1:RegEx
Code: Select all
Match:  (.*)(\(.*\))
Replace:  \2 \1
therube
 
Posts: 316
Joined: Mon Jan 18, 2016 6:23 pm


Return to Javascript Renaming