Folder Permission Fix

Support for Ubuntu and other Desktop Linux distributions
Post Reply
afinite
Posts: 1
Joined: 23 Jan 2017, 20:35

Folder Permission Fix

Post by afinite »

Hi folks, just need some simple help with permission setting in filebot cli.... my current script (snippet seen below) sets the permission of the files and subdirectories correctly, but does not set them for the newly created directory correctly.

Example:
- I grab a new TV show and no directory exists for this show at the moment
- Once completed, my filebot script gets triggered (note: this is just part of the script):

Code: Select all

filebot -script fn:amc --output "$CONFIG_OUTPUT" --action duplicate --conflict auto -non-strict --log-file /root/tmp/amc.log --def "exec=chmod 777 '{folder}/' ; chown root:admin '{folder}/'" unsorted=y
The

Code: Select all

"exec=chmod 777 '{folder}/' ; chown root:admin '{folder}/'"
in the script above sets the permission for the sub-directories and files correctly... just not the main directory...

So:

Code: Select all

New TV Show (permission incorrect)
 - Sub dir 1 (permission is correct - 777 & root:admin)
------ File.mkv (permission is correct - 777 & root:admin)
Please help me fix this :)
User avatar
rednoah
The Source
Posts: 22995
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Folder Permission Fix

Post by rednoah »

Just do a recursive chmod/chown on all your files.
:idea: Please read the FAQ and How to Request Help.
Post Reply