Page 1 of 1

shell script does not run in subfolder

PostPosted: Tue Mar 08, 2016 11:06 am
by vloryan
hi there,

i have a shell scirpt that should run in the subfolder (depth = 2). but it does run in the top level folder :( any idea?

Code: Select all
gs -q -dBATCH -dNOPAUSE -sDEVICE=pdfwrite -sOutputFile=fileout.pdf \
    *.pdf


Image

thanks!

Re: shell script does not run in subfolder

PostPosted: Tue Mar 08, 2016 2:34 pm
by Mr_Noodle
Read the sticky article. You need to create another rule to tell Hazel to go into subfolders.

Re: shell script does not run in subfolder

PostPosted: Tue Mar 08, 2016 3:39 pm
by vloryan
rules work in the subfolders, that is not the problem. the shell script does not merge pdfs from that subfolder, but from the top level folder instead?

Re: shell script does not run in subfolder

PostPosted: Wed Mar 09, 2016 5:11 am
by vloryan
Running this script

Code: Select all
gs -q -dBATCH -dNOPAUSE -sDEVICE=pdfwrite -sOutputFile="$1"/fileout.pdf \
    "$1"/*.pdf


on the folder, not on the file worked! Topic closed :)