Difference between --action duplicate and --action copy

Running FileBot from the console, Groovy scripting, shell scripts, etc
Post Reply
hphl
Posts: 1
Joined: 21 Dec 2014, 21:22

Difference between --action duplicate and --action copy

Post by hphl »

Thank you so much for write this awesome tool. I'm trying to understand some of the CLI options. I using http://www.filebot.net/cli.html and this viewtopic.php?f=4&t=215 for the options, but I notice that some option are missing. I noticed that almost everyone use action duplicate. What does that do? How different from copy? Is it just a hardlink? Is it different for different FILE Formate (e.g. MS-DOS (FAT32))?

Also how can I exclude a directory? Do I just add it to --def excludeList=amc-input.txt where amc-input.txt has EXCULDE_FOLDER/ with the slash?
User avatar
rednoah
The Source
Posts: 22999
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Trying to understand some of the CLI options.

Post by rednoah »

--action duplicate is a mixture of hardlink and copy. It will hardlink if possible, and copy if necessary.

All the Unix examples use --action duplicate because Linux/Mac/BSD/etc have excellent support for hardlinks. All the Windows examples use --action copy because Windows has questionable support for hardlinks. FAT32 probably doesn't support hardlinks.

--def excludeList contains a list of exact path names. You're not supposed to edit it yourself.

You're looking for --def ignore=EXCLUDE_PATTERN which allows you to specify an exclude pattern for files to be ignored from processing.
:idea: Please read the FAQ and How to Request Help.
RudyBzh
Posts: 23
Joined: 31 Mar 2013, 14:05

Re: Difference between --action duplicate and --action copy

Post by RudyBzh »

Hi,
That was exactly what i was looking for.... BUT
unfortunately it's not working as described.
Using duplicate is trying, for me, to do a "rename", which is not working because the file is in seed and used by vuze.
How can i "hardlink" if i can and "copy" if not ?
Thanks a lot.
Rudy
User avatar
rednoah
The Source
Posts: 22999
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Difference between --action duplicate and --action copy

Post by rednoah »

"hardlink" if i can and "copy" if not
That's what --action duplicate does.
:idea: Please read the FAQ and How to Request Help.
RudyBzh
Posts: 23
Joined: 31 Mar 2013, 14:05

Re: Difference between --action duplicate and --action copy

Post by RudyBzh »

Hi,

Thanks for your fast answer but it's not the case.

Here are some logs :

Code: Select all

