add wallpapers, using git-lfs to manage it

update niri background settings for wallpaper
This commit is contained in:
ulic-youthlic 2025-01-13 12:01:21 +08:00
parent dd77858199
commit 47dac088a4
Signed by: youthlic
GPG key ID: 63E86C3C14A0D721
7 changed files with 39 additions and 2 deletions

2
.gitattributes vendored Normal file
View file

@ -0,0 +1,2 @@
home/david/modules/wallpaper/pic/ filter=lfs diff=lfs merge=lfs -text
home/david/modules/wallpaper/pic/01.png filter=lfs diff=lfs merge=lfs -text

View file

@ -28,6 +28,10 @@
sops.enable = true; sops.enable = true;
}; };
david = {
wallpaper.enable = true;
};
xdg.userDirs = { xdg.userDirs = {
enable = true; enable = true;
download = "${config.home.homeDirectory}/dls"; download = "${config.home.homeDirectory}/dls";

View file

@ -127,7 +127,7 @@ environment {
} }
spawn-at-startup "waybar" spawn-at-startup "waybar"
spawn-at-startup "mako" spawn-at-startup "mako"
spawn-at-startup "swaybg" "-i" "/home/david/pic/wallpaper/screenbackground.png" spawn-at-startup "swaybg" "-i" "/home/david/wallpaper/01.png"
spawn-at-startup "fcitx5" "-d" "--replace" spawn-at-startup "fcitx5" "-d" "--replace"
spawn-at-startup "xwayland-satellite" ":1" spawn-at-startup "xwayland-satellite" ":1"

View file

@ -1 +1,6 @@
{ ... }: { } { ... }:
{
imports = [
./wallpaper
];
}

View file

@ -0,0 +1,22 @@
{ lib, config, ... }:
let
cfg = config.david.wallpaper;
in
{
options = {
david.wallpaper = {
enable = lib.mkOption {
type = lib.types.bool;
default = true;
example = false;
};
};
};
config = lib.mkIf cfg.enable {
home.file."wallpaper" = {
force = true;
recursive = true;
source = ./pic;
};
};
}

BIN
home/david/modules/wallpaper/pic/01.png (Stored with Git LFS) Normal file

Binary file not shown.

View file

@ -61,6 +61,7 @@
side-by-side = true; side-by-side = true;
}; };
}; };
lfs.enable = true;
extraConfig = { extraConfig = {
credential = { credential = {
helper = "store --file=${config.sops.secrets."git-credential".path}"; helper = "store --file=${config.sops.secrets."git-credential".path}";