Compare commits
No commits in common. "d6ba35810865b7b28cf9ae0f554aea3aed3cff95" and "154474cb501169229b36599283ef2a62d47b457b" have entirely different histories.
d6ba358108
...
154474cb50
Before Width: | Height: | Size: 3.1 MiB After Width: | Height: | Size: 3.1 MiB |
|
@ -37,7 +37,6 @@
|
||||||
hardware = {
|
hardware = {
|
||||||
bluetooth.enable = true;
|
bluetooth.enable = true;
|
||||||
pipewire.enable = true;
|
pipewire.enable = true;
|
||||||
print.enable = true;
|
|
||||||
};
|
};
|
||||||
dev = {
|
dev = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
|
@ -26,10 +26,6 @@ in {
|
||||||
no_fade_in = true;
|
no_fade_in = true;
|
||||||
no_fade_out = true;
|
no_fade_out = true;
|
||||||
text_trim = true;
|
text_trim = true;
|
||||||
# this will render the color we specified on the background before the image is loaded
|
|
||||||
# i like this because we will no longer see our screen for a split second before the image is ready
|
|
||||||
# extra security feature too
|
|
||||||
immediate_render = true;
|
|
||||||
};
|
};
|
||||||
background = [
|
background = [
|
||||||
{
|
{
|
||||||
|
@ -78,7 +74,7 @@ in {
|
||||||
halign = "center"; valign = "center";
|
halign = "center"; valign = "center";
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
position = "-15, -11";
|
position = "-15, -13";
|
||||||
halign = "right"; valign = "top";
|
halign = "right"; valign = "top";
|
||||||
color = "rgb(${base05})";
|
color = "rgb(${base05})";
|
||||||
font_size = 14;
|
font_size = 14;
|
||||||
|
|
|
@ -4,8 +4,7 @@ with lib;
|
||||||
let
|
let
|
||||||
cfg = config.modules.desktop.swww;
|
cfg = config.modules.desktop.swww;
|
||||||
|
|
||||||
wallpapersFolder = "${pkgs.my.wallpapers}/share/backgrounds";
|
img = ../../assets/wallpaper.png;
|
||||||
lastWallpaper = "$XDG_DATA_HOME/swww-last-wallpaper";
|
|
||||||
in {
|
in {
|
||||||
options.modules.desktop.swww = {
|
options.modules.desktop.swww = {
|
||||||
enable = mkEnableOption "Enable swww, a Solution to your Wayland Wallpaper Woes";
|
enable = mkEnableOption "Enable swww, a Solution to your Wayland Wallpaper Woes";
|
||||||
|
@ -17,25 +16,8 @@ in {
|
||||||
startScript = mkOption {
|
startScript = mkOption {
|
||||||
type = types.package;
|
type = types.package;
|
||||||
default = pkgs.writeScript "swww-start" ''
|
default = pkgs.writeScript "swww-start" ''
|
||||||
if [ ! -f "${lastWallpaper}" ]; then
|
|
||||||
echo "$(ls ${wallpapersFolder} | shuf -n 1)" > "${lastWallpaper}"
|
|
||||||
fi
|
|
||||||
|
|
||||||
${cfg.package}/bin/swww-daemon &
|
${cfg.package}/bin/swww-daemon &
|
||||||
${lib.getExe cfg.package} img "${wallpapersFolder}/$(cat ${lastWallpaper})" --transition-type none
|
${lib.getExe cfg.package} img "${img}" --transition-type none
|
||||||
'';
|
|
||||||
};
|
|
||||||
swapScript = mkOption {
|
|
||||||
type = types.package;
|
|
||||||
default = pkgs.writeScript "swww-swap" ''
|
|
||||||
file=$(ls ${wallpapersFolder} | ${lib.getExe pkgs.rofi-wayland} -dmenu -sep '\n' -i -p "select a wallpaper")
|
|
||||||
wallpaper="${wallpapersFolder}/$file"
|
|
||||||
|
|
||||||
[ ! -f "$wallpaper" ] && exit 1
|
|
||||||
|
|
||||||
${lib.getExe cfg.package} img "$wallpaper" --transition-type grow --transition-fps 60 --transition-pos 0.915,0.977 --transition-duration 1.5
|
|
||||||
|
|
||||||
echo "$file" > "${lastWallpaper}"
|
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -66,7 +66,6 @@ in {
|
||||||
"battery"
|
"battery"
|
||||||
"custom/weather"
|
"custom/weather"
|
||||||
"privacy"
|
"privacy"
|
||||||
"custom/wallpaper"
|
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
"group/power" = {
|
"group/power" = {
|
||||||
|
@ -99,12 +98,6 @@ in {
|
||||||
tooltip-format = "Power menu";
|
tooltip-format = "Power menu";
|
||||||
on-click = "${powerSelect}";
|
on-click = "${powerSelect}";
|
||||||
};
|
};
|
||||||
"custom/wallpaper" = {
|
|
||||||
format = "";
|
|
||||||
tooltip = true;
|
|
||||||
tooltip-format = "Change wallpaper";
|
|
||||||
on-click = "${config.modules.desktop.swww.swapScript}";
|
|
||||||
};
|
|
||||||
"hyprland/workspaces" = {
|
"hyprland/workspaces" = {
|
||||||
format = "{icon}";
|
format = "{icon}";
|
||||||
format-icons = {
|
format-icons = {
|
||||||
|
|
|
@ -1,30 +0,0 @@
|
||||||
{ pkgs, config, lib, ... }:
|
|
||||||
|
|
||||||
with lib;
|
|
||||||
let
|
|
||||||
cfg = config.modules.hardware.print;
|
|
||||||
in {
|
|
||||||
options.modules.hardware.print = {
|
|
||||||
enable = mkEnableOption "Enable various print services";
|
|
||||||
};
|
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
|
||||||
services.printing.enable = true;
|
|
||||||
services.printing.startWhenNeeded = true; # i am not the avid printer user
|
|
||||||
services.printing.browsed.enable = true;
|
|
||||||
services.printing.drivers = with pkgs; [
|
|
||||||
# gutenprint is very generic and supports a lot of printers
|
|
||||||
gutenprint
|
|
||||||
gutenprintBin
|
|
||||||
# brother laser printers
|
|
||||||
brlaser
|
|
||||||
];
|
|
||||||
|
|
||||||
# network discovery
|
|
||||||
services.avahi = {
|
|
||||||
enable = true;
|
|
||||||
openFirewall = true;
|
|
||||||
nssmdns4 = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
|
@ -13,7 +13,7 @@ stdenvNoCC.mkDerivation {
|
||||||
|
|
||||||
installPhase = ''
|
installPhase = ''
|
||||||
mkdir -p "$out/lib/firmware/brcm"
|
mkdir -p "$out/lib/firmware/brcm"
|
||||||
cp -r "$src/lib/firmware/brcm/." "$out/lib/firmware/brcm/"
|
cp -r lib/firmware/brcm/. "$out/lib/firmware/brcm/"
|
||||||
'';
|
'';
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
|
|
|
@ -1,22 +0,0 @@
|
||||||
{ lib, stdenvNoCC }:
|
|
||||||
|
|
||||||
stdenvNoCC.mkDerivation {
|
|
||||||
pname = "wallpapers";
|
|
||||||
version = "unstable";
|
|
||||||
|
|
||||||
src = ./.;
|
|
||||||
|
|
||||||
# later, add XML files to /usr(?)/share/backgrounds
|
|
||||||
# then, it is selectable from places like in gnome and also do the same for KDE
|
|
||||||
installPhase = ''
|
|
||||||
mkdir -p "$out/share/backgrounds"
|
|
||||||
cp -r "$src/img/." "$out/share/backgrounds/"
|
|
||||||
'';
|
|
||||||
|
|
||||||
meta = with lib; {
|
|
||||||
description = "Small collection of wallpapers";
|
|
||||||
# idk what to put here:
|
|
||||||
# license = licenses.ofl;
|
|
||||||
platforms = platforms.all;
|
|
||||||
};
|
|
||||||
}
|
|
Before Width: | Height: | Size: 649 KiB |
Before Width: | Height: | Size: 1.6 MiB |
Before Width: | Height: | Size: 2.2 MiB |
Before Width: | Height: | Size: 2.1 MiB |
Before Width: | Height: | Size: 2.1 MiB |
Before Width: | Height: | Size: 1.6 MiB |
Before Width: | Height: | Size: 2.4 MiB |
Before Width: | Height: | Size: 453 KiB |