Feature Request, Filename Pre-Processing
Feature Request, Filename Pre-Processing
Hi,
Another minor one, but before trying to match, it would be handy to be able to "clean" (pre-process) the file name. Some of my auto-downloaded files show up as (generic) "12345678_Show_Name.mp4". The match would be much better (more successful) if "12345678_" were removed first.
Thanks!
Another minor one, but before trying to match, it would be handy to be able to "clean" (pre-process) the file name. Some of my auto-downloaded files show up as (generic) "12345678_Show_Name.mp4". The match would be much better (more successful) if "12345678_" were removed first.
Thanks!
Re: Feature Request, Filename Pre-Processing

Please read How to Request Help for details:
rednoah wrote: ↑31 Jul 2014, 16:40
- Include file paths as text when reporting mismatches (press F7 to copy debug information)

Re: Feature Request, Filename Pre-Processing
Thanks! I did try to find how to post the filename, even tried a few options ... LOL. But I missed the desired format, sorry.
No ability to pre-process in filebot itself, strip the leading number?
Thanks again.
No ability to pre-process in filebot itself, strip the leading number?
Thanks again.
Re: Feature Request, Filename Pre-Processing


If you click on the file paths as text link then you will find step by step instructions:rednoah wrote: ↑27 Dec 2022, 03:44Please post file paths as text so that we can see what you are seeing.
- Press F7 (in FileBot)
- Press CTRL+V (in the text editor when making a new post)


e.g. use Plain File Mode to strip leading numbers from file names:rednoah wrote: ↑27 Dec 2022, 03:44You can use Plain File Mode to process generic files, or pre-process files to strip misleading patterns.
Code: Select all
$ filebot -rename *.mp4 --db file --format "{ fn.after(/^\d+_/) }" --action TEST --log INFO
[TEST] from [12345678_Alias.1x01.mp4] to [Alias.1x01.mp4]
Re: Feature Request, Filename Pre-Processing
OK, I get your point now
. Sorry, I was thinking in the GUI, not command line. What you say for the command line is clear, but no similar functionality / approach for the GUI? Or are you saying to use a similar syntax for the GUI renaming?
Thanks!

Thanks!
Re: Feature Request, Filename Pre-Processing
Plain File Mode explains how Plain File Mode works in the GUI with multiple examples and screenshots:
Did you read the instructions? If I give you a link to the answer to your question, then you'll want to click on that link and read. Because presumably you'll want to know the answer to the question you have asked, no?
Are the instructions not clear? What exactly is not clear?
You can copy and paste the Plain File Format for "strip leading numbers" from the example above:

rednoah wrote: ↑13 Oct 2014, 21:47 As a hidden bonus feature, FileBot supports quick and efficient generic batch renaming, and you can rewrite the filenames with awesome Groovy expressions just like in Episode / Movie mode.
1. Drop files into Original Files
2. Click on the empty New Names component
3. Now that New Names has focus press F2 (for Plain File Mode) or F3 (for Local Xattr Mode)
4. New Names will instantly filled with File objects (in Plain File Mode) or Movie / Episode objects (in Local Xattr Mode)
5. Double Click any item in New Names to apply a new Format Expression
Create Presets for repetitive tasks.
Hit F2 after selecting an item to edit the name.
Hit F3 after selecting an item to select a different metadata object.
--db file and --db xattr can be used for Plain File Mode and Local Xattr Mode on the command-line.






Code: Select all
{ fn.after(/^\d+_/) }

Re: Feature Request, Filename Pre-Processing
OK, that makes sense - thanks! So use File Format to "clean up" the name, then from there process the files (i.e. Episode, Movie, etc.). Correct?
I admit, searching for a list of the keyboard shortcuts ... F7, F2 ... LOL. I'll find it though.
Thanks again.
I admit, searching for a list of the keyboard shortcuts ... F7, F2 ... LOL. I'll find it though.
Thanks again.
Re: Feature Request, Filename Pre-Processing
Yep, and found it (keyboard shortcuts)
. Let me give the steps above a try.
Thanks!

Thanks!
Re: Feature Request, Filename Pre-Processing
Re: Feature Request, Filename Pre-Processing
To close the loop - got it all working here. Some of above was me misunderstanding of course. Thanks!!