POSTBUCKET - where random posts in unrelated topics go
Re: [SNIPPET] Sort into A-Z folders
Is there a way to sort on names minus "The"?
IE Sorted or filed or renamed as "Big Lebowski, The" as opposed to "The Big..."
Lots of "The" movies in my collection I would rather sort differently...
IE Sorted or filed or renamed as "Big Lebowski, The" as opposed to "The Big..."
Lots of "The" movies in my collection I would rather sort differently...
Re: [User Study] Take a screen recording and earn yourself a free license
It cant find the right name for Harry Potter movie (8 movies). See pic:
http://www.bilddump.se/bilder/202112301 ... 18.160.png
I have try both Ubuntu and Windows with same result.
http://www.bilddump.se/bilder/202112301 ... 18.160.png
I have try both Ubuntu and Windows with same result.
Re: [User Study] Take a screen recording and earn yourself a free license
Please include file paths as text when reporting mismatches (press F7 to copy debug information)
EDIT:
Looks weird though. My first guess would be some misleading IMDB ID in the *.nfo file that forces the same movie by ID for all files in the same folder.
What's the text content of the nfo file?
EDIT:
Looks weird though. My first guess would be some misleading IMDB ID in the *.nfo file that forces the same movie by ID for all files in the same folder.
What's the text content of the nfo file?
Re: [POC] Custom Format Server
Could this be reworked so that FileBot receives a file name plus information about the type of file and it returns a filename and location?
E.g.
and it'd return file destination?
E.g.
Code: Select all
curl "somethingsomething/post" --data-urlencode "file=${file}" --data-urlencode dir="$(basename ${file})" --data-urlencode output=/Media --data-urlencode label=tv_shows --data @<(mediainfo --full --output=xml "${file}")
I only work in black and sometimes very, very dark grey. (Batman)
Re: [POC] Custom Format Server
That is what the code above does:
Code: Select all
{ json('http://localhost:8080/'.toURL(f:f, time:System.currentTimeMillis())) }
* pass back the String value returned by the HTTP request to be used as destination path (server response is JSON in this specific example; but you can modify the code to assume a plain text response)
Re: [POC] Custom Format Server
Oh, didn't realize.
But it doesn't seem like FileBot is involved in the remote processing.
This line: const dst = src.toUpperCase().replace(/[^A-Z0-9]/g, '_') is the only piece of code involved in the renaming, right?
I was wondering if it could be made so that FileBot processes the information on the server end (like using an uploaded mediainfo file instead of analyzing the file on disk directly).
But it doesn't seem like FileBot is involved in the remote processing.
This line: const dst = src.toUpperCase().replace(/[^A-Z0-9]/g, '_') is the only piece of code involved in the renaming, right?
I was wondering if it could be made so that FileBot processes the information on the server end (like using an uploaded mediainfo file instead of analyzing the file on disk directly).
I only work in black and sometimes very, very dark grey. (Batman)
Re: [POC] Custom Format Server
The server-side code above is just a simple example. This particular example upper-cases one of the GET parameters it was sent as input and sends back the result as output. Your server-side code could do anything though, and your client-side can send arbitrary information, file path, media info, current time, etc.
Re: [POC] Custom Format Server
To expand a bit on this idea, is there a function or an option to use as source file, instead of a media file present on disk, a MediaInfo xml report?
The idea would be to host a FileBot service on a remote server, upload the MediaInfo report file named as the source file and have FileBot return the correct name.
This would not use the move/copy/keeplink functions of FileBot, the xattr bits (although they could be potentially returned in the response or processed from the source), and it would probably require a separate version of amc.groovy which doesn't check folders or file existence.
The idea would be to host a FileBot service on a remote server, upload the MediaInfo report file named as the source file and have FileBot return the correct name.
This would not use the move/copy/keeplink functions of FileBot, the xattr bits (although they could be potentially returned in the response or processed from the source), and it would probably require a separate version of amc.groovy which doesn't check folders or file existence.
I only work in black and sometimes very, very dark grey. (Batman)
Re: Q&A for n00bs
Hi, RedNoah, and thanks for any/all help you can offer here.
The goal is for TV shows to end up in N:\media\tv and movies to end up in n:\media\moviestowatch. Currently, the first line is working fine but, the infrequent time that I've got a movie to be processed, it works sometimes and, when it doesn't, it deletes the file completely. I'd prefer that movies not get their own subfolder but, if they must, that's not the end of the world.
When qbittorrent finishes, it dumps all files into n:\media\videos for processing.
Secondly, I've added the subtitle clause so let me know if I'm doing that wrong. I'd like the movies to always have a subtitle available.
It's in a batch file that does things like delete .nfo/.txt and other housekeeping things.
If this can be done with a single line to cover both types of media, I'd love to learn.
The goal is for TV shows to end up in N:\media\tv and movies to end up in n:\media\moviestowatch. Currently, the first line is working fine but, the infrequent time that I've got a movie to be processed, it works sometimes and, when it doesn't, it deletes the file completely. I'd prefer that movies not get their own subfolder but, if they must, that's not the end of the world.
When qbittorrent finishes, it dumps all files into n:\media\videos for processing.
Secondly, I've added the subtitle clause so let me know if I'm doing that wrong. I'd like the movies to always have a subtitle available.
It's in a batch file that does things like delete .nfo/.txt and other housekeeping things.
Code: Select all
"c:\Program Files\FileBot\filebot.exe" -script fn:amc --output "n:/media/tv" --action move -non-strict "n:/media/videos" --log-file amc.log --def excludeList=amc.txt --def seriesFormat="{n}/{n} - {s00e00} - {t}" clean=y kodi=kodi:[email protected]:8081
"c:\Program Files\FileBot\filebot.exe" -script fn:amc --output "n:/media/moviestowatch" --action move -non-strict "n:/media/videos" --log-file amc.log --def excludeList=amc.txt --def subtitles=en --def seriesFormat="{n} ({y}) - {rating}" clean=y kodi=kodi:[email protected]:8081
Last edited by Xander on 09 Apr 2022, 23:08, edited 1 time in total.
Re: Q&A for n00bs
Your structure and customizations seem to make things unnecessarily difficult for yourself. I'd just keep things simple.
e.g. recommended usage:
* Clearly separate input / output folders, i.e. input folder must not be inside the output folder.
* Stick to the standard {plex} format, i.e. no custom folder names, no custom formats. The {plex} format is responsible for the "TV Shows" and "Movies" folders. If you choose to use custom formats then your custom format is responsible for generating the parent folder structure within the --output folder if desired.
What have you tried so far? Where are you stuck? What did the console output say?
Please read the amc script manual for details.
You'll want to use the suball script on demand for fine-grained control over which files get subtitles. The amc script is a one-size-fits-all solution and thus not suitable if you want subtitles for some files but not others.
If you aim to organize the same files into multiple folder structures for easy access, then you'll want to have one well-organized primary structure, from which you can then auto-generate arbitrary secondary structures on demand. Please read Re-organize previously organized files using local xattr metadata for details.
e.g. recommended usage:
Code: Select all
filebot -script fn:amc --output "N:/Plex" --action duplicate -non-strict "n:/media/videos" --log-file amc.log --def excludeList=amc.txt
* Stick to the standard {plex} format, i.e. no custom folder names, no custom formats. The {plex} format is responsible for the "TV Shows" and "Movies" folders. If you choose to use custom formats then your custom format is responsible for generating the parent folder structure within the --output folder if desired.
This is the default behaviour. If all your files are mixed, then a single amc script call is your only option. You can have separate filebot -rename calls (i.e. not amc script calls) for separately processing movie files and episode files, but for that to make sense your files would have to be separated into folders already, one input folder that only contains movies and one input folder that only contains episodes.




