Skip to content

sotormd/xkcd-wall

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

xkcd-wall

Get xkcd on YOUR wallpaper today.

xkcd-wall is a simple tool to fetch xkcd comics, recolor them, and generate wallpapers with a solid background.

It supports fetching the latest comic, a specific comic by number, or a random comic.

The tool is configured via JSON and packaged with Nix.

A NixOS module is also included, which sets up a systemd timer.

Usage

  1. Get today's comic

    nix run github:sotormd/xkcd-wall -- -t today ./output.png
  2. Get a random comic

    nix run github:sotormd/xkcd-wall -- -t random ./output.png
  3. Get a specific comic

    nix run github:sotormd/xkcd-wall -- -t 1341 ./output.png

Configuration

The tool looks for configuration in $HOME/.config/xkcd-wall/config.json.

If this does not exist, a default configuration file is created.

A configuration file path can also be passed using the -c flag.

nix run github:sotormd/xkcd-wall -- -t today -c /tmp/config.json ./output.png
Click to expand: default configuration values
{
  "background-colors": ["#2e3440"],
  "foreground-colors": ["#d8dee9"],
  "dimensions": "1920x1080",
  "cache": "/tmp/xkcd-wall-cache"
}

The configuration values are explained here:

value explanation example
background-colors list of background colors to randomly choose from ["#2e3440", "#3b4252"]
foreground-colors list of foreground colors to randomly choose from ["#bf616a", "#d08770", "#ebcb8b", "#a3be8c", "#b48ead"]
dimensions output image dimensions "1920x1200"
cache cache directory "/home/username/.cache"

About

Get xkcd on YOUR wallpaper today.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published