![]()
|
Using Regular Expressions A Better Finder Rename allows you to use an advanced technique called "Regular Expression Substitution" to replace text segments. This is an advanced technique which requires a certain familiarity with programming concepts and may thus prove inappropriate for novice computer users. The feature is available via the "Replace using Regular Expression" action. A regular expression defines a text (i.e. character string) pattern and assigns a variable to each component of the pattern. The basic rules for patterns are:
Examples:
You use "expression groups" to determine which parts of the text will be grouped together and put into a variable. You achieve this grouping by placing braces around the expression group:
As mentioned before the different pattern groups will be placed into substitution variables. These variables are denoted by \1, \2, \3, \4, etc.. \0 is a special variable that holds the entire matched pattern. The substitution expression is made up from simple text characters and variables. For instance:
will yield the following name transformations:
The [ and ] characters can enclose character lists:
The regular expression support of A Better Finder Select for Mac OS X (Version 7.9 and later) is based on the RegexKit framework, which itself is based on the Perl-Compatible Regular Expressions (PCRE) project. Substitution is limited to replacing the standard substitution variables \0, \1, \2, \3, \4, \5, \6. In essence, PCRE supports the standard regular expression syntax used by the PERL scripting language. There are number of good tutorials and books out there:
You can get a complete and very detailed specification of what PRCE supports on the prcepattern man page. For those who want to master this technique in earnest, we recommend the following two books: ![]() ![]() |
Download the combined A Better Finder Rename/ A Better Finder Attributes disk image or older versions for existing users. A Better Finder Rename costs only $19.95 on its own, and $34.95 bundled with A Better Finder Attributes and the Big Mean Folder Machine. Version 8 is a free upgrade for customers who purchased after the 1st of January 2007 or own a forever upgrade. User Manual
Reviews "Arguably the best file renaming utility on the market" Mac OS X Power Tools " About this Particular Macintosh "A utility that is as discreet as it is effective." Recommended by MacDigit.Com 10th March 2010 Version 8.54 allows droplets to be locked before being distributed to end users. Our Better File Rename for Windows product offers similar functionality for Windows users. Pro Tutorials
This is the first place you should look for solutions to common problems, including how to un-install. File collections beware.. the Big Mean Folder Machine is coming for you.. Questions? Suggestions? Visit our support forums or drop us a mail at support@publicspace.net Get this or any other tool on this site for free by linking from your website or blog! |