How can I run a backup script once each weekend on a Mac that sleeps often using launchd?
1
vote
2
answers
307
views
I recently lost configuration of one of my IDEs (deleted it myself, I am very smart). I had a backup but it was a few months old. I have a script to backup all my config and push it to GitHub. I was looking into a way to run a script every week to back up everything automatically but
launchd
/ cron
need a specific time to run. My laptop might not be running at that time but I do boot up my laptop every weekend at least once.
To make it clear, my problem differs substantially from this question talks about running a script "10 minutes after 2 am every weekday only" . I’m not sure how to adapt it to my need to run only once per weekend.
Is there a way to configure launchd
/ cron
to run on a weekend at any time to back up my configuration?
Asked by Sourabh
(151 rep)
Jul 21, 2018, 01:36 PM
Last activity: Feb 4, 2024, 04:06 PM
Last activity: Feb 4, 2024, 04:06 PM