yep, more dotfiles

replace swaybar with waybar

wiro.world 356ed892 aecf3ad7

verified
Changed files
+269 -39
home-manager
+55 -31
flake.lock
···
"fromYaml": "fromYaml"
},
"locked": {
-
"lastModified": 1755819240,
-
"narHash": "sha256-qcMhnL7aGAuFuutH4rq9fvAhCpJWVHLcHVZLtPctPlo=",
"owner": "SenchoPens",
"repo": "base16.nix",
-
"rev": "75ed5e5e3fce37df22e49125181fa37899c3ccd6",
"type": "github"
},
"original": {
···
"base16-fish": {
"flake": false,
"locked": {
-
"lastModified": 1622559957,
-
"narHash": "sha256-PebymhVYbL8trDVVXxCvZgc0S5VxI7I1Hv4RMSquTpA=",
"owner": "tomyun",
"repo": "base16-fish",
-
"rev": "2f6dd973a9075dabccd26f1cded09508180bf5fe",
"type": "github"
},
"original": {
"owner": "tomyun",
"repo": "base16-fish",
"type": "github"
}
},
"base16-helix": {
"flake": false,
"locked": {
-
"lastModified": 1752979451,
-
"narHash": "sha256-0CQM+FkYy0fOO/sMGhOoNL80ftsAzYCg9VhIrodqusM=",
"owner": "tinted-theming",
"repo": "base16-helix",
-
"rev": "27cf1e66e50abc622fb76a3019012dc07c678fac",
"type": "github"
},
"original": {
···
"firefox-gnome-theme": {
"flake": false,
"locked": {
-
"lastModified": 1758112371,
-
"narHash": "sha256-lizRM2pj6PHrR25yimjyFn04OS4wcdbc38DCdBVa2rk=",
"owner": "rafaelmardojai",
"repo": "firefox-gnome-theme",
-
"rev": "0909cfe4a2af8d358ad13b20246a350e14c2473d",
"type": "github"
},
"original": {
···
]
},
"locked": {
-
"lastModified": 1756770412,
-
"narHash": "sha256-+uWLQZccFHwqpGqr2Yt5VsW/PbeJVTn9Dk6SHWhNRPw=",
"owner": "hercules-ci",
"repo": "flake-parts",
-
"rev": "4524271976b625a4a605beefd893f270620fd751",
"type": "github"
},
"original": {
···
"nixpkgs": [
"stylix",
"nixpkgs"
-
]
},
"locked": {
-
"lastModified": 1758998580,
-
"narHash": "sha256-VLx0z396gDCGSiowLMFz5XRO/XuNV+4EnDYjdJhHvUk=",
"owner": "nix-community",
"repo": "NUR",
-
"rev": "ba8d9c98f5f4630bcb0e815ab456afd90c930728",
"type": "github"
},
"original": {
···
"tinted-zed": "tinted-zed"
},
"locked": {
-
"lastModified": 1759596342,
-
"narHash": "sha256-1Eda1V8pjpviMdBTdDXrFp7jkaUokIgXgBYTZyzDODk=",
"owner": "nix-community",
"repo": "stylix",
-
"rev": "4d065856e936fc6a99ba55d39ac2df9ded6bedbe",
"type": "github"
},
"original": {
···
"tinted-schemes": {
"flake": false,
"locked": {
-
"lastModified": 1757716333,
-
"narHash": "sha256-d4km8W7w2zCUEmPAPUoLk1NlYrGODuVa3P7St+UrqkM=",
"owner": "tinted-theming",
"repo": "schemes",
-
"rev": "317a5e10c35825a6c905d912e480dfe8e71c7559",
"type": "github"
},
"original": {
···
"tinted-tmux": {
"flake": false,
"locked": {
-
"lastModified": 1757811970,
-
"narHash": "sha256-n5ZJgmzGZXOD9pZdAl1OnBu3PIqD+X3vEBUGbTi4JiI=",
"owner": "tinted-theming",
"repo": "tinted-tmux",
-
"rev": "d217ba31c846006e9e0ae70775b0ee0f00aa6b1e",
"type": "github"
},
"original": {
···
"tinted-zed": {
"flake": false,
"locked": {
-
"lastModified": 1757811247,
-
"narHash": "sha256-4EFOUyLj85NRL3OacHoLGEo0wjiRJzfsXtR4CZWAn6w=",
"owner": "tinted-theming",
"repo": "base16-zed",
-
"rev": "824fe0aacf82b3c26690d14e8d2cedd56e18404e",
"type": "github"
},
"original": {
"owner": "tinted-theming",
"repo": "base16-zed",
"type": "github"
}
},
···
"fromYaml": "fromYaml"
},
"locked": {
+
"lastModified": 1746562888,
+
"narHash": "sha256-YgNJQyB5dQiwavdDFBMNKk1wyS77AtdgDk/VtU6wEaI=",
"owner": "SenchoPens",
"repo": "base16.nix",
+
"rev": "806a1777a5db2a1ef9d5d6f493ef2381047f2b89",
"type": "github"
},
"original": {
···
"base16-fish": {
"flake": false,
"locked": {
+
"lastModified": 1754405784,
+
"narHash": "sha256-l9xHIy+85FN+bEo6yquq2IjD1rSg9fjfjpyGP1W8YXo=",
"owner": "tomyun",
"repo": "base16-fish",
+
"rev": "23ae20a0093dca0d7b39d76ba2401af0ccf9c561",
"type": "github"
},
"original": {
"owner": "tomyun",
"repo": "base16-fish",
+
"rev": "23ae20a0093dca0d7b39d76ba2401af0ccf9c561",
"type": "github"
}
},
"base16-helix": {
"flake": false,
"locked": {
+
"lastModified": 1748408240,
+
"narHash": "sha256-9M2b1rMyMzJK0eusea0x3lyh3mu5nMeEDSc4RZkGm+g=",
"owner": "tinted-theming",
"repo": "base16-helix",
+
"rev": "6c711ab1a9db6f51e2f6887cc3345530b33e152e",
"type": "github"
},
"original": {
···
"firefox-gnome-theme": {
"flake": false,
"locked": {
+
"lastModified": 1748383148,
+
"narHash": "sha256-pGvD/RGuuPf/4oogsfeRaeMm6ipUIznI2QSILKjKzeA=",
"owner": "rafaelmardojai",
"repo": "firefox-gnome-theme",
+
"rev": "4eb2714fbed2b80e234312611a947d6cb7d70caf",
"type": "github"
},
"original": {
···
]
},
"locked": {
+
"lastModified": 1749398372,
+
"narHash": "sha256-tYBdgS56eXYaWVW3fsnPQ/nFlgWi/Z2Ymhyu21zVM98=",
"owner": "hercules-ci",
"repo": "flake-parts",
+
"rev": "9305fe4e5c2a6fcf5ba6a3ff155720fbe4076569",
"type": "github"
},
"original": {
···
"nixpkgs": [
"stylix",
"nixpkgs"
+
],
+
"treefmt-nix": "treefmt-nix"
},
"locked": {
+
"lastModified": 1751320053,
+
"narHash": "sha256-3m6RMw0FbbaUUa01PNaMLoO7D99aBClmY5ed9V3vz+0=",
"owner": "nix-community",
"repo": "NUR",
+
"rev": "cbde1735782f9c2bb2c63d5e05fba171a14a4670",
"type": "github"
},
"original": {
···
"tinted-zed": "tinted-zed"
},
"locked": {
+
"lastModified": 1760478648,
+
"narHash": "sha256-Y4l+Y3zUvqIDbyLrtOrzNvp1o50Fp9TYK+iwtwweFU4=",
"owner": "nix-community",
"repo": "stylix",
+
"rev": "1ec254101285777db13922303cc47ded06e10bb3",
"type": "github"
},
"original": {
···
"tinted-schemes": {
"flake": false,
"locked": {
+
"lastModified": 1750770351,
+
"narHash": "sha256-LI+BnRoFNRa2ffbe3dcuIRYAUcGklBx0+EcFxlHj0SY=",
"owner": "tinted-theming",
"repo": "schemes",
+
"rev": "5a775c6ffd6e6125947b393872cde95867d85a2a",
"type": "github"
},
"original": {
···
"tinted-tmux": {
"flake": false,
"locked": {
+
"lastModified": 1751159871,
+
"narHash": "sha256-UOHBN1fgHIEzvPmdNMHaDvdRMgLmEJh2hNmDrp3d3LE=",
"owner": "tinted-theming",
"repo": "tinted-tmux",
+
"rev": "bded5e24407cec9d01bd47a317d15b9223a1546c",
"type": "github"
},
"original": {
···
"tinted-zed": {
"flake": false,
"locked": {
+
"lastModified": 1751158968,
+
"narHash": "sha256-ksOyv7D3SRRtebpXxgpG4TK8gZSKFc4TIZpR+C98jX8=",
"owner": "tinted-theming",
"repo": "base16-zed",
+
"rev": "86a470d94204f7652b906ab0d378e4231a5b3384",
"type": "github"
},
"original": {
"owner": "tinted-theming",
"repo": "base16-zed",
+
"type": "github"
+
}
+
},
+
"treefmt-nix": {
+
"inputs": {
+
"nixpkgs": [
+
"stylix",
+
"nur",
+
"nixpkgs"
+
]
+
},
+
"locked": {
+
"lastModified": 1733222881,
+
"narHash": "sha256-JIPcz1PrpXUCbaccEnrcUS8jjEb/1vJbZz5KkobyFdM=",
+
"owner": "numtide",
+
"repo": "treefmt-nix",
+
"rev": "49717b5af6f80172275d47a418c9719a31a78b53",
+
"type": "github"
+
},
+
"original": {
+
"owner": "numtide",
+
"repo": "treefmt-nix",
"type": "github"
}
},
+1
home-manager/fragments/default.nix
···
./thunderbird.nix
./tools.nix
./vscodium.nix
./xdg-mime.nix
./zellij
];
···
./thunderbird.nix
./tools.nix
./vscodium.nix
+
./waybar.nix
./xdg-mime.nix
./zellij
];
+4 -1
home-manager/fragments/firefox.nix
···
config = lib.mkIf cfg.enable {
home.sessionVariables.BROWSER = lib.getExe pkgs.firefox;
-
stylix.targets.firefox.profileNames = [ "default" ];
programs.firefox = {
enable = true;
···
config = lib.mkIf cfg.enable {
home.sessionVariables.BROWSER = lib.getExe pkgs.firefox;
+
stylix.targets.firefox = {
+
enable = false;
+
profileNames = [ "default" ];
+
};
programs.firefox = {
enable = true;
+4 -3
home-manager/fragments/stylix.nix
···
'';
config = lib.mkIf cfg.enable {
-
specialisation.light.configuration = {
-
stylix.base16Scheme = "${pkgs.base16-schemes}/share/themes/one-light.yaml";
-
};
stylix = {
enable = true;
···
'';
config = lib.mkIf cfg.enable {
+
# TODO: take a lot of build time
+
# specialisation.light.configuration = {
+
# stylix.base16Scheme = "${pkgs.base16-schemes}/share/themes/one-light.yaml";
+
# };
stylix = {
enable = true;
-2
home-manager/fragments/sway.nix
···
inherit (self.outputs) homeManagerModules;
cfg = config.local.fragment.sway;
-
-
theme = config.lib.stylix.colors;
cfg-sway = config.wayland.windowManager.sway.config;
workspacesRange = lib.zipListsWith (key-idx: workspace-idx: { inherit key-idx workspace-idx; }) [ 1 2 3 4 5 6 7 8 9 0 ] (lib.range 1 10);
···
inherit (self.outputs) homeManagerModules;
cfg = config.local.fragment.sway;
cfg-sway = config.wayland.windowManager.sway.config;
workspacesRange = lib.zipListsWith (key-idx: workspace-idx: { inherit key-idx workspace-idx; }) [ 1 2 3 4 5 6 7 8 9 0 ] (lib.range 1 10);
+6 -2
home-manager/fragments/swaybar.nix
···
}:
let
-
cfg = config.local.fragment.sway;
integrated-keyboard-id = "1:1:AT_Translated_Set_2_keyboard";
integrated-keyboard-id-bis = "1:1:kanata";
···
swaymsg = lib.getExe' pkgs.sway "swaymsg";
in
{
config = lib.mkIf cfg.enable {
programs.i3status-rust = {
enable = true;
···
icons = "awesome6";
settings.icon_format = " <span font_family='FontAwesome6'>{icon}</span> ";
-
blocks = [
{
block = "custom";
···
}:
let
+
cfg = config.local.fragment.swaybar;
integrated-keyboard-id = "1:1:AT_Translated_Set_2_keyboard";
integrated-keyboard-id-bis = "1:1:kanata";
···
swaymsg = lib.getExe' pkgs.sway "swaymsg";
in
{
+
options.local.fragment.swaybar.enable = lib.mkEnableOption ''
+
Swaybar related
+
'';
+
config = lib.mkIf cfg.enable {
programs.i3status-rust = {
enable = true;
···
icons = "awesome6";
settings.icon_format = " <span font_family='FontAwesome6'>{icon}</span> ";
+
blocks = [
{
block = "custom";
+198
home-manager/fragments/waybar.nix
···
···
+
{ config
+
, lib
+
, pkgs
+
, ...
+
}:
+
+
let
+
cfg = config.local.fragment.waybar;
+
in
+
{
+
options.local.fragment.waybar.enable = lib.mkEnableOption ''
+
Waybar related
+
'';
+
+
config = lib.mkIf cfg.enable {
+
stylix.targets.waybar = {
+
font = "sansSerif";
+
addCss = false;
+
};
+
+
services.playerctld.enable = true;
+
+
programs.waybar = {
+
enable = true;
+
+
settings.main = {
+
mode = "hide";
+
ipc = true;
+
position = "bottom";
+
+
modules-left = [
+
"sway/workspaces"
+
];
+
+
modules-center = [ ];
+
+
modules-right = [
+
"cava"
+
"mpris"
+
"pulseaudio"
+
"battery"
+
"clock"
+
"tray"
+
];
+
+
"sway/workspaces" = {
+
disable-scroll = true;
+
format = "{name}:{icon}";
+
format-icons = {
+
default = "";
+
+
"1" = "";
+
"2" = "";
+
"3" = "";
+
"4" = "";
+
"10" = "";
+
};
+
};
+
+
tray.spacing = 10;
+
+
clock = {
+
format = "{:%d %b %H:%M}";
+
tooltip = false;
+
};
+
+
battery = {
+
states = {
+
good = 95;
+
warning = 30;
+
critical = 15;
+
};
+
+
format = "{capacity}% {icon}";
+
format-full = "{capacity}% {icon}";
+
format-charging = "{capacity}% ";
+
format-plugged = "{capacity}% ";
+
format-icons = [ " " " " " " " " " " ];
+
};
+
+
pulseaudio = {
+
scroll-step = 5;
+
+
format = "{volume}% {icon} {format_source}";
+
tooltip = false;
+
format-bluetooth = "{volume}% {icon} {format_source}";
+
format-bluetooth-muted = " {icon} {format_source}";
+
format-muted = " {format_source}";
+
format-source = "{volume}% ";
+
format-source-muted = "";
+
format-icons = {
+
headset = "";
+
headphone = "";
+
hands-free = "";
+
phone = "";
+
portable = "";
+
car = "";
+
default = [ "" " " " " ];
+
};
+
+
on-click = "pavucontrol";
+
};
+
+
mpris = {
+
format = "{title} - {artist}";
+
tooltip-format = "{album} ({player})";
+
};
+
+
cava = {
+
bars = 6;
+
format-icons = [ "▁" "▂" "▃" "▄" "▅" "▆" "▇" "█" ];
+
bar_delimiter = 0;
+
hide_on_silence = true;
+
};
+
};
+
+
style = ''
+
#waybar, tooltip { color: @base00; }
+
tooltip { border-color: @base0D; background-color: @base00; }
+
tooltip label { color: @base05; }
+
+
#clock { color: @base00; background-color: @base03; }
+
+
#battery { color: @base00; background-color: @base0D; }
+
#battery.charging { background-color: @base0E; }
+
+
#pulseaudio { color: @base00; background-color: @base09; }
+
#pulseaudio.muted { background-color: @base0C; }
+
+
#mpris { background-color: @base0B; }
+
+
#cava { background-color: @base0E; }
+
''
+
+ ''
+
* {
+
border-radius: 0;
+
}
+
+
/* Apply transparency to the bar (handled above by Stylix) */
+
#waybar { background: alpha(white, 0); }
+
+
/* Apply margin to all module groups */
+
.modules-left, .modules-center, .modules-right {
+
/*margin: .5rem .8rem;*/
+
}
+
+
/* Apply padding to all modules */
+
.modules-right widget .module {
+
padding: 0 1rem;
+
+
color: @base07;
+
}
+
+
/* Round first and last child of left, right and center modules. Disable rounding on the sides*/
+
.modules-left widget:last-child .module,
+
.modules-center widget:last-child .module/*,
+
.modules-right widget:last-child .module*/ {
+
border-top-right-radius: 5px;
+
}
+
/*.modules-left widget:first-child .module,*/
+
.modules-center widget:first-child .module,
+
.modules-right widget:first-child .module {
+
border-top-left-radius: 5px;
+
}
+
+
#tray {
+
background-color: @base03;
+
}
+
+
/* Round first and last child of workspaces. */
+
#workspaces button:first-child {
+
/*border-top-left-radius: 5px;*/
+
}
+
#workspaces button:last-child {
+
border-top-right-radius: 5px;
+
}
+
+
#workspaces button {
+
color: @base07;
+
background-color: @base03;
+
}
+
#workspaces button:hover {
+
color: @base07;
+
background-color: @base03;
+
}
+
#workspaces button.urgent { color: @base08; }
+
'';
+
};
+
+
wayland.windowManager.sway.config.bars = [{
+
command = lib.getExe pkgs.waybar;
+
+
mode = "hide";
+
hiddenState = "hide";
+
}];
+
};
+
}
+
+1
home-manager/profiles/desktop.nix
···
thunderbird.enable = true;
tools.enable = true;
vscodium.enable = true;
xdg-mime.enable = true;
zellij.enable = true;
};
···
thunderbird.enable = true;
tools.enable = true;
vscodium.enable = true;
+
waybar.enable = true;
xdg-mime.enable = true;
zellij.enable = true;
};