-
Download autocontrol.applescript from the GitHub repository
-
Create a Keychain password entry for SelfControl
- Open
Keychain
->Create Password
-> SetKeychain Item Name
andAccount Name
toSelfControl
- Set
Password
to your user admin password
- Open
Why? SelfControl requires your user admin password to start a block. The script uses this new Keychain entry to enter the user admin password automatically
- To start a block, run
osascript PATH/TO/autocontrol.scpt 120
where120
represents the duration of your desired block in minutes. By default, if no duration is specified, the block duration will be set to 1 hour. This can be changed inside the script.
I recommend using cron
for scheduling your blocking.
To start, open your terminal and enter crontab -e
to edit your cron entries
For documentation on how to format cronjob times, visit crontab.guru
Some example entries:
Everyday at 9AM, start a 3 hour block
00 9 * * * osascript ~/scripts/autocontrol.scpt 180
Every weekday at 10PM, start a 2 hour block
00 22 * * 1,2,3,4,5 osascript ~/scripts/autocontrol.scpt 120
-
cron
may not work if it does not haveFull Disk Access
.- To enable, go to
System Preferences
->Privacy & Security
->Full Disk Access
-> Click+
-> Presscommand+shift+G
-> Type/usr/sbin/cron
-> PressEnter
-> Select thecron
file -> ClickOpen
- To enable, go to
-
Support for multiple blocklists in currently unavailible, however, coming soon.