diff --git a/hosts/spectre-x360-2018/default.nix b/hosts/spectre-x360-2018/default.nix
index ded8da5..42102fa 100644
--- a/hosts/spectre-x360-2018/default.nix
+++ b/hosts/spectre-x360-2018/default.nix
@@ -4,6 +4,7 @@
imports = [
./configuration.nix
./hardware-configuration.nix
+ ../../modules/nixos/fonts.nix
../../modules/nixos/hyprland.nix
../../modules/nixos/monitoring.nix
../../modules/nixos/networking.nix
diff --git a/modules/home-manager/hypr/default.nix b/modules/home-manager/hypr/default.nix
index 974cd89..6389027 100644
--- a/modules/home-manager/hypr/default.nix
+++ b/modules/home-manager/hypr/default.nix
@@ -2,5 +2,6 @@
imports = [
./hyprland-customization.nix
./hyprpaper.nix
+ ./waybar.nix
];
}
\ No newline at end of file
diff --git a/modules/home-manager/hypr/hyprland-customization.nix b/modules/home-manager/hypr/hyprland-customization.nix
index 4de80b1..1c49b99 100644
--- a/modules/home-manager/hypr/hyprland-customization.nix
+++ b/modules/home-manager/hypr/hyprland-customization.nix
@@ -6,7 +6,6 @@
pkgs.nautilus
pkgs.gnome-control-center
pkgs.brightnessctl
- pkgs.swaync
];
@@ -61,6 +60,7 @@
gaps_in = 5;
gaps_out = 5;
border_size = 1;
+ "col.active_border" = "rgb(98971A) rgb(CC241D) 45deg";
layout = "master";
};
@@ -88,23 +88,32 @@
decoration = {
rounding = 5;
- active_opacity = 0.95;
+ # active_opacity = 0.95;
inactive_opacity = 0.9;
shadow = {
enabled = true;
range = 6;
render_power = 6;
- color = "#000000";
+ # color = "#000000";
};
- blur = {
- enabled = true;
- size = 4;
- passes = 2;
- new_optimizations = on;
- ignore_opacity = true;
- };
+ # set this on a per-program basis
+ # blur = {
+ # enabled = true;
+ # size = 4;
+ # passes = 2;
+ # new_optimizations = true;
+ # ignore_opacity = true;
+ # };
+ layerrule = [
+ "blur, wofi"
+ "ignorezero, wofi"
+ "ignorealpha 0.5, wofi"
+ "blur, kitty"
+ "ignorezero, kitty"
+ "ignorealpha 0.5, kitty"
+ ];
};
monitor = [
@@ -121,39 +130,6 @@
];
};
- # imports = [ inputs.hyprpanel.homeManagerModules.hyprpanel ];
- # # the overlay makes this available as a home manager module
- # programs.hyprpanel = {
- # enable = true;
- # # autostart after hyprland
- # hyprland.enable = true;
- # overwrite.enable = true;
- # overlay.enable = true;
-
- # theme = "monochrome";
-
- # settings = {
- # bar = {
- # clock.format = "%H:%M";
- # clock.showIcon = false;
- # launcher.icon = "🚀";
- # launcher.autoDetectIcon = true;
- # workspaces.show_icons = true;
- # };
- # };
-
- # layout = {
- # "bar.layouts" = {
- # "*" = {
- # left = ["workspaces"];
- # middle = ["clock"];
- # right = ["volume" "systray" "nm-applet" "notifications" ];
- # };
- # };
- # };
- # };
-
-
programs.walker = {
enable = true;
runAsService = true;
@@ -187,4 +163,36 @@
enable = true;
};
+ services.swaync.enable = true;
+
+
+ gtk = {
+ enable = true;
+ cursorTheme = {
+ package = pkgs.capitaine-cursors;
+ name = "capitaine-cursors-white";
+ size = 32;
+ };
+ iconTheme = {
+ name = "Papirus-Dark";
+ package = pkgs.papirus-icon-theme;
+ };
+ theme = {
+ name = "Materia-dark";
+ package = pkgs.materia-theme;
+ };
+ font = {
+ name = "Inter";
+ size = 11;
+ package = pkgs.inter;
+ };
+ };
+
+
+ home.pointerCursor = {
+ gtk.enable = true;
+ package = pkgs.capitaine-cursors;
+ name = "capitaine-cursors-white";
+ size = 32;
+ };
}
diff --git a/modules/home-manager/hypr/hyprpaper.nix b/modules/home-manager/hypr/hyprpaper.nix
index 087459c..c733853 100644
--- a/modules/home-manager/hypr/hyprpaper.nix
+++ b/modules/home-manager/hypr/hyprpaper.nix
@@ -5,7 +5,11 @@
services.hyprpaper = {
enable = true;
settings = {
- preload = builtins.attrValues (builtins.readDir ./wallpapers)
+ # TODO: implement this correctly
+ # preload = builtins.attrValues (builtins.readFile ../../../wallpapers/luke-chesser-eICUFSeirc0-unsplash.jpg);
+ # wallpaper = [
+ # ", ${builtins.attrValues (builtins.readFile ../../../wallpapers/luke-chesser-eICUFSeirc0-unsplash.jpg)}"
+ # ];
};
};
}
\ No newline at end of file
diff --git a/modules/home-manager/hypr/waybar.nix b/modules/home-manager/hypr/waybar.nix
index 8977fbe..286776f 100644
--- a/modules/home-manager/hypr/waybar.nix
+++ b/modules/home-manager/hypr/waybar.nix
@@ -1,103 +1,140 @@
{inputs, pkgs, ...}:
{
+ # required to autoload fonts from packages installed via Home Manager
+ fonts.fontconfig.enable = true;
+
# waybar requires font-awesome
home.packages = [
pkgs.font-awesome
+ pkgs.fira-code
];
# enable waybar
programs.waybar.enable = true;
- programs.waybar.settings = {
- mainBar = {
- layer = "top";
- position = "top";
- height = 30;
- # output = [
- # "eDP-1"
- # "HDMI-A-1"
- # ];
- modules-left = [
- "hyprland/workspaces"
- # "hyprland/mode"
- # "wlr/taskbar"
- ];
- modules-center = [
- "hyprland/window"
- "clock"
- # "custom/hello-from-waybar"
- ];
- modules-right = [
- "mpd"
- "tray"
- "custom/notification"
- # "temperature"
- "group/expand"
- "bluetooth"
- "network"
- "battery"
- ];
+ programs.waybar = {
+ settings = {
+
+ mainBar = {
+ margin-top = 5;
+ margin-bottom = 5;
+ margin-left = 5;
+ margin-right = 5;
+ height = 42;
+ layer = "top";
+ position = "top";
+ # height = 30;
+ # output = [
+ # "eDP-1"
+ # "HDMI-A-1"
+ # ];
+ modules-left = [
+ "hyprland/workspaces"
+ "hyprland/window"
- # module specific settings
- "hyprland/workspaces" = {
- "format" = "{icon}";
- "format-icons" = {
- "active" = "";
- "default" = "";
- "empty" = ""
- };
- };
- "custom/notification" = {
- "tooltip" = false;
- "format" = "";
- "on-click" = "swaync-client -t -sw";
- "escape" = true;
- };
- "clock": {
- "format" = "{:%I:%M}";
- "interval" = 1;
- "tooltip-format" = "{calendar}";
- "calendar" = {
- "format" = {
- "today" = "{}"
+ ];
+ modules-center = [
+ "clock"
+ ];
+ modules-right = [
+ "tray"
+ # "temperature"
+ "group/expand"
+ "bluetooth"
+ # "network"
+ "mpd"
+ "battery"
+ "backlight"
+ "custom/notification"
+ ];
+
+ # module specific settings
+ "hyprland/workspaces" = {
+ format = "{icon}";
+ format-icons = {
+ active = "";
+ default = "";
+ empty = "";
};
};
- };
-
- "network" = {
- "format-wifi" = "";
- "format-ethernet" ="";
- "format-disconnected" = "";
- "tooltip-format-disconnected" = "Error";
- "tooltip-format-wifi" = "{essid} ({signalStrength}%) ";
- "tooltip-format-ethernet" = "{ifname} 🖧 ";
- "on-click" = "kitty nmtui"
- };
- "bluetooth" = {
- "format-on" = "";
- "format-off" = "BT-off";
- "format-disabled" = "";
- "format-connected-battery" = "{device_battery_percentage}% ";
- "format-alt" = "{device_alias} ";
- "tooltip-format" = "{controller_alias}\t{controller_address}\n\n{num_connections} connected";
- "tooltip-format-connected" = "{controller_alias}\t{controller_address}\n\n{num_connections} connected\n\n{device_enumerate}";
- "tooltip-format-enumerate-connected" = "{device_alias}\n{device_address}";
- "tooltip-format-enumerate-connected-battery" = "{device_alias}\n{device_address}\n{device_battery_percentage}%";
- "on-click-right" = "blueman-manager";
- };
- "battery" = {
- "interval" = 60;
- "states" = {
- "good" = 80;
- "warning" = 30;
- "critical" = 10
+ "custom/notification" = {
+ tooltip = false;
+ format = "";
+ on-click = "swaync-client -t -sw";
+ escape = true;
+ };
+ "clock" = {
+ format = "{:%H:%M}";
+ interval = 1;
+ tooltip-format = "{calendar}";
+ calendar = {
+ "format" = {
+ "today" = "{}";
+ };
+ };
+ };
+
+ # "network" = {
+ # "format-wifi" = "";
+ # "format-ethernet" ="";
+ # "format-disconnected" = "";
+ # "tooltip-format-disconnected" = "Error";
+ # "tooltip-format-wifi" = "{essid} ({signalStrength}%) ";
+ # "tooltip-format-ethernet" = "{ifname} 🖧 ";
+ # "on-click" = "kitty nmtui";
+ # };
+ "bluetooth" = {
+ format-on = "";
+ format-off = "BT-off";
+ format-disabled = "";
+ format-connected-battery = "{device_battery_percentage}% ";
+ format-alt = "{device_alias} ";
+ tooltip-format = "{controller_alias}\t{controller_address}\n\n{num_connections} connected";
+ tooltip-format-connected = "{controller_alias}\t{controller_address}\n\n{num_connections} connected\n\n{device_enumerate}";
+ tooltip-format-enumerate-connected = "{device_alias}\n{device_address}";
+ tooltip-format-enumerate-connected-battery = "{device_alias}\n{device_address}\n{device_battery_percentage}%";
+ on-click-right = "blueman-manager";
+ };
+ "battery" = {
+ interval = 60;
+ states = {
+ good = 80;
+ warning = 30;
+ critical = 10;
+ };
+ format = "{capacity}% {icon}";
+ format-charging = "{capacity}% ";
+ format-plugged = "{capacity}% ";
+ format-alt = "{time} {icon}";
+ format-icons = [ "" "" "" "" "" "" ];
};
- "format" = "{capacity}% {icon}";
- "format-charging" = "{capacity}% ";
- "format-plugged" = "{capacity}% ";
- "format-alt" = "{time} {icon}";
- "format-icons" = [ "" "" "" "" "" "" ];
};
};
- }
-};
-
\ No newline at end of file
+
+ style = ''
+ * {
+ border: none;
+ border-radius: 5px;
+ padding: 0px 5px 0px 5px;
+ margin: 0px 5px 0px 5px;
+ font-size: 18px;
+ }
+ window#waybar {
+ background-color: transparent;
+ }
+ #workspaces button {
+ padding-left: 1px;
+ padding-right: 1px;
+ }
+ #workspaces {
+ padding-left: 1px;
+ padding-right: 1px;
+ }
+ '';
+ # font-family: ${font};
+ # font-weight: ${font_weight};
+ # opacity: ${opacity};
+ # font-size: ${font_size};
+
+ };
+}
+
\ No newline at end of file
diff --git a/modules/home-manager/kitty.nix b/modules/home-manager/kitty.nix
index c1f2cde..043aa46 100644
--- a/modules/home-manager/kitty.nix
+++ b/modules/home-manager/kitty.nix
@@ -9,8 +9,9 @@
cursor_trail = 3;
};
keybindings = {
- "ctrl+c" = "copy_to_clipboard";
- "ctrl+v" = "paste_from_clipboard";
+ # TODO - they should not overwrite default behaviour
+ # "ctrl+c" = "copy_to_clipboard";
+ # "ctrl+v" = "paste_from_clipboard";
};
};
diff --git a/modules/nixos/fonts.nix b/modules/nixos/fonts.nix
new file mode 100644
index 0000000..890fe39
--- /dev/null
+++ b/modules/nixos/fonts.nix
@@ -0,0 +1,11 @@
+{
+ config,
+ lib,
+ pkgs,
+ ...
+}:
+{
+ # from here on fonts are managed on a user level
+ fonts.fontDir.enable = true;
+ fonts.fontconfig.enable = true;
+}