Difference between revisions of "ReNamer:Rules:Remove"

From den4b Wiki
Jump to navigation Jump to search
(removed old help index)
(Clarified the "skip extension" option)
 
(16 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{ReNamer Help}}
+
{{Go|up=ReNamer:Rules|prev=ReNamer:Rules:Delete|next=ReNamer:Rules:Replace}}
  
== Remove Rule ==
+
== Remove Rule ==
[[Image:RemoveRule.png]]
 
  
This rule removes the specified string from the file name. It has options to remove the first occurrence, the last occurrence, or all the occurrences of the specified string. You can enter multiple strings at a time (just separate them with "'''|'''"). If ReNamer finds any of them in the name, they will be removed. You can create a pattern with wildcards, so that any string that matches the pattern will be removed.
+
[[Image:RemoveRule.png|center]]
  
The parameters are as follows:
+
This rule removes the specified string from the file name. It has options to remove the first occurrence, the last occurrence, or all the occurrences of the specified string. You can enter multiple strings at a time (just separate them with '''*|*'''). If ReNamer finds any of them in the name, they will be removed. You can create a pattern with wildcards, so that any string that matches the pattern will be removed.
  
{| class="prettytable"
+
The parameters are as follows:
! Parameter
+
 
 +
{| class="wikitable"
 +
|-
 +
! Parameter  
 
! Details
 
! Details
 
 
|-
 
|-
| Remove
+
| Remove  
| Enter the string to be removed.
+
| Enter the string to be removed.
 +
*You can enter multiple strings at a time. Press the + button to separate two strings
 +
*If the name does not contain the specified string, the rule will not act on it.
 +
*If the name contains more than one of these strings, it will remove all of them.
  
* You can enter multiple strings at a time. Press the + button to separate two strings
+
'''TIP:''' Sometimes, the file names have a common string that needs to be removed. In such cases, rather than entering the whole string by hand, it is easier to borrow it from one of the file names. To do this, just click on a file name in the '''Files''' pane of ReNamer ''BEFORE'' launching the '''Remove''' rule. ReNamer will automatically copy the entire name of the selected file into the Remove field. Now edit this entry to get the desired common string.  
* If the name does not contain the specified string, the rule will not act on it.
 
* If the name contains more than one of these strings, it will remove all of them.  
 
  
 
|-
 
|-
| [[Image:PlusButton.png]] button
+
| [[Image:PlusButton.png]] button  
| Press to insert a separator between strings. You can also type a vertical bar ('''<nowiki>|</nowiki>''') from the keyboard.
+
| Inserts a separator ('''*{{Pipe}}*''') sequence between two delimiter entries. (You can directly type *{{Pipe}}* instead of clicking on this button.)
 
 
 
|-
 
|-
| Occurrences
+
| Occurrences  
| In case the strings occure multiple times in the name, specify which occurrences should be removed. (Options are: ''first only'', ''last only'', or ''all'')
+
| In case the strings occur multiple times in the name, specify which occurrences should be removed. (Options are: ''first only'', ''last only'', or ''all'')
 
 
 
|-
 
|-
| Skip extension
+
| Skip extension  
| If this check box is selected, the rule won't touch the extention.
+
| If checked, the file extension will be excluded from the processing and will remain unaffected.
 
 
 
|-
 
|-
| Case sensitive
+
| Case sensitive  
 
| Will only remove a specified string from the name if the case matches exactly.
 
| Will only remove a specified string from the name if the case matches exactly.
 +
|-
 +
| Whole words only
 +
| Remove the subject text only when it is whole word, not a part of another word.
  
 +
For example, searching for "bar" would not find a match in "foobar" or "bars".
 
|-
 
|-
| Interpret symbols as wildcards
+
| Interpret symbols as wildcards  
| The following wildcards are allowed (compare with RegEx).
+
| Treat certain symbols as [[#Wildcards|Wildcards]] for matching simple patterns (similar to [[ReNamer:Regular Expressions|Regular Expressions]]).  
 +
 
 +
|}
 +
 
 +
=== Wildcards ===
  
{| class="prettytable"
+
{| class="wikitable"
!
+
|-
! Represents
+
! Wildcard
 +
! Represents  
 
! Example
 
! Example
 
 
|-
 
|-
| <center><nowiki>*</nowiki></center>
+
| <center><nowiki>*</nowiki></center>  
| any number of characters (including numbers, space, underscores, etc.).
+
| any number of characters (including numbers, space, underscores, etc.).  
 
| '''abc*''' equals '''abc''' followed by 0 or more characters.
 
| '''abc*''' equals '''abc''' followed by 0 or more characters.
 
 
|-
 
|-
| <center>?</center>
+
| <center>?</center>  
| Any single character (including numbers, space, underscores, etc.)
+
| Any single character (including numbers, space, underscores, etc.)  
 
| '''ab?d''' equals '''abcd''', '''ab1d''', '''ab d''', '''ab_d''', etc.
 
| '''ab?d''' equals '''abcd''', '''ab1d''', '''ab d''', '''ab_d''', etc.
 
 
|-
 
|-
| <center><nowiki>[]</nowiki></center>
+
| <center><nowiki>[]</nowiki></center>  
| Brackets enclose a set of characters, any one of which may match a single character at that position.
+
| Brackets enclose a set of characters, any one of which may match a single character at that position.  
 
| '''<nowiki>foo[ab]ar </nowiki>'''equals '''fooaar''' and '''foobar'''
 
| '''<nowiki>foo[ab]ar </nowiki>'''equals '''fooaar''' and '''foobar'''
 
 
|-
 
|-
| <center>-</center>
+
| <center>-</center>  
| (only within a pair of brackets) denotes a range of characters.
+
| (only within a pair of brackets) denotes a range of characters.  
 
| '''<nowiki>foo[a-z]ar </nowiki>'''equals '''fooaar''', '''foobar,''' '''foocar,''' '''foodar,''' etc.
 
| '''<nowiki>foo[a-z]ar </nowiki>'''equals '''fooaar''', '''foobar,''' '''foocar,''' '''foodar,''' etc.
 +
|}
  
|}
+
[[Category:ReNamer]]
|}
 

Latest revision as of 01:28, 1 April 2022

Remove Rule

RemoveRule.png

This rule removes the specified string from the file name. It has options to remove the first occurrence, the last occurrence, or all the occurrences of the specified string. You can enter multiple strings at a time (just separate them with *|*). If ReNamer finds any of them in the name, they will be removed. You can create a pattern with wildcards, so that any string that matches the pattern will be removed.

The parameters are as follows:

Parameter Details
Remove Enter the string to be removed.
  • You can enter multiple strings at a time. Press the + button to separate two strings
  • If the name does not contain the specified string, the rule will not act on it.
  • If the name contains more than one of these strings, it will remove all of them.

TIP: Sometimes, the file names have a common string that needs to be removed. In such cases, rather than entering the whole string by hand, it is easier to borrow it from one of the file names. To do this, just click on a file name in the Files pane of ReNamer BEFORE launching the Remove rule. ReNamer will automatically copy the entire name of the selected file into the Remove field. Now edit this entry to get the desired common string.

PlusButton.png button Inserts a separator (*|*) sequence between two delimiter entries. (You can directly type *|* instead of clicking on this button.)
Occurrences In case the strings occur multiple times in the name, specify which occurrences should be removed. (Options are: first only, last only, or all)
Skip extension If checked, the file extension will be excluded from the processing and will remain unaffected.
Case sensitive Will only remove a specified string from the name if the case matches exactly.
Whole words only Remove the subject text only when it is whole word, not a part of another word.

For example, searching for "bar" would not find a match in "foobar" or "bars".

Interpret symbols as wildcards Treat certain symbols as Wildcards for matching simple patterns (similar to Regular Expressions).

Wildcards

Wildcard Represents Example
*
any number of characters (including numbers, space, underscores, etc.). abc* equals abc followed by 0 or more characters.
?
Any single character (including numbers, space, underscores, etc.) ab?d equals abcd, ab1d, ab d, ab_d, etc.
[]
Brackets enclose a set of characters, any one of which may match a single character at that position. foo[ab]ar equals fooaar and foobar
-
(only within a pair of brackets) denotes a range of characters. foo[a-z]ar equals fooaar, foobar, foocar, foodar, etc.