I have the following shell script:
#!/bin/bash
time=$(time);
imagesnap -q "/var/captures/$time.jpg";
When I run it in the terminal, everything works. But when I run it using launchtl
or crontab
at login, nothing happens.
Does anyone know how to run this script at login? It it even possible?
Thanks for any answers in advance!
Note
The issue is not with crontab
or launchctl
, I have got them to work. They just wont work with the camera.
I am using Imagesnap as a dependency for capturing images.
My Machine
I am using macOS 14.1 Beta 2 on a 2021 macBook Pro