Artificial intelligent assistant

Entr: trying to trigger function while monitoring file change I'm trying to monitor some files with entr. My script based on their examples: do_it(){ echo Eita!; } while true; do ls folder/* more-folder/* | entr -pd do_it; done >> entr: exec do_it: No such file or directory However, this works: while true; do ls folder1/* folder2/* | entr -pd echo Eita!; done What am I doing wrong?

Answered by the programmers of entr (< "A function can be exported to a subshell, but you cannot execute a function with an external program. If you want to execute shell functions, you can write a loop such as this:"


do_it(){ echo 'Eita!'; }

while true; do
ls folder1/* folder2/* | entr -pd -s 'kill $PPID'
do_it
done

xcX3v84RxoQ-4GxG32940ukFUIEgYdPy 5f5e866a426f4437d3d10853eb343b19