Re: [User Study] Take a screen recording and earn yourself a free license
Hi rednoah
Is this free license promotion still available if I sent you a recording? I could try it on my QNAP Nas.
Looking for a reply. Thanks in advance.
Is this free license promotion still available if I sent you a recording? I could try it on my QNAP Nas.
Looking for a reply. Thanks in advance.
-
- Posts: 107
- Joined: 12 Apr 2020, 04:02
Re: How about sharing our format expressions?
Just windows explorer, i created a movie library and added different paths that correspond to the categories i want
https://cdn.discordapp.com/attachments/ ... nknown.png
Re: Q&A for n00bs
This thread may been three years old, but I would feel bad asking such a dumb question in it's own thread: my brain may be broked, but qBittorrent doesn't seem to want to run anything. And for the record, "TV_Shows" is merely the alias to my TV Shows drive; Movies_Other is where movies are kept.
This works fine and dandy in the Linux Terminal, but not out of qBittorrent.
Thinking I might be misremembering something, I took the AMC script with the output edited, and nothing happened either. The files didn't go anywhere, they weren't copied or anything, and no amc.excludes file. I've checked permissions, I've reinstalled different distros, and installed filebot from different repos, but nothin'.
And despite running this, I cannot find the log file
wat do
This works fine and dandy in the Linux Terminal, but not out of qBittorrent.
Code: Select all
filebot -script fn:amc --output /mnt/TV_Shows --action duplicate -non-strict /home/alittler/Downloads --def movieFormat=/mnt/Movies_Other/{plex} seriesFormat=/mnt/TV_Shows/{plex} --def plex=192.168.1.123:duhhhhhhhhh --def clean=y --def unsorted=y --log-file amc.log --def excludeList=amc.txt
Code: Select all
filebot -script fn:amc --output "/mnt/TV_Shows" --action duplicate --conflict skip -non-strict --log-file amc.log --def excludeList=amc.excludes --def unsorted=y music=y artwork=y "ut_label=%L" "ut_title=%N" "ut_kind=multi" "ut_dir=%F"
Code: Select all
find /usr/local/filebot-node/ -name "*.log"
Re: Q&A for n00bs


viewtopic.php?t=3067

