feat: variable-based path interpolated hyprpaper config UNTESTED
This commit is contained in:
parent
899c1b4a26
commit
362d2098bf
4 changed files with 38 additions and 7 deletions
BIN
home-manager/stvnliu/assets/gruvbox-wallpaper.png
Normal file
BIN
home-manager/stvnliu/assets/gruvbox-wallpaper.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 187 KiB |
|
@ -7,10 +7,6 @@
|
||||||
pkgs,
|
pkgs,
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
let
|
|
||||||
myUserName = "stvnliu";
|
|
||||||
myEmail = "z.liu@outlook.com.gr";
|
|
||||||
in
|
|
||||||
{
|
{
|
||||||
# You can import other home-manager modules here
|
# You can import other home-manager modules here
|
||||||
imports = [
|
imports = [
|
||||||
|
@ -21,6 +17,7 @@ in
|
||||||
#./swaywm.nix
|
#./swaywm.nix
|
||||||
./hyprland.nix
|
./hyprland.nix
|
||||||
./shells
|
./shells
|
||||||
|
./variables.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
nixpkgs = {
|
nixpkgs = {
|
||||||
|
@ -46,8 +43,11 @@ in
|
||||||
};
|
};
|
||||||
|
|
||||||
home = {
|
home = {
|
||||||
username = "${myUserName}";
|
username = "${config.myUserName}";
|
||||||
homeDirectory = "/home/${myUserName}";
|
homeDirectory = "/home/${config.myUserName}";
|
||||||
|
file = {
|
||||||
|
"wallpaper.png".source = ./assets/gruvbox-wallpaper.png;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
programs.neovim.enable = true;
|
programs.neovim.enable = true;
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
|
@ -55,7 +55,11 @@ in
|
||||||
devenv
|
devenv
|
||||||
];
|
];
|
||||||
programs.home-manager.enable = true;
|
programs.home-manager.enable = true;
|
||||||
programs.git.enable = true;
|
programs.git = {
|
||||||
|
enable = true;
|
||||||
|
userName = config.myDisplayName;
|
||||||
|
userEmail = config.myEmail;
|
||||||
|
};
|
||||||
programs.firefox.enable = true;
|
programs.firefox.enable = true;
|
||||||
# Nicely reload system units when changing configs
|
# Nicely reload system units when changing configs
|
||||||
systemd.user.startServices = "sd-switch";
|
systemd.user.startServices = "sd-switch";
|
||||||
|
|
12
home-manager/stvnliu/hyprpaper.nix
Normal file
12
home-manager/stvnliu/hyprpaper.nix
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
{pkgs, config, ...}:
|
||||||
|
{
|
||||||
|
services.hyprpaper = {
|
||||||
|
enable = true;
|
||||||
|
settings = {
|
||||||
|
ipc = "on";
|
||||||
|
splash = false;
|
||||||
|
preload = [ config.myWallPaperPathString ];
|
||||||
|
wallpapaer = ",${config.myWallPaperPathString}";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
15
home-manager/stvnliu/variables.nix
Normal file
15
home-manager/stvnliu/variables.nix
Normal file
|
@ -0,0 +1,15 @@
|
||||||
|
{pkgs, config, lib, ...}:
|
||||||
|
{
|
||||||
|
options = with lib; with types; {
|
||||||
|
myWallPaperPathString = { type = str; };
|
||||||
|
myUserName = { type = str; };
|
||||||
|
myDisplayName = { type = str; };
|
||||||
|
myEmail = { type = str; };
|
||||||
|
};
|
||||||
|
config = rec {
|
||||||
|
myUserName = "stvnliu";
|
||||||
|
myWallPaperPathString = "/home/${config.myUserName}/wallpaper.png";
|
||||||
|
myDisplayName = "Zhongheng Liu";
|
||||||
|
myEmail = "z.liu@outlook.com.gr";
|
||||||
|
};
|
||||||
|
}
|
Loading…
Add table
Add a link
Reference in a new issue