sublime-autotheme
A small script to change your sublime text theme for day and night. Made for MacOS.
If the time is between 7PM-7AM, a dark theme will be applied, otherwise a light theme will be applied.
You can change these times inside autotheme.sh
:
- Go to this line:
if [[ $time -gt 1900 || $time -lt 700 ]]; then
1900
is 7PM in 24 hour time and700
is 7AM in 24 hour time- Change these to your desired times at which a dark theme will be applied
How to use
- Inside
autotheme.sh
there are 4 variables you need to change. See the comments inautotheme.sh
to do this. - Once you have made the changes simply run
./install.sh
. This will ask for your password so it can copyautotheme.sh
into/usr/local/bin
.
A launch agent in ~/Library/LaunchAgents/
will run autotheme.sh
on the hour.