Run script [fn:amc] at [Thu Aug 06 23:16:17 CEST 2015]
Parameter: subtitles = n
Parameter: music = n
Parameter: artwork = n
Parameter: ut_dir = D:\Downloads\Terminé
Parameter: ut_file = TheMovieHere.2015.MULTi.1080p.BluRay.x264-LOST.mkv
Parameter: ut_kind = single
Parameter: ut_title = TheMovieHere.2015.MULTi.1080p.BluRay.x264-LOST.mkv
Parameter: ut_label = ToDel
Parameter: seriesFormat = E:/Séries/{n.replaceAll(/[!?.]+$/).replaceAll(/[`'`'?]/, "'").replaceAll(/[:]/, "-")}/{episode.special ? "Special" : "Saison "+s}/{n.replaceAll(/[!?.]+$/).replaceAll(/[`'`'?]/, "'").replaceAll(/[:]/, "-")} - {episode.special ? "S00E"+special.pad(2) : s00e00} - {t.replaceAll(/[!?.]+$/).replaceAll(/[`'`'?]/, "'").replaceAll(/[:]/, "-").replacePart(', Part $1')}{dim[0] > 1900 ? " [1080p]" : dim[0] > 1200 ? " [720p]":""}
Parameter: animeFormat = D:/Films/{n.replaceAll(/[!?.]+$/).replaceAll(/[`'`'?]/, "'").replaceAll(/[:]/, "-")} ({y})/{n.replaceAll(/[!?.]+$/).replaceAll(/[`'`'?]/, "'").replaceAll(/[:]/, "-")} ({y}){" CD$pi"}{dim[0] > 1900 ? " [1080p]" : dim[0] > 1200 ? " [720p]":""}
Parameter: movieFormat = E:/Films/{n.replaceAll(/[!?.]+$/).replaceAll(/[`'`'?]/, "'").replaceAll(/[:]/, "-")} ({y})/{n.replaceAll(/[!?.]+$/).replaceAll(/[`'`'?]/, "'").replaceAll(/[:]/, "-")} ({y}){" CD$pi"}{dim[0] > 1900 ? " [1080p]" : dim[0] > 1200 ? " [720p]":""}
Input: D:\Downloads\Terminé\TheMovieHere.2015.MULTi.1080p.BluRay.x264-LOST.mkv
TheMovieHere.2015.MULTi.1080p.BluRay.x264-LOST.mkv [series: null, movie: TheMovieHere(2015)]
Group: [tvs:null, mov:TheMovieHere 2015, anime:null] => [TheMovieHere.2015.MULTi.1080p.BluRay.x264-LOST.mkv]
CmdlineException: Illegal language code: n
Rename movies using [TheMovieDB]
Auto-detect movie from context: [D:\Downloads\Terminé\TheMovieHere.2015.MULTi.1080p.BluRay.x264-LOST.mkv]
[DUPLICATE] Rename [D:\Downloads\Terminé\TheMovieHere.2015.MULTi.1080p.BluRay.x264-LOST.mkv] to [E:\Films\TheMovieHere (2015)\TheMovieHere (2015) [1080p].mkv]
Processed 1 files
Done ヾ(@⌒ー⌒@)ノ
And here is the command run Under vuze once download is finished :

Code: Select all

filebot.exe -script fn:amc --action duplicate --conflict override -non-strict --log all --log-file "%D\filebot.log" --lang fr --encoding UTF-8 --def subtitles=n music=n artwork=n "ut_dir=%D" "ut_file=%F" "ut_kind=%K" "ut_title=%N" "ut_label=%L" "seriesFormat=E:/Séries/{n.replaceAll(/[!?.]+$/).replaceAll(/[`'`'?]/, \"'\").replaceAll(/[:]/, \"-\")}/{episode.special ? \"Special\" : \"Saison \"+s}/{n.replaceAll(/[!?.]+$/).replaceAll(/[`'`'?]/, \"'\").replaceAll(/[:]/, \"-\")} - {episode.special ? \"S00E\"+special.pad(2) : s00e00} - {t.replaceAll(/[!?.]+$/).replaceAll(/[`'`'?]/, \"'\").replaceAll(/[:]/, \"-\").replacePart(', Part $1')}{dim[0] > 1900 ? \" [1080p]\" : dim[0] > 1200 ? \" [720p]\":\"\"}" "animeFormat=D:/Films/{n.replaceAll(/[!?.]+$/).replaceAll(/[`'`'?]/, \"'\").replaceAll(/[:]/, \"-\")} ({y})/{n.replaceAll(/[!?.]+$/).replaceAll(/[`'`'?]/, \"'\").replaceAll(/[:]/, \"-\")} ({y}){\" CD$pi\"}{dim[0] > 1900 ? \" [1080p]\" : dim[0] > 1200 ? \" [720p]\":\"\"}" "movieFormat=E:/Films/{n.replaceAll(/[!?.]+$/).replaceAll(/[`'`'?]/, \"'\").replaceAll(/[:]/, \"-\")} ({y})/{n.replaceAll(/[!?.]+$/).replaceAll(/[`'`'?]/, \"'\").replaceAll(/[:]/, \"-\")} ({y}){\" CD$pi\"}{dim[0] > 1900 ? \" [1080p]\" : dim[0] > 1200 ? \" [720p]\":\"\"}"
As you understand, my downloads are under D: and the movies are under D: so, it should be a hardlink here.
Else, should be a copy.
Here, it's trying a rename (with Duplicate action as you will see)

What am I doing wrong ?

Thanks


EDIT

My bad, i've just discovered i made a mistake and put e: for my movies in place of d:
I have to make aditionnal tests before telling it's not doing what it should... (Sorry)
Just the fact we see "rename" and not "copy", is it normal ?
"Rename" is a "move" or a "copy" ?
Thanks for your time.
User avatar
rednoah
The Source
Posts: 22999
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Difference between --action duplicate and --action copy

Post by rednoah »

That log message just happens to say "Rename" and it'll process files with whatever MOVE/COPY/HARDLINK/etc action you have specified. If you specify DUPLICATE then the logs will not tell you if it copied or hardlinked files. If you want to test hardlinks, you should specify HARDLINK.
:idea: Please read the FAQ and How to Request Help.
RudyBzh
Posts: 23
Joined: 31 Mar 2013, 14:05

Re: Difference between --action duplicate and --action copy

Post by RudyBzh »

Ok, i think i understood.
I'll try for a few days and see what happens.
Hardlink was the older way i was using filebot but due to lack of space, i have to split movies and tv shows on different drive. So i can't use anymore hardlink (for my tv shows...)
Thanks a lot !
Post Reply