Linked Questions

1
vote
1answer
2k views

Adding a startup script on Big Sur [duplicate]

I want to install a startup item in OS X Big Sur which runs a shell script as a user on my machine and connects via ssh to a remote machine I maintain. I use ssh keys so no password is required for ...
0
votes
1answer
261 views

How to use Launchd? [duplicate]

(sorry if this is a bad question. I am new to apple coding) I want to run a .scpt file at a specific time, once a day, every day using launchd (if there is a better way please tell me) I am running ...
1
vote
0answers
70 views

How can I use launchd to auto update brew? [duplicate]

I followed the instructions on the page Creating Launch Daemons and Agents and created (as root) my own plist file named com.personal.brew.plist and located in /Library/LaunchDeamons/: <?xml ...
10
votes
2answers
5k views

Is cron command supposed to work like this?

I've set up cron to run a script hourly but when I reboot cron does not work. Does this mean that I should run cron whenever I boot into my Mac? The cron command which I use cron 5 * * * * path/to/...
4
votes
3answers
6k views

How to completely block specific Wi-Fi SSID on macOS?

I'm looking for a way to totally blacklist a Wi-Fi network (by SSID) in macOS. And no, I promise you that I really (truly!) do not need to just have the computer "forget it" by removing it from the ...
4
votes
1answer
9k views

How to add startup program using Terminal?

Honestly, I'm finding Apple's launchctl and plist (XML?) usage to be somewhat confusing and overkill. Using Terminal, I just wanna say hey, macOS, start program.app at boot! or hey, macOS, start my /...
2
votes
2answers
1k views

Launchd running an Applescript every two hours

I have written a small applescript that I would like to run automatically every 2 hours. I have thus written the following launchd daemon (probably it is an agent): <?xml version="1.0" encoding="...
4
votes
2answers
496 views

Earliest way to disable wifi at login or boot

I'm running Catalina, and the OS will always turn wifi on at boot. I've been looking into methods to turn wifi power off when I login, and I've created a .plist: <?xml version="1.0" encoding="UTF-...
1
vote
2answers
1k views

Using sudo command in shell script in Automator app?

I'm planning to make a small Automator app to make these commands into something I can run regularly: rm -rf ~/Library/Caches/* rm -rf ~/Library/Saved\ Application\ State/* sudo rm -rf /Library/...
2
votes
2answers
982 views

How do I run an app using launchd at regular intervals?

I have an app which is written in AppleScripting language which checks if the S.M.A.R.T. status is 'Verified' if it is not then it will automatically show me a dialog alert. But I need it to run every ...
2
votes
1answer
1k views

launchctl config file location?

I'm trying to configure a NetBoot image so that a script will automatically launch on the target machine after it boots from the image I've been using this article as a reference: https://medium.com/...
1
vote
1answer
929 views

Running a script with administrator privileges from a standard client terminal

I have the strong feeling I'm trying to reinvent the wheel, but I did spend some time without finding an existing solution. I have an already working shell script with several sudos. Its first target ...
2
votes
2answers
741 views

Show dialog at login (bash script)

The idea is that when somebody logs in to my Mac, a popup will show up and the date/time are written to a log. I run the bash script from a cron job: @reboot ~/Develop/login.sh (I know about ...
1
vote
2answers
610 views

rsync cron job for backup not working

I'm trying to run a backup from one HDD to another at 10pm everynight on a Mac Pro. I have tested the rsync and it backups just fine outside of the cron table. Here is what I have and it's not running ...
1
vote
0answers
917 views

launchD runs script every hour in between 8:00 to 17:00 on weekdays

launchD runs script every hour in between 8:00 to 17:00 hours on weekdays Mon to Fri. 8 to 17:00 = 9 times in a Day. Mon - Friday = 5 days Do I have to add StartCalendarInterval 9 X 5 = 45 times or ...

15 30 50 per page