Re: Q&A for n00bs
Well, the printenv command works when I add it to my Terminal script, but not when I paste it into qBT. Which I expected, but also blows chunks. I've installed Filebot dozens of times in my attempts organize my completely legal downloading, in uBT, qBT, and my old Synology NAS, and this has never been a problem.
Despite my best attempts, a crontab just don't work as well as running a script on command.
Despite my best attempts, a crontab just don't work as well as running a script on command.
Re: Q&A for n00bs
If you can't run a simple custom shell script unrelated to filebot, then you will not be able to run filebot. Re-installing FileBot has no effect because qBT for some reason seems to just not execute your post-process command.
I recommend checking with qBT users in the qBT forums first and see if they can help you debug qBT and see if you can manage to successfully call a simple custom script. Once you've got that confirmed to be working reliably, then we can move on to calling filebot.
EDIT:

EDIT:
You seem to be doing something wrong here, because I'd expect you to copy the path to a custom script into qBT, i.e. just a file path:
rednoah wrote: ↑09 Oct 2015, 16:48 Step-by-Step Instructions for Beginners:
- Download the debug.sh script:
Code: Select all
curl -O "https://raw.githubusercontent.com/filebot/plugins/master/bash/debug.sh"
- Read the debug.sh script and try to understand what it does line by line:
Code: Select all
cat debug.sh
- Make the debug.sh script executable for all users:
Code: Select all
chmod +rx debug.sh
- Enter the absolute path to your /path/to/debug.sh script to execute it:
Code: Select all
/path/to/debug.sh
- Read the console output for each test command (e.g. printenv > /tmp/printenv.txt) and confirm that each test command is working:
Code: Select all
tail /tmp/*.txt
- Copy the absolute path to your /path/to/debug.sh script into qBT / Deluge / Transmission / etc and wait for it to be called. Then check the /tmp/*.txt text files to see the console output (i.e. error messages) was for each test command.
Re: Q&A for n00bs
Well, it eventually got to work. The issue seems to have been permissions, and using the idea of your debug.sh file, I put my preferred filebot script into a torrent.sh file and made it executable for all users.
I also downloaded about latest Young Sheldon episode about 15,000 times because it was relatively small and had a great amount of seeds.
Thank you kindly, sir.
I also downloaded about latest Young Sheldon episode about 15,000 times because it was relatively small and had a great amount of seeds.
Thank you kindly, sir.
Re: [DOCS] The movie {tags} and movie {edition} bindings
For Plex/Multiple Editions tag... "[" and "]" will not be accepted yet they are built into your tags format. Text in square brackets are ignored.
Plex gives this as the proper format:
How to search for "DC" in a filename, coming after a four digit year, and transform that into "Directors Cut" for editions while using plex.id.derive?
Plex gives this as the proper format:
I have to use this to make it work with Plex/Media
/Movies
Blade Runner (1982) {edition-Director's Cut}.mp4
Blade Runner (1982) {edition-Final Cut}.mp4
Code: Select all
{edition-'+tags.toString().replace('[','').replace(']','')+'}'

Code: Select all
{plex.id.derive{' {edition-'+tags.toString().replace('[','').replace(']','')+'}' }
Re: [SNIPPET] Sort into A-Z folders
How would I sort TV shows, by their first letters, into separate drives? Something like this;
Ah tell you hwat...
Code: Select all
{
if ({az} = A..L) {
return "/media/alittler/'TV Shows'/{plex}"
} else {
return "/media/alittler/'TV Shows2'/{plex}"
}
}
Re: [SNIPPET] Sort into A-Z folders
After a few hours of try and try and try again, I think I got it. I just had to search the Forums the same questions in a few different waysalittler wrote: ↑18 Mar 2023, 13:17 How would I sort TV shows, by their first letters, into separate drives? Something like this;
Ah tell you hwat...Code: Select all
{ if ({az} = A..L) { return "/media/alittler/'TV Shows'/{plex}" } else { return "/media/alittler/'TV Shows2'/{plex}" } }
Code: Select all
Movies_Other/" --action duplicate -non-strict --log-file amc.log --def movieFormat="/media/alittler/Movies_Other/{ plex }" seriesFormat="{n =~ /^(?i)[0-9a-r]/ ? '/media/alittler/TV_Shows_1' : n =~ /^(?i)[s-z]/ ? '/media/alittler/TV_Shows_2'}:/{plex}
" excludeList="/media/alittler/Movies_Other/amc.txt
Re: [SNIPPET] Sort into A-Z folders
e.g.
Code: Select all
{
if (az in 'A'..'L')
return '/path/to/A-L'
if (az in 'M'..'Z')
return '/path/to/M-Z'
return '/path/to/#'
}
/
{plex}
Re: [SNIPPET] Sort into A-Z folders
Thank you kindly. Either I misread the Terminal or something (or it was very, very late) but the command I had just tried didn't quite work, and this is a much simpler version of it.rednoah wrote: ↑19 Mar 2023, 11:12 e.g.Code: Select all
{ if (az in 'A'..'L') return '/path/to/A-L' if (az in 'M'..'Z') return '/path/to/M-Z' return '/path/to/#' } / {plex}