Page 1 of 2
My RegExp no longer works in 0140
Posted: 16 Aug 2006 17:35
by John Bee
Hi;
I need help with the new way you are doing the RegExp Rename.
Up until 0140 I was doing it this way:
using
.*(.msi|.exe|.zip|.rar|.pdf|.7z)>XYplorer 5.00.0140 beta.zip
would change
Xyplorer_5.00_beta.zip.dsc.txt
Xyplorer_5.00_beta.zip
to
XYplorer 5.00.0140 beta.zip.dsc.txt
XYplorer 5.00.0140 beta.zip
but now in 0140 I get:
XYplorer 5.00.0140 beta.zip.dsc.txt
Xyplorer_5.00_beta.zip
Only the .txt file seems to match.
This is possibly to do with?:
* Rename Special: from now on, the following commands will *never*
change the extensions of the renamed files.
- Batch Rename...
- RegExp Rename...
- Search and Replace...
- Keep Particular Characters...
So how do I change my RegExp to compensate?
John
Win2K
0139
1,406ms/453ms
Re: My RegExp no longer works in 0140
Posted: 16 Aug 2006 22:23
by admin
Yeah, you feel the recent changes here: extensions simply don't take part anymore in the functions I mentioned. Simply because it is highly unlikely that one would change base and extension of one or more names at the same time. It is rare enough to extensions at all...
If I get your RegExp right, you want to replace "Xyplorer_5.00_beta" with "XYplorer 5.00.0140 beta". Why not simply do "Search and Replace"?
Pattern: Xyplorer_5.00_beta/XYplorer 5.00.0140 beta
Re: My RegExp no longer works in 0140
Posted: 16 Aug 2006 22:47
by John Bee
admin wrote:Yeah, you feel the recent changes here: extensions simply don't take part anymore in the functions I mentioned. Simply because it is highly unlikely that one would change base and extension of one or more names at the same time. It is rare enough to extensions at all...
If I get your RegExp right, you want to replace "Xyplorer_5.00_beta" with "XYplorer 5.00.0140 beta". Why not simply do "Search and Replace"?
Pattern: Xyplorer_5.00_beta/XYplorer 5.00.0140 beta
Hi Don;
Well, because that regexp handles all renames no matter what the actual original filename. I only have to type in the replacement and not the original filename.
John
Win2K
0139
Re: My RegExp no longer works in 0140
Posted: 16 Aug 2006 22:49
by John Bee
admin wrote:Yeah, you feel the recent changes here: extensions simply don't take part anymore in the functions I mentioned. Simply because it is highly unlikely that one would change base and extension of one or more names at the same time. It is rare enough to extensions at all...
If I get your RegExp right, you want to replace "Xyplorer_5.00_beta" with "XYplorer 5.00.0140 beta". Why not simply do "Search and Replace"?
Pattern: Xyplorer_5.00_beta/XYplorer 5.00.0140 beta
Hi Don;
Well, because that regexp handles all renames no matter what the actual original filename and its a quick copy and paste for the replacement and I don't have to type in the original filename.
John
Win2K
0139
Re: My RegExp no longer works in 0140
Posted: 16 Aug 2006 22:54
by admin
John Bee wrote: Well, because that regexp handles all renames no matter what the actual original filename and its a quick copy and paste for the replacement and I don't have to type in the original filename.
Ah, I see. Then you have to alter your RegExp to handle the new rules. I'm sure it's easy when you know how to do it.

Re: My RegExp no longer works in 0140
Posted: 17 Aug 2006 00:36
by John Bee
admin wrote:John Bee wrote: Well, because that regexp handles all renames no matter what the actual original filename and its a quick copy and paste for the replacement and I don't have to type in the original filename.
Ah, I see. Then you have to alter your RegExp to handle the new rules. I'm sure it's easy when you know how to do it.

Hi Don
Ha, ha, without the ext in the picture you've made it virtually impossible to use regexp renames with multiple filenames that are not the same.
I need the ext to use regexp properly.
John
Win2K
0139
Posted: 17 Aug 2006 04:38
by jacky
Yeah, not a regexp expert but I'm pretty sure it can't be done anymore, as the extension was used inside the regexp to determine what part of the filename will be renamed (thus leaving the ext out just makes this impossible now)
I also would love to have RegExp rename working back with the full filename, aka base+ext. Because like here in John's case it could have been part of the regexp, and could also allow to have regexp working on the extension!
I really think it's be better, as now you're limitating the power of use of regexp more than making things easier, I think....
BTW, I actually feel the same about Batch Rename too. Plus it was cool to have it either to reset the extension, or keep the original extensions, or remove them even! Now all that is gone

