Get a wallpaper based on the time of day.
Go to file
2020-10-27 22:17:37 +01:00
go.mod inital commit 2020-10-26 01:39:45 +01:00
main.go fixed runCommand 2020-10-27 22:17:37 +01:00
README.md inital commit 2020-10-26 01:39:45 +01:00

Get a wallpaper based on the time of day. You can get some wallpapers at Dynamic wallpaper club.

Usage

sunset --file sunset.json Get the current image to set as a walpaper.

sunset --file sunset.json --next Get the time when the next wallpaper should be set.

sunset --file sunset.json --wait How long to wait to set the next wallpaper.

If no file is provided then it defaults to ./sunset.json.

Sunset.json

The sunset file must be structured like this:

{
    "files": [
        {
            "file":"Ghib-0.jpg",
            "time":"9:30"
        },
        {
            "file":"Ghib-1.jpg",
            "time":"19:30"
        },
        {
            "file":"Ghib-2.jpg",
            "time":"8:00"
        },
        {
            "file":"Ghib-3.jpg",
            "time":"18:00"
        }
    ]
}

Convert heic file to jpeg

You need imagemagick.

mogrify -format jpg Ghib.heic or identify Ghib.heic | wc -l to count the images.