sway: tidy

This commit is contained in:
Colin 2023-05-15 02:51:57 +00:00
parent f8d02687b9
commit a47e785ae7
3 changed files with 13 additions and 30 deletions

View File

@ -4,9 +4,6 @@
with lib; with lib;
let let
cfg = config.sane.gui.sway; cfg = config.sane.gui.sway;
waybar-config = import ./waybar-config.nix pkgs;
# waybar-config-text = lib.generators.toJSON {} waybar-config;
waybar-config-text = (pkgs.formats.json {}).generate "waybar-config.json" waybar-config;
# bare sway launcher # bare sway launcher
sway-launcher = pkgs.writeShellScriptBin "sway-launcher" '' sway-launcher = pkgs.writeShellScriptBin "sway-launcher" ''
@ -144,34 +141,18 @@ in
enable = true; enable = true;
wrapperFeatures.gtk = true; wrapperFeatures.gtk = true;
}; };
sane.user.fs.".config/sway/config" = sane-lib.fs.wantedText (import ./sway-config.nix { sane.user.fs.".config/sway/config" = sane-lib.fs.wantedText
inherit config pkgs; (import ./sway-config.nix { inherit config pkgs; });
});
sane.user.fs.".config/waybar/config" = sane-lib.fs.wantedSymlinkTo waybar-config-text; sane.user.fs.".config/waybar/config" =
let
waybar-config = import ./waybar-config.nix { inherit pkgs; };
in sane-lib.fs.wantedSymlinkTo (
(pkgs.formats.json {}).generate "waybar-config.json" waybar-config
);
# style docs: https://github.com/Alexays/Waybar/wiki/Styling sane.user.fs.".config/waybar/style.css" = sane-lib.fs.wantedText
sane.user.fs.".config/waybar/style.css" = sane-lib.fs.wantedText (builtins.readFile ./waybar-style.css); (builtins.readFile ./waybar-style.css);
# style = ''
# * {
# border: none;
# border-radius: 0;
# font-family: Source Code Pro;
# }
# window#waybar {
# background: #16191C;
# color: #AAB2BF;
# }
# #workspaces button {
# padding: 0 5px;
# }
# .custom-spotify {
# padding: 0 10px;
# margin: 0 4px;
# background-color: #1DB954;
# color: black;
# }
# '';
}) })
]; ];
} }

View File

@ -1,6 +1,6 @@
# docs: https://github.com/Alexays/Waybar/wiki/Configuration # docs: https://github.com/Alexays/Waybar/wiki/Configuration
# format specifiers: https://fmt.dev/latest/syntax.html#syntax # format specifiers: https://fmt.dev/latest/syntax.html#syntax
pkgs: { pkgs }:
[ [
{ # TOP BAR { # TOP BAR
layer = "top"; layer = "top";

View File

@ -1,3 +1,5 @@
/* style docs: https://github.com/Alexays/Waybar/wiki/Styling */
* { * {
font-family: monospace; font-family: monospace;
} }