We can only have them ujntouched, so again, I feel like we're loosing here

(and even with the extension, the new template "2006-*-(backup)" would still work, just say * is base only, or better more!, like ? for base only, * for for both, : for ext only)
..oh I understand system had "flaws", because a dot can be part of the filename and not an extension (eg filename "first part.second part.ext") so for such files it was impossible to leave the extension untouched, since ".second part" would be considered as the extension, so we had to reset the extension... but with your new template addition this (leaving extension untouched) could now be possible using whatever if used for extension only

Re: My RegExp no longer works in 0140
Posted: 17 Aug 2006 07:01
by admin
John Bee wrote:Ha, ha, without the ext in the picture you've made it virtually impossible to use regexp renames with multiple filenames that are not the same.
Hm. Which files do you what to rename to what?
Posted: 17 Aug 2006 07:48
by admin
jacky wrote:I really think it's be better, as now you're limitating the power of use of regexp more than making things easier, I think....
Ok, I'm no regexp man, and when enough users (two

) tell me, they'd rather have the extension in the picture here, no problem. I won't use it anyway myself
jacky wrote:BTW, I actually feel the same about Batch Rename too. Plus it was cool to have it either to reset the extension, or keep the original extensions, or remove them even! Now all that is gone

...
Hm, to reset the extension simply use "Set Extension".
My goal was to make things (a) easier, and (b) safer (changing the extension can mean losing important information when you're not a file format guru).
Posted: 17 Aug 2006 14:17
by RalphM
admin wrote:Ok, I'm no regexp man, and when enough users (two

) tell me, they'd rather have the extension in the picture here, no problem. I won't use it anyway myself

I didn't check it out myself yet, but if it's true, that by this addition the ext isn't even availabe for the regexp to evaluate the need for certain actions on certain ext's only, then I'm definitely voting to get it back the way it was.
Posted: 17 Aug 2006 17:04
by jacky
admin wrote:Hm, to reset the extension simply use "Set Extension".
My goal was to make things (a) easier, and (b) safer (changing the extension can mean losing important information when you're not a file format guru).
[Set Extension] Yeah I know, just it's one more step than it used to be

And renaming extension on batch rename can be usefull, for example when working on pictures, to make sure they're all ".jpg" not ".jpeg" or ".JPG"/".Jpg" etc which isn't only a visual thing (even if it counts, for some

) but also quite important when you intend to send & use thoose files on a *nix environement (eg web server).
And I understand your motivation, just that i though the way it was was more powerfull and yet quite easy, you know the good old XY way to go

I can see how having the ext left out can be seen as easier/safer; but regarding the safer side.. well XY targets power user, ie they're supposed to know what they're doing, I mean don't click on Nuke just for fun guys!

As for easier, if adding something like
.: (in the idea that : means original extension) get the same results, doesn't sound too complicated to me, and allows one to batch rename with or without changing the extension... but hey, it's your call uh?
BTW:
Code: Select all
+ Rename Special/Batch Rename: added shortcut Shift+F2. Useful to
invoke the Batch Rename interface if only one (or no) list item is
selected
so I got a question: what the hell is XY gonna do when I do a Batch Rename while no items are selected at all?? What's gonna be renamed?? I don't get it

Posted: 17 Aug 2006 17:32
by admin
jacky wrote: what the hell is XY gonna do when I do a Batch Rename while no items are selected at all?? What's gonna be renamed?? I don't get it

Last time I checked it would rename the focused item.

Posted: 17 Aug 2006 17:40
by jacky
admin wrote:jacky wrote: what the hell is XY gonna do when I do a Batch Rename while no items are selected at all?? What's gonna be renamed?? I don't get it

Last time I checked it would rename the focused item.

hmmm.. well, tried again with .143 and nothing happens

Posted: 17 Aug 2006 17:44
by admin
jacky wrote:admin wrote:jacky wrote: what the hell is XY gonna do when I do a Batch Rename while no items are selected at all?? What's gonna be renamed?? I don't get it

Last time I checked it would rename the focused item.

hmmm.. well, tried again with .143 and nothing happens

List focused? (I cannot check where I am right now)
PS: use Shift+F2!
Posted: 17 Aug 2006 17:51
by jacky
admin wrote:List focused? (I cannot check where I am right now)
PS: use Shift+F2!
Yes, Shift+F2 (how else could I trigger Batch Rename without any selected items anyway?) and List focused. F2 selected the focused item and switch in Rename mode, but Shitf+F2 shows the BR window, then nothing.