Move feature missing "POSITION FROM RIGHT"

With NameWiz, you can rename files en-masse in either a single folder or all sub folders. Change the file extension, make all names lower/upper case, replace, remove, insert, delete, move or swap characters, add prefixes and suffixes, or replace the names altogether with sequential names of your choosing.
Post Reply
JessKaufman
Posts: 8
Joined: Mon Feb 03, 2014 4:30 pm

Move feature missing "POSITION FROM RIGHT"

Post by JessKaufman »

I love NameWiz and dont' know how I would live without it. It has been well thought out and includes so many possibilities, i can almost always use it to solve my renaming issues. Now and then i find myself wishing it supported something it does not.

For example, right now I have a large quantity of music directories with the names of albums and the year they were released. I have been able to strip out and format the names the way i want, but the four digit year (such as "1984) is at the END of the directory name. I would love to be able to MOVE the year to the beginning of the file name so the directories can be sorted in chronological order. However, the MOVE command does not have a "POSITION FROM RIGHT" check box, as the INSERT command does. If it did, i could MOVE four characters using position 1 (with POSITION FROM RIGHT box checked) and a character count of 4 to position 1. Each directory name is of different length, so i do not see any way to move the year from the end of each name to the beginning, other than doing it manually (not feasible for hundreds of names).

Am i missing something, or is NameWiz missing something??
JessKaufman
Posts: 8
Joined: Mon Feb 03, 2014 4:30 pm

Re: Move feature missing "POSITION FROM RIGHT"

Post by JessKaufman »

By the way, do you plan any new updates for the software ... its been a long time.
User avatar
Support
Site Admin
Posts: 2986
Joined: Sun Oct 02, 2011 10:49 am

Re: Move feature missing "POSITION FROM RIGHT"

Post by Support »

Use the RegEx Rename plugin and in the "Mask", put in...

Code: Select all

(.*)(\d{4})$
and in the "Change to" make that...

Code: Select all

$2 $1
and this should move the year to the beginning of the file name.

We didn't have any reason to update NameWiz but now that you mention about no checkbox for the right position, we'll work on it.
Your support team.
https://SoftByteLabs.com
JessKaufman
Posts: 8
Joined: Mon Feb 03, 2014 4:30 pm

Re: Move feature missing "POSITION FROM RIGHT"

Post by JessKaufman »

Great, i'll try this out.

Love the fact that you will incorporate my suggestions. I had a few other "wishes" and when I remember what they were,will let you know.
User avatar
Support
Site Admin
Posts: 2986
Joined: Sun Oct 02, 2011 10:49 am

Re: Move feature missing "POSITION FROM RIGHT"

Post by Support »

Suggestions are always welcome. Thanks.
Your support team.
https://SoftByteLabs.com
JessKaufman
Posts: 8
Joined: Mon Feb 03, 2014 4:30 pm

Re: Move feature missing "POSITION FROM RIGHT"

Post by JessKaufman »

Worked like a charm. Wish i understood it, or the plug in was documented somewhere.
User avatar
Support
Site Admin
Posts: 2986
Joined: Sun Oct 02, 2011 10:49 am

Re: Move feature missing "POSITION FROM RIGHT"

Post by Support »

That's regular expressions as found in the Perl documentation. Basically it goes as follow...

.* mean everything, and if in between parenthesis, it means assign the match to $1
\d means a single digit from 0 to 9 and the {4} means four of those digits. The match will be assigned to $2 as it is enclosed in the second set of parenthesis.

$ mean the end of the line, in this case, then end of the file name.

As for the "Change to", we used the result from the match, that is, $2 and $1 which means the year was saved in $2 and the rest of the file name in $1. If you put in $1$2 the name would have stayed the same.

So (.*)(\d{4})$ means to match any characters up but not including a 4 digit number and save it in $1, following by that 4 digit number but that number must be at the end of the file name, then assign it to $2. If a file name does not match this regular expression, nothing is returned in $1 and $2
Your support team.
https://SoftByteLabs.com
JessKaufman
Posts: 8
Joined: Mon Feb 03, 2014 4:30 pm

Re: Move feature missing "POSITION FROM RIGHT"

Post by JessKaufman »

Great, thanks.

This works great on renaming directories, but does not seem to work for renaming files. What am i missing?
User avatar
Support
Site Admin
Posts: 2986
Joined: Sun Oct 02, 2011 10:49 am

Re: Move feature missing "POSITION FROM RIGHT"

Post by Support »

Can you give me an example of what you are trying to rename?
Your support team.
https://SoftByteLabs.com
JessKaufman
Posts: 8
Joined: Mon Feb 03, 2014 4:30 pm

Re: Move feature missing "POSITION FROM RIGHT"

Post by JessKaufman »

132010.avi
Blitz2011.avi
Cellular2004.avi
Chaos2005.avi
Collateral2004.avi
Crank 2 - High Voltage2009.avi
Crank2006.avi
Death Race2008.avi


Wanting to move the 4 digit year at the end to the beginning of the line. works great for directories. perhaps because of the extension?
User avatar
Support
Site Admin
Posts: 2986
Joined: Sun Oct 02, 2011 10:49 am

Re: Move feature missing "POSITION FROM RIGHT"

Post by Support »

ok, the "Mask" should be...

Code: Select all

(.*)(\d{4})(\..*)$
and the "Change to" should be

Code: Select all

$2$1$3
This RegEx take into consideration that there is a file extension.
Your support team.
https://SoftByteLabs.com
JessKaufman
Posts: 8
Joined: Mon Feb 03, 2014 4:30 pm

Re: Move feature missing "POSITION FROM RIGHT"

Post by JessKaufman »

worked perfectly. Thanks!
toddward
Posts: 1
Joined: Sat Aug 06, 2016 8:44 am

Re: Move feature missing "POSITION FROM RIGHT"

Post by toddward »

JessKaufman wrote:I love NameWiz and dont' know how I would live without it. It has been well thought out and includes so many possibilities, i can almost always use it to solve my renaming issues. Now and then i find myself wishing it supported something it does not.

For example, right now I have a large quantity of music directories with the names of albums and the year they were released. I have been able to strip out and format the names the way i want, but the four digit year (such as "1984) is at the END of the directory name. I would love to be able to MOVE the year to the beginning of the file name so the directories can be sorted in chronological order. However, the MOVE command does not have a "POSITION FROM RIGHT" check box, as the INSERT command does. If it did, i could MOVE four characters using position 1 (with POSITION FROM RIGHT box checked) and a character count of 4 to position 1. Each directory name is of different length, so i do not see any way to move the year from the end of each name to the beginning, other than doing it manually (not feasible for hundreds of names).

Am i missing something, or is NameWiz missing something??


I also love NameWiz. I was wondering if we have that extra checkbox now ? It is really very useful for well-organized people ;) I also search if I missed something but then saw your post and was relieved.
Post Reply