attempt oren update to latest style
This commit is contained in:
parent
303afdceb6
commit
ef1eb99b46
14 changed files with 730 additions and 834 deletions
|
|
@ -1,170 +0,0 @@
|
||||||
{
|
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
pkgs,
|
|
||||||
hyprland,
|
|
||||||
hyprlandPkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
let
|
|
||||||
ccfg = import ../../config.nix;
|
|
||||||
cfg_path = [
|
|
||||||
ccfg.custom_config_key
|
|
||||||
"desktopEnvironment"
|
|
||||||
"hyprland"
|
|
||||||
];
|
|
||||||
cfg = lib.attrsets.getAttrFromPath cfg_path config;
|
|
||||||
in
|
|
||||||
with lib;
|
|
||||||
{
|
|
||||||
options =
|
|
||||||
{ }
|
|
||||||
// lib.attrsets.setAttrByPath cfg_path {
|
|
||||||
enable = lib.mkEnableOption "hyprland desktop environment";
|
|
||||||
terminalCommand = mkOption {
|
|
||||||
type = lib.types.str;
|
|
||||||
default = "foot";
|
|
||||||
description = "The terminal command to use.";
|
|
||||||
};
|
|
||||||
extraOptions = mkOption {
|
|
||||||
type = lib.types.attrs;
|
|
||||||
default = { };
|
|
||||||
description = "Extra options for Hyprland configuration.";
|
|
||||||
};
|
|
||||||
hyprpaperSettings = lib.mkOption {
|
|
||||||
type = lib.types.attrs;
|
|
||||||
default = { };
|
|
||||||
description = "Extra options for hyprpaper configuration.";
|
|
||||||
};
|
|
||||||
swaync = {
|
|
||||||
enable = lib.mkEnableOption "Enable Swaync (notification center for Hyprland)";
|
|
||||||
};
|
|
||||||
waybar = {
|
|
||||||
enable = lib.mkEnableOption "Enable Waybar (status bar for Hyprland)";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
config = lib.mkIf cfg.enable {
|
|
||||||
# Enable for all users
|
|
||||||
home-manager = {
|
|
||||||
sharedModules = [
|
|
||||||
hyprland.homeManagerModules.default
|
|
||||||
./home_manager
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
services.greetd = {
|
|
||||||
enable = true;
|
|
||||||
vt = 2;
|
|
||||||
settings = {
|
|
||||||
default_session = {
|
|
||||||
command = "${pkgs.greetd.tuigreet}/bin/tuigreet --time --remember --remember-session --cmd '${pkgs.dbus}/bin/dbus-run-session ${hyprlandPkgs.hyprland}/bin/Hyprland'";
|
|
||||||
user = "greeter";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
# Caps Lock as Escape for console/tty
|
|
||||||
console.useXkbConfig = true;
|
|
||||||
services.xserver.xkb = {
|
|
||||||
layout = "us";
|
|
||||||
options = "caps:escape";
|
|
||||||
};
|
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
|
||||||
wl-clipboard
|
|
||||||
wl-clip-persist
|
|
||||||
wofi # application launcher
|
|
||||||
nemo # file manager (x11)
|
|
||||||
# nautilus # file manager
|
|
||||||
feh # image viewer (x11)
|
|
||||||
# imv # image viewer
|
|
||||||
networkmanager # network management
|
|
||||||
upower # power management
|
|
||||||
brightnessctl # screen/keyboard brightness control
|
|
||||||
wireplumber # media session manager
|
|
||||||
libgtop # system monitor library
|
|
||||||
bluez # Bluetooth support
|
|
||||||
power-profiles-daemon # power profiles
|
|
||||||
grim
|
|
||||||
slurp
|
|
||||||
hyprpicker
|
|
||||||
grimblast # screenshot tool
|
|
||||||
wf-recorder # screen recording tool
|
|
||||||
btop # system monitor
|
|
||||||
];
|
|
||||||
|
|
||||||
services.blueman.enable = config.hardware.bluetooth.enable;
|
|
||||||
|
|
||||||
programs.hyprland = {
|
|
||||||
enable = true;
|
|
||||||
# xwayland.enable = false;
|
|
||||||
# withUWSM = true;
|
|
||||||
|
|
||||||
# set the flake package
|
|
||||||
package = hyprlandPkgs.hyprland;
|
|
||||||
# make sure to also set the portal package, so that they are in sync
|
|
||||||
# This is set below now in xdf portal directly so we can also add things like gtk
|
|
||||||
# portalPackage = hyprlandPkgs.xdg-desktop-portal-hyprland;
|
|
||||||
};
|
|
||||||
|
|
||||||
xdg.portal = {
|
|
||||||
enable = true;
|
|
||||||
extraPortals = lib.mkForce [
|
|
||||||
hyprlandPkgs.xdg-desktop-portal-hyprland
|
|
||||||
# hyprlandPkgs.xdg-desktop-portal-wlr
|
|
||||||
hyprlandPkgs.xdg-desktop-portal-gtk
|
|
||||||
];
|
|
||||||
config.common.default = [
|
|
||||||
"hyprland"
|
|
||||||
# "wlr"
|
|
||||||
"gtk"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
# Enable PipeWire + WirePlumber so xdg-desktop-portal can do screencast
|
|
||||||
services.pipewire = {
|
|
||||||
enable = true;
|
|
||||||
# Enable WirePlumber session manager via the pipewire module option
|
|
||||||
wireplumber = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
hardware.graphics = {
|
|
||||||
enable = true;
|
|
||||||
package = hyprlandPkgs.mesa;
|
|
||||||
# if you also want 32-bit support (e.g for Steam)
|
|
||||||
# enable32Bit = true;
|
|
||||||
package32 = hyprlandPkgs.pkgsi686Linux.mesa;
|
|
||||||
};
|
|
||||||
|
|
||||||
# Environment variables
|
|
||||||
environment.sessionVariables = {
|
|
||||||
GTK_THEME = "Adwaita:dark";
|
|
||||||
XDG_SESSION_TYPE = "wayland";
|
|
||||||
# XDG_CURRENT_DESKTOP = "sway";
|
|
||||||
# XDG_SESSION_DESKTOP = "sway";
|
|
||||||
# prefer EGL renderer (can be changed back to "auto" if needed)
|
|
||||||
WLR_RENDERER = "egl";
|
|
||||||
|
|
||||||
# Tell apps to run native wayland
|
|
||||||
NIXOS_OZONE_WL = "1";
|
|
||||||
ELECTRON_OZONE_PLATFORM_HINT = "wayland";
|
|
||||||
ELECTRON_ENABLE_WAYLAND = "1";
|
|
||||||
ELECTRON_DISABLE_SANDBOX = "0";
|
|
||||||
GDK_BACKEND = "wayland,x11"; # GTK
|
|
||||||
QT_QPA_PLATFORM = "wayland;xcb"; # Qt 5/6
|
|
||||||
MOZ_ENABLE_WAYLAND = "1"; # Firefox
|
|
||||||
SDL_VIDEODRIVER = "wayland"; # SDL apps/games
|
|
||||||
CLUTTER_BACKEND = "wayland";
|
|
||||||
};
|
|
||||||
|
|
||||||
# Qt theming
|
|
||||||
qt = {
|
|
||||||
enable = true;
|
|
||||||
platformTheme = "gtk2";
|
|
||||||
style = "adwaita-dark";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
inputs = {
|
inputs = {
|
||||||
ragenix.url = "github:yaxitech/ragenix";
|
hyprland.url = "github:hyprwm/Hyprland";
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs =
|
outputs =
|
||||||
|
|
@ -20,6 +20,7 @@
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
hyprland.nixosModules.default
|
hyprland.nixosModules.default
|
||||||
|
./hyprland.nix
|
||||||
];
|
];
|
||||||
config = {
|
config = {
|
||||||
_module.args = {
|
_module.args = {
|
||||||
|
|
|
||||||
|
|
@ -4,15 +4,6 @@
|
||||||
hyprlandPkgs,
|
hyprlandPkgs,
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
let
|
|
||||||
ccfg = import ../../../config.nix;
|
|
||||||
cfg_path = [
|
|
||||||
ccfg.custom_config_key
|
|
||||||
"desktopEnvironment"
|
|
||||||
"hyprland"
|
|
||||||
];
|
|
||||||
cfg = lib.attrsets.getAttrFromPath cfg_path osConfig;
|
|
||||||
in
|
|
||||||
{
|
{
|
||||||
wayland.windowManager.hyprland = {
|
wayland.windowManager.hyprland = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
@ -21,7 +12,7 @@ in
|
||||||
# hyprspace
|
# hyprspace
|
||||||
# ];
|
# ];
|
||||||
|
|
||||||
settings = lib.attrsets.recursiveUpdate {
|
settings = {
|
||||||
# Debug logs enabled when this is uncommented
|
# Debug logs enabled when this is uncommented
|
||||||
debug.disable_logs = false;
|
debug.disable_logs = false;
|
||||||
debug.disable_time = false;
|
debug.disable_time = false;
|
||||||
|
|
@ -89,7 +80,7 @@ in
|
||||||
|
|
||||||
bind = [
|
bind = [
|
||||||
# Applications
|
# Applications
|
||||||
"$mainMod, Return, exec, ${cfg.terminalCommand}"
|
"$mainMod, Return, exec, foot"
|
||||||
"$mainMod, Space, exec, pkill wofi || wofi --show drun"
|
"$mainMod, Space, exec, pkill wofi || wofi --show drun"
|
||||||
"$mainMod, q, killactive"
|
"$mainMod, q, killactive"
|
||||||
"$mainMod SHIFT, escape, exit"
|
"$mainMod SHIFT, escape, exit"
|
||||||
|
|
@ -171,6 +162,6 @@ in
|
||||||
"$mainMod, mouse:273, resizewindow"
|
"$mainMod, mouse:273, resizewindow"
|
||||||
];
|
];
|
||||||
|
|
||||||
} cfg.extraOptions;
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,22 +1,8 @@
|
||||||
{
|
{
|
||||||
osConfig,
|
|
||||||
lib,
|
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
let
|
|
||||||
ccfg = import ../../../config.nix;
|
|
||||||
cfg_path = [
|
|
||||||
ccfg.custom_config_key
|
|
||||||
"desktopEnvironment"
|
|
||||||
"hyprland"
|
|
||||||
];
|
|
||||||
cfg = lib.attrsets.getAttrFromPath cfg_path osConfig;
|
|
||||||
in
|
|
||||||
{
|
{
|
||||||
config = {
|
services.hyprpaper = {
|
||||||
services.hyprpaper = {
|
enable = true;
|
||||||
enable = true;
|
|
||||||
settings = cfg.hyprpaperSettings;
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,19 +1,8 @@
|
||||||
{
|
{
|
||||||
osConfig,
|
|
||||||
lib,
|
|
||||||
pkgs,
|
pkgs,
|
||||||
upkgs,
|
upkgs,
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
let
|
|
||||||
ccfg = import ../../../config.nix;
|
|
||||||
cfg_path = [
|
|
||||||
ccfg.custom_config_key
|
|
||||||
"desktopEnvironment"
|
|
||||||
"hyprland"
|
|
||||||
];
|
|
||||||
cfg = lib.attrsets.getAttrFromPath cfg_path osConfig;
|
|
||||||
in
|
|
||||||
{
|
{
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
upkgs.quickshell
|
upkgs.quickshell
|
||||||
|
|
|
||||||
|
|
@ -1,251 +1,237 @@
|
||||||
{
|
{
|
||||||
lib,
|
|
||||||
osConfig,
|
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
let
|
|
||||||
ccfg = import ../../../config.nix;
|
|
||||||
cfg_path = [
|
|
||||||
ccfg.custom_config_key
|
|
||||||
"desktopEnvironment"
|
|
||||||
"hyprland"
|
|
||||||
"swaync"
|
|
||||||
];
|
|
||||||
cfg = lib.attrsets.getAttrFromPath cfg_path osConfig;
|
|
||||||
in
|
|
||||||
{
|
{
|
||||||
config = lib.mkIf cfg.enable {
|
services.swaync = {
|
||||||
services.swaync = {
|
enable = true;
|
||||||
enable = true;
|
settings = {
|
||||||
settings = {
|
ignore = [
|
||||||
ignore = [
|
"com.spotify.Client"
|
||||||
"com.spotify.Client"
|
];
|
||||||
];
|
|
||||||
|
|
||||||
positionX = "right";
|
positionX = "right";
|
||||||
positionY = "top";
|
positionY = "top";
|
||||||
layer = "overlay";
|
layer = "overlay";
|
||||||
control-center-layer = "top";
|
control-center-layer = "top";
|
||||||
layer-shell = true;
|
layer-shell = true;
|
||||||
cssPriority = "application";
|
cssPriority = "application";
|
||||||
|
|
||||||
control-center-margin-top = 0;
|
control-center-margin-top = 0;
|
||||||
control-center-margin-bottom = 0;
|
control-center-margin-bottom = 0;
|
||||||
control-center-margin-right = 0;
|
control-center-margin-right = 0;
|
||||||
control-center-margin-left = 0;
|
control-center-margin-left = 0;
|
||||||
|
|
||||||
notification-2fa-action = true;
|
notification-2fa-action = true;
|
||||||
notification-inline-replies = false;
|
notification-inline-replies = false;
|
||||||
notification-icon-size = 64;
|
notification-icon-size = 64;
|
||||||
notification-body-image-height = 100;
|
notification-body-image-height = 100;
|
||||||
notification-body-image-width = 200;
|
notification-body-image-width = 200;
|
||||||
|
|
||||||
timeout = 10;
|
timeout = 10;
|
||||||
timeout-low = 5;
|
timeout-low = 5;
|
||||||
timeout-critical = 0;
|
timeout-critical = 0;
|
||||||
|
|
||||||
control-center-width = 500;
|
control-center-width = 500;
|
||||||
control-center-height = 600;
|
control-center-height = 600;
|
||||||
notification-window-width = 500;
|
notification-window-width = 500;
|
||||||
|
|
||||||
keyboard-shortcuts = true;
|
keyboard-shortcuts = true;
|
||||||
image-visibility = "when-available";
|
image-visibility = "when-available";
|
||||||
transition-time = 200;
|
transition-time = 200;
|
||||||
hide-on-clear = false;
|
hide-on-clear = false;
|
||||||
hide-on-action = true;
|
hide-on-action = true;
|
||||||
script-fail-notify = true;
|
script-fail-notify = true;
|
||||||
|
|
||||||
widgets = [
|
widgets = [
|
||||||
"inhibitors"
|
"inhibitors"
|
||||||
"title"
|
"title"
|
||||||
"dnd"
|
"dnd"
|
||||||
"volume"
|
"volume"
|
||||||
"backlight"
|
"backlight"
|
||||||
"mpris"
|
"mpris"
|
||||||
"buttons-grid#quick"
|
"buttons-grid#quick"
|
||||||
"notifications"
|
"notifications"
|
||||||
];
|
];
|
||||||
|
|
||||||
# Widget configurations
|
# Widget configurations
|
||||||
widget-config = {
|
widget-config = {
|
||||||
inhibitors = {
|
inhibitors = {
|
||||||
text = "Inhibitors";
|
text = "Inhibitors";
|
||||||
button-text = "Clear All";
|
button-text = "Clear All";
|
||||||
clear-all-button = true;
|
clear-all-button = true;
|
||||||
};
|
};
|
||||||
title = {
|
title = {
|
||||||
text = "Notifications";
|
text = "Notifications";
|
||||||
clear-all-button = true;
|
clear-all-button = true;
|
||||||
button-text = "Clear All";
|
button-text = "Clear All";
|
||||||
};
|
};
|
||||||
dnd.text = "Do Not Disturb";
|
dnd.text = "Do Not Disturb";
|
||||||
mpris = {
|
mpris = {
|
||||||
image-size = 96;
|
image-size = 96;
|
||||||
image-radius = 12;
|
image-radius = 12;
|
||||||
};
|
};
|
||||||
volume = {
|
volume = {
|
||||||
label = "";
|
label = "";
|
||||||
show-per-app = true;
|
show-per-app = true;
|
||||||
};
|
};
|
||||||
backlight = {
|
backlight = {
|
||||||
label = "";
|
label = "";
|
||||||
device = "intel_backlight";
|
device = "intel_backlight";
|
||||||
};
|
};
|
||||||
"buttons-grid#quick" = {
|
"buttons-grid#quick" = {
|
||||||
columns = 4; # adjust: 3/4/5
|
columns = 4; # adjust: 3/4/5
|
||||||
icon-size = 20; # tweak to taste
|
icon-size = 20; # tweak to taste
|
||||||
actions = [
|
actions = [
|
||||||
# Power
|
# Power
|
||||||
{
|
{
|
||||||
label = "";
|
label = "";
|
||||||
tooltip = "Shutdown";
|
tooltip = "Shutdown";
|
||||||
command = "confirm-action 'systemctl poweroff' 'Shutdown?'";
|
command = "confirm-action 'systemctl poweroff' 'Shutdown?'";
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
label = "";
|
label = "";
|
||||||
tooltip = "Reboot";
|
tooltip = "Reboot";
|
||||||
command = "confirm-action 'systemctl reboot' 'Reboot?'";
|
command = "confirm-action 'systemctl reboot' 'Reboot?'";
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
label = "";
|
label = "";
|
||||||
tooltip = "Logout";
|
tooltip = "Logout";
|
||||||
command = "confirm-action 'hyprctl dispatch exit' 'Logout?'";
|
command = "confirm-action 'hyprctl dispatch exit' 'Logout?'";
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
};
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
# Custom CSS for the control center
|
|
||||||
style = ''
|
|
||||||
.control-center {
|
|
||||||
background: #1a1b26;
|
|
||||||
border: 2px solid #7dcae4;
|
|
||||||
border-radius: 12px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.control-center-list {
|
|
||||||
background: transparent;
|
|
||||||
}
|
|
||||||
|
|
||||||
.control-center .notification-row:focus,
|
|
||||||
.control-center .notification-row:hover {
|
|
||||||
opacity: 1;
|
|
||||||
background: #24283b;
|
|
||||||
}
|
|
||||||
|
|
||||||
.notification {
|
|
||||||
border-radius: 8px;
|
|
||||||
margin: 6px 12px;
|
|
||||||
box-shadow: 0 0 0 1px rgba(125, 196, 228, 0.3), 0 1px 3px 1px rgba(0, 0, 0, 0.7), 0 2px 6px 2px rgba(0, 0, 0, 0.3);
|
|
||||||
padding: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Widget styling */
|
|
||||||
.widget-title {
|
|
||||||
margin: 8px;
|
|
||||||
font-size: 1.5rem;
|
|
||||||
color: #c0caf5;
|
|
||||||
}
|
|
||||||
|
|
||||||
.widget-dnd {
|
|
||||||
margin: 8px;
|
|
||||||
font-size: 1.1rem;
|
|
||||||
color: #c0caf5;
|
|
||||||
}
|
|
||||||
|
|
||||||
.widget-dnd > switch {
|
|
||||||
font-size: initial;
|
|
||||||
border-radius: 8px;
|
|
||||||
background: #414868;
|
|
||||||
border: 1px solid #7dcae4;
|
|
||||||
}
|
|
||||||
|
|
||||||
.widget-dnd > switch:checked {
|
|
||||||
background: #7dcae4;
|
|
||||||
}
|
|
||||||
|
|
||||||
.widget-mpris {
|
|
||||||
color: #c0caf5;
|
|
||||||
background: #24283b;
|
|
||||||
padding: 8px;
|
|
||||||
margin: 8px;
|
|
||||||
border-radius: 8px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.widget-mpris-player {
|
|
||||||
padding: 8px;
|
|
||||||
margin: 8px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.widget-mpris-title {
|
|
||||||
font-weight: bold;
|
|
||||||
font-size: 1.25rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.widget-mpris-subtitle {
|
|
||||||
font-size: 1.1rem;
|
|
||||||
color: #9ece6a;
|
|
||||||
}
|
|
||||||
|
|
||||||
.widget-volume {
|
|
||||||
background: #24283b;
|
|
||||||
padding: 8px;
|
|
||||||
margin: 8px;
|
|
||||||
border-radius: 8px;
|
|
||||||
color: #c0caf5;
|
|
||||||
}
|
|
||||||
|
|
||||||
.widget-backlight {
|
|
||||||
background: #24283b;
|
|
||||||
padding: 8px;
|
|
||||||
margin: 8px;
|
|
||||||
border-radius: 8px;
|
|
||||||
color: #c0caf5;
|
|
||||||
}
|
|
||||||
|
|
||||||
.widget-menubar {
|
|
||||||
background: #24283b;
|
|
||||||
padding: 8px;
|
|
||||||
margin: 8px;
|
|
||||||
border-radius: 8px;
|
|
||||||
color: #c0caf5;
|
|
||||||
}
|
|
||||||
|
|
||||||
.widget-menubar .menu-item button {
|
|
||||||
background: #1f2335;
|
|
||||||
color: #c0caf5;
|
|
||||||
border-radius: 8px;
|
|
||||||
padding: 6px 10px;
|
|
||||||
margin: 4px;
|
|
||||||
border: 1px solid #2e3440;
|
|
||||||
font-family: "JetBrainsMonoNL Nerd Font";
|
|
||||||
}
|
|
||||||
|
|
||||||
.widget-menubar .menu-item button:hover {
|
|
||||||
background: #414868;
|
|
||||||
border-color: #7dcae4;
|
|
||||||
}
|
|
||||||
|
|
||||||
.topbar-buttons button {
|
|
||||||
border: none;
|
|
||||||
background: transparent;
|
|
||||||
color: #c0caf5;
|
|
||||||
font-size: 1.1rem;
|
|
||||||
border-radius: 8px;
|
|
||||||
margin: 0 4px;
|
|
||||||
padding: 8px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.topbar-buttons button:hover {
|
|
||||||
background: #414868;
|
|
||||||
}
|
|
||||||
|
|
||||||
.topbar-buttons button:active {
|
|
||||||
background: #7dcae4;
|
|
||||||
color: #1a1b26;
|
|
||||||
}
|
|
||||||
'';
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# Custom CSS for the control center
|
||||||
|
style = ''
|
||||||
|
.control-center {
|
||||||
|
background: #1a1b26;
|
||||||
|
border: 2px solid #7dcae4;
|
||||||
|
border-radius: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.control-center-list {
|
||||||
|
background: transparent;
|
||||||
|
}
|
||||||
|
|
||||||
|
.control-center .notification-row:focus,
|
||||||
|
.control-center .notification-row:hover {
|
||||||
|
opacity: 1;
|
||||||
|
background: #24283b;
|
||||||
|
}
|
||||||
|
|
||||||
|
.notification {
|
||||||
|
border-radius: 8px;
|
||||||
|
margin: 6px 12px;
|
||||||
|
box-shadow: 0 0 0 1px rgba(125, 196, 228, 0.3), 0 1px 3px 1px rgba(0, 0, 0, 0.7), 0 2px 6px 2px rgba(0, 0, 0, 0.3);
|
||||||
|
padding: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Widget styling */
|
||||||
|
.widget-title {
|
||||||
|
margin: 8px;
|
||||||
|
font-size: 1.5rem;
|
||||||
|
color: #c0caf5;
|
||||||
|
}
|
||||||
|
|
||||||
|
.widget-dnd {
|
||||||
|
margin: 8px;
|
||||||
|
font-size: 1.1rem;
|
||||||
|
color: #c0caf5;
|
||||||
|
}
|
||||||
|
|
||||||
|
.widget-dnd > switch {
|
||||||
|
font-size: initial;
|
||||||
|
border-radius: 8px;
|
||||||
|
background: #414868;
|
||||||
|
border: 1px solid #7dcae4;
|
||||||
|
}
|
||||||
|
|
||||||
|
.widget-dnd > switch:checked {
|
||||||
|
background: #7dcae4;
|
||||||
|
}
|
||||||
|
|
||||||
|
.widget-mpris {
|
||||||
|
color: #c0caf5;
|
||||||
|
background: #24283b;
|
||||||
|
padding: 8px;
|
||||||
|
margin: 8px;
|
||||||
|
border-radius: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.widget-mpris-player {
|
||||||
|
padding: 8px;
|
||||||
|
margin: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.widget-mpris-title {
|
||||||
|
font-weight: bold;
|
||||||
|
font-size: 1.25rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.widget-mpris-subtitle {
|
||||||
|
font-size: 1.1rem;
|
||||||
|
color: #9ece6a;
|
||||||
|
}
|
||||||
|
|
||||||
|
.widget-volume {
|
||||||
|
background: #24283b;
|
||||||
|
padding: 8px;
|
||||||
|
margin: 8px;
|
||||||
|
border-radius: 8px;
|
||||||
|
color: #c0caf5;
|
||||||
|
}
|
||||||
|
|
||||||
|
.widget-backlight {
|
||||||
|
background: #24283b;
|
||||||
|
padding: 8px;
|
||||||
|
margin: 8px;
|
||||||
|
border-radius: 8px;
|
||||||
|
color: #c0caf5;
|
||||||
|
}
|
||||||
|
|
||||||
|
.widget-menubar {
|
||||||
|
background: #24283b;
|
||||||
|
padding: 8px;
|
||||||
|
margin: 8px;
|
||||||
|
border-radius: 8px;
|
||||||
|
color: #c0caf5;
|
||||||
|
}
|
||||||
|
|
||||||
|
.widget-menubar .menu-item button {
|
||||||
|
background: #1f2335;
|
||||||
|
color: #c0caf5;
|
||||||
|
border-radius: 8px;
|
||||||
|
padding: 6px 10px;
|
||||||
|
margin: 4px;
|
||||||
|
border: 1px solid #2e3440;
|
||||||
|
font-family: "JetBrainsMonoNL Nerd Font";
|
||||||
|
}
|
||||||
|
|
||||||
|
.widget-menubar .menu-item button:hover {
|
||||||
|
background: #414868;
|
||||||
|
border-color: #7dcae4;
|
||||||
|
}
|
||||||
|
|
||||||
|
.topbar-buttons button {
|
||||||
|
border: none;
|
||||||
|
background: transparent;
|
||||||
|
color: #c0caf5;
|
||||||
|
font-size: 1.1rem;
|
||||||
|
border-radius: 8px;
|
||||||
|
margin: 0 4px;
|
||||||
|
padding: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.topbar-buttons button:hover {
|
||||||
|
background: #414868;
|
||||||
|
}
|
||||||
|
|
||||||
|
.topbar-buttons button:active {
|
||||||
|
background: #7dcae4;
|
||||||
|
color: #1a1b26;
|
||||||
|
}
|
||||||
|
'';
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,18 +0,0 @@
|
||||||
{
|
|
||||||
osConfig,
|
|
||||||
lib,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
let
|
|
||||||
ccfg = import ../../../config.nix;
|
|
||||||
cfg_path = [
|
|
||||||
ccfg.custom_config_key
|
|
||||||
"desktopEnvironment"
|
|
||||||
"hyprland"
|
|
||||||
];
|
|
||||||
cfg = lib.attrsets.getAttrFromPath cfg_path osConfig;
|
|
||||||
in
|
|
||||||
{
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,258 +1,245 @@
|
||||||
{ lib, osConfig, ... }:
|
{ lib, ... }:
|
||||||
let
|
|
||||||
ccfg = import ../../../config.nix;
|
|
||||||
cfg_path = [
|
|
||||||
ccfg.custom_config_key
|
|
||||||
"desktopEnvironment"
|
|
||||||
"hyprland"
|
|
||||||
"waybar"
|
|
||||||
];
|
|
||||||
cfg = lib.attrsets.getAttrFromPath cfg_path osConfig;
|
|
||||||
in
|
|
||||||
{
|
{
|
||||||
config = lib.mkIf cfg.enable {
|
programs.waybar = {
|
||||||
|
enable = true;
|
||||||
|
systemd.enable = true;
|
||||||
|
settings = {
|
||||||
|
mainBar = {
|
||||||
|
layer = "top";
|
||||||
|
position = "top";
|
||||||
|
height = 28;
|
||||||
|
spacing = 6;
|
||||||
|
margin-top = 0;
|
||||||
|
margin-bottom = 0;
|
||||||
|
margin-left = 10;
|
||||||
|
margin-right = 10;
|
||||||
|
|
||||||
programs.waybar = {
|
modules-left = [
|
||||||
enable = true;
|
"hyprland/workspaces"
|
||||||
systemd.enable = true;
|
];
|
||||||
settings = {
|
modules-center = [
|
||||||
mainBar = {
|
"clock"
|
||||||
layer = "top";
|
"temperature"
|
||||||
position = "top";
|
"cpu"
|
||||||
height = 28;
|
"memory"
|
||||||
spacing = 6;
|
"disk"
|
||||||
margin-top = 0;
|
];
|
||||||
margin-bottom = 0;
|
modules-right = [
|
||||||
margin-left = 10;
|
"battery"
|
||||||
margin-right = 10;
|
"battery#bat2"
|
||||||
|
"pulseaudio"
|
||||||
|
"network"
|
||||||
|
"bluetooth"
|
||||||
|
"power-profiles-daemon"
|
||||||
|
"backlight"
|
||||||
|
"custom/notifications"
|
||||||
|
"tray"
|
||||||
|
"custom/power"
|
||||||
|
];
|
||||||
|
|
||||||
modules-left = [
|
"hyprland/workspaces" = {
|
||||||
"hyprland/workspaces"
|
format = "{icon}";
|
||||||
];
|
format-icons = {
|
||||||
modules-center = [
|
"1" = "一";
|
||||||
"clock"
|
"2" = "二";
|
||||||
"temperature"
|
"3" = "三";
|
||||||
"cpu"
|
"4" = "四";
|
||||||
"memory"
|
"5" = "五";
|
||||||
"disk"
|
"6" = "六";
|
||||||
];
|
"7" = "七";
|
||||||
modules-right = [
|
"8" = "八";
|
||||||
"battery"
|
"9" = "九";
|
||||||
"battery#bat2"
|
"10" = "十";
|
||||||
"pulseaudio"
|
"11" = "十一";
|
||||||
"network"
|
"12" = "十二";
|
||||||
"bluetooth"
|
"13" = "十三";
|
||||||
"power-profiles-daemon"
|
"14" = "十四";
|
||||||
"backlight"
|
"15" = "十五";
|
||||||
"custom/notifications"
|
"16" = "十六";
|
||||||
"tray"
|
"17" = "十七";
|
||||||
"custom/power"
|
"18" = "十八";
|
||||||
];
|
"19" = "十九";
|
||||||
|
"20" = "二十";
|
||||||
"hyprland/workspaces" = {
|
|
||||||
format = "{icon}";
|
|
||||||
format-icons = {
|
|
||||||
"1" = "一";
|
|
||||||
"2" = "二";
|
|
||||||
"3" = "三";
|
|
||||||
"4" = "四";
|
|
||||||
"5" = "五";
|
|
||||||
"6" = "六";
|
|
||||||
"7" = "七";
|
|
||||||
"8" = "八";
|
|
||||||
"9" = "九";
|
|
||||||
"10" = "十";
|
|
||||||
"11" = "十一";
|
|
||||||
"12" = "十二";
|
|
||||||
"13" = "十三";
|
|
||||||
"14" = "十四";
|
|
||||||
"15" = "十五";
|
|
||||||
"16" = "十六";
|
|
||||||
"17" = "十七";
|
|
||||||
"18" = "十八";
|
|
||||||
"19" = "十九";
|
|
||||||
"20" = "二十";
|
|
||||||
};
|
|
||||||
disable-scroll = false;
|
|
||||||
};
|
};
|
||||||
|
disable-scroll = false;
|
||||||
# CENTER
|
|
||||||
clock = {
|
|
||||||
format = "{:%b %d, %H:%M}";
|
|
||||||
tooltip-format = "<big>{:%Y %B}</big>\n<tt><small>{calendar}</small></tt>";
|
|
||||||
};
|
|
||||||
|
|
||||||
temperature = {
|
|
||||||
thermal-zone = 2;
|
|
||||||
hwmon-path = "/sys/class/hwmon/hwmon2/temp1_input";
|
|
||||||
critical-threshold = 80;
|
|
||||||
format-critical = " {temperatureC}°C";
|
|
||||||
format = " {temperatureC}°C";
|
|
||||||
};
|
|
||||||
|
|
||||||
cpu = {
|
|
||||||
format = " {usage}%";
|
|
||||||
tooltip = true;
|
|
||||||
on-click = "btop";
|
|
||||||
};
|
|
||||||
|
|
||||||
memory = {
|
|
||||||
format = " {}%";
|
|
||||||
on-click = "btop";
|
|
||||||
};
|
|
||||||
|
|
||||||
disk = {
|
|
||||||
interval = 30;
|
|
||||||
format = " {percentage_used}%";
|
|
||||||
path = "/";
|
|
||||||
on-click = "btop";
|
|
||||||
};
|
|
||||||
|
|
||||||
# RIGHT
|
|
||||||
"battery" = {
|
|
||||||
"states" = {
|
|
||||||
# "good"= 95;
|
|
||||||
"warning" = 30;
|
|
||||||
"critical" = 15;
|
|
||||||
};
|
|
||||||
"format" = "{capacity}% {icon}";
|
|
||||||
"format-full" = "{capacity}% {icon}";
|
|
||||||
"format-charging" = "{capacity}% ";
|
|
||||||
"format-plugged" = "{capacity}% ";
|
|
||||||
"format-alt" = "{time} {icon}";
|
|
||||||
# "format-good"= ""; // An empty format will hide the module
|
|
||||||
# "format-full"= "";
|
|
||||||
"format-icons" = [
|
|
||||||
""
|
|
||||||
""
|
|
||||||
""
|
|
||||||
""
|
|
||||||
""
|
|
||||||
];
|
|
||||||
};
|
|
||||||
"battery#bat2" = {
|
|
||||||
"bat" = "BAT2";
|
|
||||||
};
|
|
||||||
|
|
||||||
pulseaudio = {
|
|
||||||
format = "{icon} {volume}%";
|
|
||||||
format-bluetooth = " {volume}%";
|
|
||||||
format-bluetooth-muted = " ";
|
|
||||||
format-muted = " ";
|
|
||||||
format-source = " {volume}%";
|
|
||||||
format-source-muted = " ";
|
|
||||||
format-icons = {
|
|
||||||
headphone = "";
|
|
||||||
hands-free = "";
|
|
||||||
headset = "";
|
|
||||||
phone = "";
|
|
||||||
portable = "";
|
|
||||||
car = "";
|
|
||||||
default = [
|
|
||||||
""
|
|
||||||
""
|
|
||||||
""
|
|
||||||
];
|
|
||||||
};
|
|
||||||
scroll-step = 5;
|
|
||||||
on-click = "pavucontrol";
|
|
||||||
on-click-right = "wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle";
|
|
||||||
};
|
|
||||||
|
|
||||||
network = {
|
|
||||||
format-wifi = " {essid} ({signalStrength}%)";
|
|
||||||
format-ethernet = " {ipaddr}/{cidr}";
|
|
||||||
tooltip-format = "{ifname} via {gwaddr} ";
|
|
||||||
format-linked = " {ifname} (No IP)";
|
|
||||||
format-disconnected = " Disconnected";
|
|
||||||
# on-click = "wofi-wifi-menu";
|
|
||||||
# on-click-right = "nmcli radio wifi toggle";
|
|
||||||
};
|
|
||||||
|
|
||||||
bluetooth = {
|
|
||||||
format = " {status}";
|
|
||||||
format-connected = " {device_alias}";
|
|
||||||
format-connected-battery = " {device_alias} {device_battery_percentage}%";
|
|
||||||
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}\t{device_address}";
|
|
||||||
tooltip-format-enumerate-connected-battery = "{device_alias}\t{device_address}\t{device_battery_percentage}%";
|
|
||||||
# on-click = "wofi-bluetooth-menu";
|
|
||||||
# on-click-right = "bluetoothctl power toggle";
|
|
||||||
};
|
|
||||||
|
|
||||||
"power-profiles-daemon" = {
|
|
||||||
format = "{icon}";
|
|
||||||
"tooltip-format" = "Power profile: {profile}\nDriver: {driver}";
|
|
||||||
tooltip = true;
|
|
||||||
"format-icons" = {
|
|
||||||
default = "";
|
|
||||||
performance = "";
|
|
||||||
balanced = "";
|
|
||||||
"power-saver" = "";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
backlight = {
|
|
||||||
format = "{percent}% {icon}";
|
|
||||||
"format-icons" = [
|
|
||||||
""
|
|
||||||
""
|
|
||||||
""
|
|
||||||
""
|
|
||||||
""
|
|
||||||
""
|
|
||||||
""
|
|
||||||
""
|
|
||||||
""
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
"custom/notifications" = {
|
|
||||||
format = "{icon} {}";
|
|
||||||
format-icons = {
|
|
||||||
notification = "";
|
|
||||||
none = "";
|
|
||||||
dnd-notification = "";
|
|
||||||
dnd-none = "";
|
|
||||||
inhibited-notification = "";
|
|
||||||
inhibited-none = "";
|
|
||||||
dnd-inhibited-notification = "";
|
|
||||||
dnd-inhibited-none = "";
|
|
||||||
};
|
|
||||||
return-type = "json";
|
|
||||||
exec-if = "which swaync-client";
|
|
||||||
exec = "swaync-client -swb";
|
|
||||||
on-click = "swaync-client -t -sw";
|
|
||||||
on-click-right = "swaync-client -d -sw";
|
|
||||||
escape = true;
|
|
||||||
tooltip = false;
|
|
||||||
};
|
|
||||||
|
|
||||||
"sway/language" = {
|
|
||||||
format = "{}";
|
|
||||||
};
|
|
||||||
|
|
||||||
"tray" = {
|
|
||||||
"spacing" = 10;
|
|
||||||
};
|
|
||||||
|
|
||||||
"custom/power" = {
|
|
||||||
format = "⏻ ";
|
|
||||||
tooltip = false;
|
|
||||||
menu = "on-click";
|
|
||||||
"menu-file" = ./waybar/power_menu.xml;
|
|
||||||
"menu-actions" = {
|
|
||||||
shutdown = "shutdown 0";
|
|
||||||
reboot = "reboot";
|
|
||||||
logout = "loginctl terminate-session $(loginctl list-sessions | grep seat0 | awk '{print $1}')";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
};
|
};
|
||||||
};
|
|
||||||
|
|
||||||
style = builtins.readFile ./waybar/waybar.css;
|
# CENTER
|
||||||
|
clock = {
|
||||||
|
format = "{:%b %d, %H:%M}";
|
||||||
|
tooltip-format = "<big>{:%Y %B}</big>\n<tt><small>{calendar}</small></tt>";
|
||||||
|
};
|
||||||
|
|
||||||
|
temperature = {
|
||||||
|
thermal-zone = 2;
|
||||||
|
hwmon-path = "/sys/class/hwmon/hwmon2/temp1_input";
|
||||||
|
critical-threshold = 80;
|
||||||
|
format-critical = " {temperatureC}°C";
|
||||||
|
format = " {temperatureC}°C";
|
||||||
|
};
|
||||||
|
|
||||||
|
cpu = {
|
||||||
|
format = " {usage}%";
|
||||||
|
tooltip = true;
|
||||||
|
on-click = "btop";
|
||||||
|
};
|
||||||
|
|
||||||
|
memory = {
|
||||||
|
format = " {}%";
|
||||||
|
on-click = "btop";
|
||||||
|
};
|
||||||
|
|
||||||
|
disk = {
|
||||||
|
interval = 30;
|
||||||
|
format = " {percentage_used}%";
|
||||||
|
path = "/";
|
||||||
|
on-click = "btop";
|
||||||
|
};
|
||||||
|
|
||||||
|
# RIGHT
|
||||||
|
"battery" = {
|
||||||
|
"states" = {
|
||||||
|
# "good"= 95;
|
||||||
|
"warning" = 30;
|
||||||
|
"critical" = 15;
|
||||||
|
};
|
||||||
|
"format" = "{capacity}% {icon}";
|
||||||
|
"format-full" = "{capacity}% {icon}";
|
||||||
|
"format-charging" = "{capacity}% ";
|
||||||
|
"format-plugged" = "{capacity}% ";
|
||||||
|
"format-alt" = "{time} {icon}";
|
||||||
|
# "format-good"= ""; // An empty format will hide the module
|
||||||
|
# "format-full"= "";
|
||||||
|
"format-icons" = [
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
];
|
||||||
|
};
|
||||||
|
"battery#bat2" = {
|
||||||
|
"bat" = "BAT2";
|
||||||
|
};
|
||||||
|
|
||||||
|
pulseaudio = {
|
||||||
|
format = "{icon} {volume}%";
|
||||||
|
format-bluetooth = " {volume}%";
|
||||||
|
format-bluetooth-muted = " ";
|
||||||
|
format-muted = " ";
|
||||||
|
format-source = " {volume}%";
|
||||||
|
format-source-muted = " ";
|
||||||
|
format-icons = {
|
||||||
|
headphone = "";
|
||||||
|
hands-free = "";
|
||||||
|
headset = "";
|
||||||
|
phone = "";
|
||||||
|
portable = "";
|
||||||
|
car = "";
|
||||||
|
default = [
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
];
|
||||||
|
};
|
||||||
|
scroll-step = 5;
|
||||||
|
on-click = "pavucontrol";
|
||||||
|
on-click-right = "wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle";
|
||||||
|
};
|
||||||
|
|
||||||
|
network = {
|
||||||
|
format-wifi = " {essid} ({signalStrength}%)";
|
||||||
|
format-ethernet = " {ipaddr}/{cidr}";
|
||||||
|
tooltip-format = "{ifname} via {gwaddr} ";
|
||||||
|
format-linked = " {ifname} (No IP)";
|
||||||
|
format-disconnected = " Disconnected";
|
||||||
|
# on-click = "wofi-wifi-menu";
|
||||||
|
# on-click-right = "nmcli radio wifi toggle";
|
||||||
|
};
|
||||||
|
|
||||||
|
bluetooth = {
|
||||||
|
format = " {status}";
|
||||||
|
format-connected = " {device_alias}";
|
||||||
|
format-connected-battery = " {device_alias} {device_battery_percentage}%";
|
||||||
|
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}\t{device_address}";
|
||||||
|
tooltip-format-enumerate-connected-battery = "{device_alias}\t{device_address}\t{device_battery_percentage}%";
|
||||||
|
# on-click = "wofi-bluetooth-menu";
|
||||||
|
# on-click-right = "bluetoothctl power toggle";
|
||||||
|
};
|
||||||
|
|
||||||
|
"power-profiles-daemon" = {
|
||||||
|
format = "{icon}";
|
||||||
|
"tooltip-format" = "Power profile: {profile}\nDriver: {driver}";
|
||||||
|
tooltip = true;
|
||||||
|
"format-icons" = {
|
||||||
|
default = "";
|
||||||
|
performance = "";
|
||||||
|
balanced = "";
|
||||||
|
"power-saver" = "";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
backlight = {
|
||||||
|
format = "{percent}% {icon}";
|
||||||
|
"format-icons" = [
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
"custom/notifications" = {
|
||||||
|
format = "{icon} {}";
|
||||||
|
format-icons = {
|
||||||
|
notification = "";
|
||||||
|
none = "";
|
||||||
|
dnd-notification = "";
|
||||||
|
dnd-none = "";
|
||||||
|
inhibited-notification = "";
|
||||||
|
inhibited-none = "";
|
||||||
|
dnd-inhibited-notification = "";
|
||||||
|
dnd-inhibited-none = "";
|
||||||
|
};
|
||||||
|
return-type = "json";
|
||||||
|
exec-if = "which swaync-client";
|
||||||
|
exec = "swaync-client -swb";
|
||||||
|
on-click = "swaync-client -t -sw";
|
||||||
|
on-click-right = "swaync-client -d -sw";
|
||||||
|
escape = true;
|
||||||
|
tooltip = false;
|
||||||
|
};
|
||||||
|
|
||||||
|
"sway/language" = {
|
||||||
|
format = "{}";
|
||||||
|
};
|
||||||
|
|
||||||
|
"tray" = {
|
||||||
|
"spacing" = 10;
|
||||||
|
};
|
||||||
|
|
||||||
|
"custom/power" = {
|
||||||
|
format = "⏻ ";
|
||||||
|
tooltip = false;
|
||||||
|
menu = "on-click";
|
||||||
|
"menu-file" = ./waybar/power_menu.xml;
|
||||||
|
"menu-actions" = {
|
||||||
|
shutdown = "shutdown 0";
|
||||||
|
reboot = "reboot";
|
||||||
|
logout = "loginctl terminate-session $(loginctl list-sessions | grep seat0 | awk '{print $1}')";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
style = builtins.readFile ./waybar/waybar.css;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
132
flakes/hyprland/hyprland.nix
Normal file
132
flakes/hyprland/hyprland.nix
Normal file
|
|
@ -0,0 +1,132 @@
|
||||||
|
{
|
||||||
|
config,
|
||||||
|
lib,
|
||||||
|
pkgs,
|
||||||
|
hyprland,
|
||||||
|
hyprlandPkgs,
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
with lib;
|
||||||
|
{
|
||||||
|
# Enable for all users
|
||||||
|
home-manager = {
|
||||||
|
sharedModules = [
|
||||||
|
hyprland.homeManagerModules.default
|
||||||
|
./home_manager
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
services.greetd = {
|
||||||
|
enable = true;
|
||||||
|
vt = 2;
|
||||||
|
settings = {
|
||||||
|
default_session = {
|
||||||
|
command = "${pkgs.greetd.tuigreet}/bin/tuigreet --time --remember --remember-session --cmd '${pkgs.dbus}/bin/dbus-run-session ${hyprlandPkgs.hyprland}/bin/Hyprland'";
|
||||||
|
user = "greeter";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
# Caps Lock as Escape for console/tty
|
||||||
|
console.useXkbConfig = true;
|
||||||
|
services.xserver.xkb = {
|
||||||
|
layout = "us";
|
||||||
|
options = "caps:escape";
|
||||||
|
};
|
||||||
|
|
||||||
|
environment.systemPackages = with pkgs; [
|
||||||
|
wl-clipboard
|
||||||
|
wl-clip-persist
|
||||||
|
wofi # application launcher
|
||||||
|
nemo # file manager (x11)
|
||||||
|
# nautilus # file manager
|
||||||
|
feh # image viewer (x11)
|
||||||
|
# imv # image viewer
|
||||||
|
networkmanager # network management
|
||||||
|
upower # power management
|
||||||
|
brightnessctl # screen/keyboard brightness control
|
||||||
|
wireplumber # media session manager
|
||||||
|
libgtop # system monitor library
|
||||||
|
bluez # Bluetooth support
|
||||||
|
power-profiles-daemon # power profiles
|
||||||
|
grim
|
||||||
|
slurp
|
||||||
|
hyprpicker
|
||||||
|
grimblast # screenshot tool
|
||||||
|
wf-recorder # screen recording tool
|
||||||
|
btop # system monitor
|
||||||
|
];
|
||||||
|
|
||||||
|
services.blueman.enable = config.hardware.bluetooth.enable;
|
||||||
|
|
||||||
|
programs.hyprland = {
|
||||||
|
enable = true;
|
||||||
|
# xwayland.enable = false;
|
||||||
|
# withUWSM = true;
|
||||||
|
|
||||||
|
# set the flake package
|
||||||
|
package = hyprlandPkgs.hyprland;
|
||||||
|
# make sure to also set the portal package, so that they are in sync
|
||||||
|
# This is set below now in xdf portal directly so we can also add things like gtk
|
||||||
|
# portalPackage = hyprlandPkgs.xdg-desktop-portal-hyprland;
|
||||||
|
};
|
||||||
|
|
||||||
|
xdg.portal = {
|
||||||
|
enable = true;
|
||||||
|
extraPortals = lib.mkForce [
|
||||||
|
hyprlandPkgs.xdg-desktop-portal-hyprland
|
||||||
|
# hyprlandPkgs.xdg-desktop-portal-wlr
|
||||||
|
hyprlandPkgs.xdg-desktop-portal-gtk
|
||||||
|
];
|
||||||
|
config.common.default = [
|
||||||
|
"hyprland"
|
||||||
|
# "wlr"
|
||||||
|
"gtk"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
# Enable PipeWire + WirePlumber so xdg-desktop-portal can do screencast
|
||||||
|
services.pipewire = {
|
||||||
|
enable = true;
|
||||||
|
# Enable WirePlumber session manager via the pipewire module option
|
||||||
|
wireplumber = {
|
||||||
|
enable = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
hardware.graphics = {
|
||||||
|
enable = true;
|
||||||
|
package = hyprlandPkgs.mesa;
|
||||||
|
# if you also want 32-bit support (e.g for Steam)
|
||||||
|
# enable32Bit = true;
|
||||||
|
package32 = hyprlandPkgs.pkgsi686Linux.mesa;
|
||||||
|
};
|
||||||
|
|
||||||
|
# Environment variables
|
||||||
|
environment.sessionVariables = {
|
||||||
|
GTK_THEME = "Adwaita:dark";
|
||||||
|
XDG_SESSION_TYPE = "wayland";
|
||||||
|
# XDG_CURRENT_DESKTOP = "sway";
|
||||||
|
# XDG_SESSION_DESKTOP = "sway";
|
||||||
|
# prefer EGL renderer (can be changed back to "auto" if needed)
|
||||||
|
WLR_RENDERER = "egl";
|
||||||
|
|
||||||
|
# Tell apps to run native wayland
|
||||||
|
NIXOS_OZONE_WL = "1";
|
||||||
|
ELECTRON_OZONE_PLATFORM_HINT = "wayland";
|
||||||
|
ELECTRON_ENABLE_WAYLAND = "1";
|
||||||
|
ELECTRON_DISABLE_SANDBOX = "0";
|
||||||
|
GDK_BACKEND = "wayland,x11"; # GTK
|
||||||
|
QT_QPA_PLATFORM = "wayland;xcb"; # Qt 5/6
|
||||||
|
MOZ_ENABLE_WAYLAND = "1"; # Firefox
|
||||||
|
SDL_VIDEODRIVER = "wayland"; # SDL apps/games
|
||||||
|
CLUTTER_BACKEND = "wayland";
|
||||||
|
};
|
||||||
|
|
||||||
|
# Qt theming
|
||||||
|
qt = {
|
||||||
|
enable = true;
|
||||||
|
platformTheme = "gtk2";
|
||||||
|
style = "adwaita-dark";
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
@ -1,5 +1,4 @@
|
||||||
{
|
{
|
||||||
upkgs,
|
|
||||||
pkgs,
|
pkgs,
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
|
|
@ -46,11 +45,6 @@
|
||||||
nodejs_24
|
nodejs_24
|
||||||
foot
|
foot
|
||||||
vlc
|
vlc
|
||||||
upkgs.ladybird
|
|
||||||
google-chrome
|
google-chrome
|
||||||
trilium-desktop
|
|
||||||
dig
|
|
||||||
traceroute
|
|
||||||
# opensnitch-ui
|
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,6 @@
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
{
|
{
|
||||||
system.stateVersion = "24.11"; # Did you read the comment?
|
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
# [Laptop] Battery status
|
# [Laptop] Battery status
|
||||||
acpi
|
acpi
|
||||||
|
|
|
||||||
|
|
@ -1,11 +1,17 @@
|
||||||
{
|
{
|
||||||
inputs = {
|
inputs = {
|
||||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-25.05";
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-25.05";
|
||||||
nixpkgs-unstable.url = "github:nixos/nixpkgs/nixos-unstable";
|
home-manager.url = "github:rycee/home-manager/release-25.05";
|
||||||
|
|
||||||
# Use relative to get current version for testing
|
# Use relative to get current version for testin
|
||||||
# common.url = "path:../../common";
|
# common.url = "path:../../flakes/common";
|
||||||
common.url = "git+https://git.joshuabell.xyz/ringofstorms/dotfiles";
|
common.url = "git+https://git.joshuabell.xyz/ringofstorms/dotfiles?dir=flakes/common";
|
||||||
|
# secrets.url = "path:../../flakes/secrets";
|
||||||
|
secrets.url = "git+https://git.joshuabell.xyz/ringofstorms/dotfiles?dir=flakes/secrets";
|
||||||
|
# flatpaks.url = "path:../../flakes/flatpaks";
|
||||||
|
flatpaks.url = "git+https://git.joshuabell.xyz/ringofstorms/dotfiles?dir=flakes/flatpaks";
|
||||||
|
hyprland.url = "path:../../flakes/hyprland";
|
||||||
|
# hyprland.url = "git+https://git.joshuabell.xyz/ringofstorms/dotfiles?dir=flakes/hyprland";
|
||||||
|
|
||||||
ros_neovim.url = "git+https://git.joshuabell.xyz/ringofstorms/nvim";
|
ros_neovim.url = "git+https://git.joshuabell.xyz/ringofstorms/nvim";
|
||||||
};
|
};
|
||||||
|
|
@ -13,30 +19,123 @@
|
||||||
outputs =
|
outputs =
|
||||||
{
|
{
|
||||||
nixpkgs,
|
nixpkgs,
|
||||||
nixpkgs-unstable,
|
home-manager,
|
||||||
|
|
||||||
common,
|
common,
|
||||||
|
secrets,
|
||||||
|
flatpaks,
|
||||||
|
hyprland,
|
||||||
ros_neovim,
|
ros_neovim,
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
let
|
let
|
||||||
configuration_name = "oren";
|
configuration_name = "oren";
|
||||||
|
system = "x86_64-linux";
|
||||||
|
stateVersion = "25.05";
|
||||||
|
primaryUser = "josh";
|
||||||
lib = nixpkgs.lib;
|
lib = nixpkgs.lib;
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
nixosConfigurations = {
|
nixosConfigurations = {
|
||||||
"${configuration_name}" = (
|
"${configuration_name}" = (
|
||||||
lib.nixosSystem {
|
lib.nixosSystem {
|
||||||
|
inherit system;
|
||||||
modules = [
|
modules = [
|
||||||
common.nixosModules.default
|
home-manager.nixosModules.default
|
||||||
|
|
||||||
|
secrets.nixosModules.default
|
||||||
ros_neovim.nixosModules.default
|
ros_neovim.nixosModules.default
|
||||||
|
flatpaks.nixosModules.default
|
||||||
|
hyprland.nixosModules.default
|
||||||
|
|
||||||
|
common.nixosModules.essentials
|
||||||
|
common.nixosModules.git
|
||||||
|
common.nixosModules.tmux
|
||||||
|
common.nixosModules.boot_systemd
|
||||||
|
common.nixosModules.hardening
|
||||||
|
common.nixosModules.jetbrains_font
|
||||||
|
common.nixosModules.nix_options
|
||||||
|
common.nixosModules.podman
|
||||||
|
common.nixosModules.tailnet
|
||||||
|
common.nixosModules.timezone_auto
|
||||||
|
common.nixosModules.tty_caps_esc
|
||||||
|
common.nixosModules.zsh
|
||||||
|
|
||||||
./configuration.nix
|
./configuration.nix
|
||||||
./hardware-configuration.nix
|
./hardware-configuration.nix
|
||||||
# ./sway_customizations.nix
|
# ./sway_customizations.nix
|
||||||
./hyprland_customizations.nix
|
./hyprland_customizations.nix
|
||||||
(
|
(
|
||||||
{ config, pkgs, ... }:
|
{ config, pkgs, ... }:
|
||||||
{
|
rec {
|
||||||
|
# Home Manager
|
||||||
|
home-manager = {
|
||||||
|
useUserPackages = true;
|
||||||
|
useGlobalPkgs = true;
|
||||||
|
backupFileExtension = "bak";
|
||||||
|
# add all normal users to home manager so it applies to them
|
||||||
|
users = lib.mapAttrs (name: user: {
|
||||||
|
home.stateVersion = stateVersion;
|
||||||
|
programs.home-manager.enable = true;
|
||||||
|
}) (lib.filterAttrs (name: user: user.isNormalUser or false) users.users);
|
||||||
|
|
||||||
|
sharedModules = [
|
||||||
|
common.homeManagerModules.tmux
|
||||||
|
common.homeManagerModules.atuin
|
||||||
|
common.homeManagerModules.direnv
|
||||||
|
common.homeManagerModules.foot
|
||||||
|
common.homeManagerModules.git
|
||||||
|
common.homeManagerModules.postgres_cli_options
|
||||||
|
common.homeManagerModules.ssh
|
||||||
|
common.homeManagerModules.starship
|
||||||
|
common.homeManagerModules.zoxide
|
||||||
|
common.homeManagerModules.zsh
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
# System configuration
|
||||||
|
system.stateVersion = stateVersion;
|
||||||
|
networking.hostName = configuration_name;
|
||||||
|
programs.nh.flake = "/home/${primaryUser}/.config/nixos-config/hosts/${config.networking.hostName}";
|
||||||
|
nixpkgs.config.allowUnfree = true;
|
||||||
|
users.users = {
|
||||||
|
"${primaryUser}" = {
|
||||||
|
isNormalUser = true;
|
||||||
|
initialPassword = "password1";
|
||||||
|
extraGroups = [
|
||||||
|
"wheel"
|
||||||
|
"networkmanager"
|
||||||
|
"video"
|
||||||
|
"input"
|
||||||
|
];
|
||||||
|
openssh.authorizedKeys.keys = [
|
||||||
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAILMzgAe4od9K4EsvH2g7xjNU7hGoJiFJlYcvB0BoDCvn nix2oren"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
environment.systemPackages = with pkgs; [
|
||||||
|
lua
|
||||||
|
qdirstat
|
||||||
|
ffmpeg-full
|
||||||
|
vlc
|
||||||
|
google-chrome
|
||||||
|
|
||||||
|
nodejs_24
|
||||||
|
ttyd
|
||||||
|
appimage-run
|
||||||
|
];
|
||||||
|
|
||||||
|
services.flatpak.packages = [
|
||||||
|
"org.signal.Signal"
|
||||||
|
"dev.vencord.Vesktop"
|
||||||
|
"md.obsidian.Obsidian"
|
||||||
|
"com.spotify.Client"
|
||||||
|
"com.bitwarden.desktop"
|
||||||
|
"org.openscad.OpenSCAD"
|
||||||
|
"im.riot.Riot"
|
||||||
|
"com.rustdesk.RustDesk"
|
||||||
|
];
|
||||||
|
|
||||||
services.devmon.enable = true;
|
services.devmon.enable = true;
|
||||||
services.gvfs.enable = true;
|
services.gvfs.enable = true;
|
||||||
services.udisks2.enable = true;
|
services.udisks2.enable = true;
|
||||||
|
|
@ -68,98 +167,6 @@
|
||||||
|
|
||||||
"ollamal" = "ollama list | tail -n +2 | awk '{print $1}' | fzf --ansi --preview 'ollama show {}'";
|
"ollamal" = "ollama list | tail -n +2 | awk '{print $1}' | fzf --ansi --preview 'ollama show {}'";
|
||||||
};
|
};
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
|
||||||
lua
|
|
||||||
qdirstat
|
|
||||||
ffmpeg-full
|
|
||||||
appimage-run
|
|
||||||
nodejs_24
|
|
||||||
foot
|
|
||||||
ttyd
|
|
||||||
];
|
|
||||||
|
|
||||||
services.ollama = {
|
|
||||||
enable = true;
|
|
||||||
package = nixpkgs-unstable.legacyPackages.x86_64-linux.ollama;
|
|
||||||
acceleration = "rocm"; # cuda for NVIDA; rocm for amd; false/default for neither
|
|
||||||
};
|
|
||||||
|
|
||||||
ringofstorms_common = {
|
|
||||||
systemName = configuration_name;
|
|
||||||
boot.systemd.enable = true;
|
|
||||||
general = {
|
|
||||||
enableSleep = true;
|
|
||||||
reporting.enable = true;
|
|
||||||
};
|
|
||||||
secrets.enable = true;
|
|
||||||
desktopEnvironment.hyprland = {
|
|
||||||
enable = true;
|
|
||||||
waybar.enable = true;
|
|
||||||
swaync.enable = true;
|
|
||||||
};
|
|
||||||
programs = {
|
|
||||||
qFlipper.enable = true;
|
|
||||||
rustDev.enable = true;
|
|
||||||
uhkAgent.enable = true;
|
|
||||||
tailnet.enable = true;
|
|
||||||
ssh.enable = true;
|
|
||||||
podman.enable = true;
|
|
||||||
virt-manager.enable = true;
|
|
||||||
flatpaks = {
|
|
||||||
enable = true;
|
|
||||||
packages = [
|
|
||||||
"org.signal.Signal"
|
|
||||||
"dev.vencord.Vesktop"
|
|
||||||
"md.obsidian.Obsidian"
|
|
||||||
"com.spotify.Client"
|
|
||||||
"org.videolan.VLC"
|
|
||||||
"com.bitwarden.desktop"
|
|
||||||
"im.riot.Riot"
|
|
||||||
"com.rustdesk.RustDesk"
|
|
||||||
"com.google.Chrome"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
users = {
|
|
||||||
# Users are all normal users and default password is password1
|
|
||||||
admins = [ "josh" ]; # First admin is also the primary user owning nix config
|
|
||||||
users = {
|
|
||||||
josh = {
|
|
||||||
openssh.authorizedKeys.keys = [
|
|
||||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAILMzgAe4od9K4EsvH2g7xjNU7hGoJiFJlYcvB0BoDCvn nix2oren"
|
|
||||||
];
|
|
||||||
extraGroups = [
|
|
||||||
"networkmanager"
|
|
||||||
"video"
|
|
||||||
"input"
|
|
||||||
];
|
|
||||||
shell = pkgs.zsh;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
homeManager = {
|
|
||||||
users = {
|
|
||||||
josh = {
|
|
||||||
imports = with common.homeManagerModules; [
|
|
||||||
zsh
|
|
||||||
ssh
|
|
||||||
starship
|
|
||||||
zoxide
|
|
||||||
tmux
|
|
||||||
atuin
|
|
||||||
kitty
|
|
||||||
foot
|
|
||||||
direnv
|
|
||||||
git
|
|
||||||
nix_deprecations
|
|
||||||
obs
|
|
||||||
postgres
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
];
|
];
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
{ lib, pkgs, ... }:
|
{ ... }:
|
||||||
let
|
let
|
||||||
hyprlandExtraOptions = {
|
hyprlandExtraOptions = {
|
||||||
exec-once = [
|
exec-once = [
|
||||||
|
|
@ -11,20 +11,23 @@ let
|
||||||
};
|
};
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
options = { };
|
home-manager.sharedModules = [
|
||||||
|
(
|
||||||
|
{ ... }:
|
||||||
|
{
|
||||||
|
wayland.windowManager.hyprland.settings = hyprlandExtraOptions;
|
||||||
|
services.hyprpaper.settings = {
|
||||||
|
mode = "fill"; # Wallpaper display mode: fill, fit, stretch, center, tile
|
||||||
|
|
||||||
config = {
|
preload = [
|
||||||
ringofstorms_common.desktopEnvironment.hyprland.extraOptions = hyprlandExtraOptions;
|
"${../_shared_assets/wallpapers/pixel_neon.png}"
|
||||||
ringofstorms_common.desktopEnvironment.hyprland.hyprpaperSettings = {
|
];
|
||||||
mode = "fill"; # Wallpaper display mode: fill, fit, stretch, center, tile
|
|
||||||
|
|
||||||
preload = [
|
wallpaper = [
|
||||||
"${../_shared_assets/wallpapers/pixel_neon.png}"
|
"eDP-1,${../_shared_assets/wallpapers/pixel_neon.png}"
|
||||||
];
|
];
|
||||||
|
};
|
||||||
wallpaper = [
|
}
|
||||||
"eDP-1,${../_shared_assets/wallpapers/pixel_neon.png}"
|
)
|
||||||
];
|
];
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -47,6 +47,7 @@
|
||||||
common.nixosModules.git
|
common.nixosModules.git
|
||||||
common.nixosModules.tmux
|
common.nixosModules.tmux
|
||||||
common.nixosModules.boot_systemd
|
common.nixosModules.boot_systemd
|
||||||
|
common.nixosModules.de_sway
|
||||||
common.nixosModules.hardening
|
common.nixosModules.hardening
|
||||||
common.nixosModules.jetbrains_font
|
common.nixosModules.jetbrains_font
|
||||||
common.nixosModules.nix_options
|
common.nixosModules.nix_options
|
||||||
|
|
@ -105,11 +106,19 @@
|
||||||
"input"
|
"input"
|
||||||
];
|
];
|
||||||
openssh.authorizedKeys.keys = [
|
openssh.authorizedKeys.keys = [
|
||||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJN2nsLmAlF6zj5dEBkNSJaqcCya+aB6I0imY8Q5Ew0S nix2lio"
|
"REPLACE"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
environment.systemPackages = with pkgs; [
|
||||||
|
lua
|
||||||
|
qdirstat
|
||||||
|
ffmpeg-full
|
||||||
|
vlc
|
||||||
|
google-chrome
|
||||||
|
];
|
||||||
|
|
||||||
services.flatpak.packages = [
|
services.flatpak.packages = [
|
||||||
"org.signal.Signal"
|
"org.signal.Signal"
|
||||||
"dev.vencord.Vesktop"
|
"dev.vencord.Vesktop"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue