Tiny Windows program that turns on/off dark theme at sunrise/sunset.
You can download the pre-built binary for the latest release on the
GitHub releases page. You can put
it anywhere you want on your computer. You can also build from source with
cargo
if you prefer (see Building below).
You will probably want to run the program at startup. To do so, add a shortcut to the executable (or the executable itself) in the "Start-up" folder:
- Copy the executable (
autolight.exe
) Windows + R
and typeshell:startup
. This will open the "Start-up" folder.- In the new explorer window, right-click and select "Paste shortcut". On Windows 11, you might have to "Show more options" first.
The configuration file is mandatory. It's loaded from
%USERPROFILE%\.autolight.toml
. This file is constantly watched and changes are
applied automatically.
# Set this to `true` to terminate the process immediately
disable = false
# Set this to `false` to disable notifications
notifications = true
# Set this to `true` to have dark theme at day and light theme at night
# Why would anyone do this??
invert = false
# How often the program should force a time check (in seconds)
# The program might unsync with the system clock when the computer goes to sleep
# or hibernates. This setting will force a time check to resync it.
refresh_period = 60
# Required for the program to work: replace with YOUR coordinates
[location]
latitude = 48.956775
longitude = 2.463845
autolight
is written in Rust!
Install it to build autolight
from source.
cargo build
You can also build in release
mode:
cargo build --release
Just run the executable. It runs in the background. Everything else happens in the configuration file.
To stop the process, set disable = true
in the configuration file.
- Initial release