mess around with hyprland
This commit is contained in:
2
.gitignore
vendored
2
.gitignore
vendored
@@ -1 +1,3 @@
|
|||||||
.idea
|
.idea
|
||||||
|
*.qcow2
|
||||||
|
result
|
||||||
|
|||||||
@@ -1,6 +1,10 @@
|
|||||||
{ user, pkgs, layout, variant, ... }:
|
{ config, osConfig, pkgs, inputs, lib, ... }:
|
||||||
|
with lib;
|
||||||
|
let
|
||||||
|
cfg = osConfig.custom.graphical.hyprland;
|
||||||
|
in
|
||||||
{
|
{
|
||||||
home-manager.users.${user} = {
|
config = lib.mkIf cfg.enable {
|
||||||
programs.swaylock.enable = true;
|
programs.swaylock.enable = true;
|
||||||
wayland.windowManager.hyprland = {
|
wayland.windowManager.hyprland = {
|
||||||
enable = true;
|
enable = true;
|
||||||
@@ -38,8 +42,8 @@
|
|||||||
|
|
||||||
# For all categories, see https://wiki.hyprland.org/Configuring/Variables/
|
# For all categories, see https://wiki.hyprland.org/Configuring/Variables/
|
||||||
input = {
|
input = {
|
||||||
kb_layout = layout;
|
kb_layout = osConfig.mainUser.layout;
|
||||||
kb_variant = variant;
|
kb_variant = osConfig.mainUser.variant;
|
||||||
kb_model = "";
|
kb_model = "";
|
||||||
kb_options = "";
|
kb_options = "";
|
||||||
kb_rules = "";
|
kb_rules = "";
|
||||||
@@ -155,7 +159,7 @@
|
|||||||
"$mainMod, V, togglefloating"
|
"$mainMod, V, togglefloating"
|
||||||
"$mainMod, I, exec, ${rofi} -show drun -show-icons"
|
"$mainMod, I, exec, ${rofi} -show drun -show-icons"
|
||||||
"$mainMod, S, exec, cat ~/songs | shuf -n 1 | sed \"s/^/b\.p /g\" | ${wl-copy}"
|
"$mainMod, S, exec, cat ~/songs | shuf -n 1 | sed \"s/^/b\.p /g\" | ${wl-copy}"
|
||||||
"$mainMod, R, exec, ${swww} img $(ls -d ~/Nextcloud/dinge/Bg/* | shuf -n 1)"
|
"$mainMod, R, exec, ${swww} img $(ls -d /synced/default/dinge/Bg/* | shuf -n 1)"
|
||||||
" , Print, exec, ${grim} -g \"$(${slurp} -d)\" - | ${wl-copy}"
|
" , Print, exec, ${grim} -g \"$(${slurp} -d)\" - | ${wl-copy}"
|
||||||
"ALT, SPACE, exec, ${rofi} -show combi"
|
"ALT, SPACE, exec, ${rofi} -show combi"
|
||||||
" , XF86MonBrightnessUp, exec, ${brightnessctl} s +5%"
|
" , XF86MonBrightnessUp, exec, ${brightnessctl} s +5%"
|
||||||
@@ -230,7 +234,7 @@
|
|||||||
|
|
||||||
exec-once = [
|
exec-once = [
|
||||||
"${pkgs.swww}/bin/swww init; sleep 1;"
|
"${pkgs.swww}/bin/swww init; sleep 1;"
|
||||||
"${pkgs.swww} img $(ls -d ~/Nextcloud/dinge/Bg/* | shuf -n 1)"
|
"${pkgs.swww} img $(ls -d /synced/default/dinge/Bg/* | shuf -n 1)"
|
||||||
"${pkgs.networkmanagerapplet}/bin/nm-applet --indicator &"
|
"${pkgs.networkmanagerapplet}/bin/nm-applet --indicator &"
|
||||||
"${pkgs.waybar}/bin/waybar &"
|
"${pkgs.waybar}/bin/waybar &"
|
||||||
#"${pkgs.dunst}/bin/dunst &"
|
#"${pkgs.dunst}/bin/dunst &"
|
||||||
|
|||||||
22
home-manager/hyprland-xwaylandvideobridge.nix
Normal file
22
home-manager/hyprland-xwaylandvideobridge.nix
Normal file
@@ -0,0 +1,22 @@
|
|||||||
|
{ config, osConfig, pkgs, inputs, lib, ... }:
|
||||||
|
with lib;
|
||||||
|
let
|
||||||
|
cfg = osConfig.custom.graphical.hyprland.videobridge;
|
||||||
|
in
|
||||||
|
{
|
||||||
|
config = lib.mkIf cfg.enable {
|
||||||
|
wayland.windowManager.hyprland.settings.windowrulev2 = [
|
||||||
|
"opacity 0.0 override 0.0 override,class:^(xwaylandvideobridge)$"
|
||||||
|
"noanim,class:^(xwaylandvideobridge)$"
|
||||||
|
"noinitialfocus,class:^(xwaylandvideobridge)$"
|
||||||
|
"maxsize 1 1,class:^(xwaylandvideobridge)$"
|
||||||
|
"noblur,class:^(xwaylandvideobridge)$"
|
||||||
|
];
|
||||||
|
|
||||||
|
systemd.user.services.xwaylandvideobridge = {
|
||||||
|
Unit.Description = "XWaylandVideoBridge";
|
||||||
|
Service.ExecStart = lib.getExe pkgs.xwaylandvideobridge;
|
||||||
|
Install.WantedBy = ["graphical-session.target"];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -30,6 +30,8 @@
|
|||||||
wooting.enable = true;
|
wooting.enable = true;
|
||||||
};
|
};
|
||||||
graphical = {
|
graphical = {
|
||||||
|
hyprland.enable = true;
|
||||||
|
hyprland.videobridge.enable = true;
|
||||||
audio.enable = true;
|
audio.enable = true;
|
||||||
code.enable = true;
|
code.enable = true;
|
||||||
emulators.enable = true;
|
emulators.enable = true;
|
||||||
|
|||||||
@@ -21,6 +21,7 @@
|
|||||||
code.enable = true;
|
code.enable = true;
|
||||||
emulators.enable = true;
|
emulators.enable = true;
|
||||||
gamemode.enable = true;
|
gamemode.enable = true;
|
||||||
|
hyprland.enable = true;
|
||||||
games.enable = true;
|
games.enable = true;
|
||||||
ime.enable = true;
|
ime.enable = true;
|
||||||
shared.enable = true;
|
shared.enable = true;
|
||||||
|
|||||||
@@ -7,6 +7,7 @@
|
|||||||
./gamemode.nix
|
./gamemode.nix
|
||||||
./games.nix
|
./games.nix
|
||||||
./gnome.nix
|
./gnome.nix
|
||||||
|
./hyprland.nix
|
||||||
./ime.nix
|
./ime.nix
|
||||||
./lxqt.nix
|
./lxqt.nix
|
||||||
./noise-supression.nix
|
./noise-supression.nix
|
||||||
|
|||||||
@@ -1,36 +1,40 @@
|
|||||||
{ config, pkgs, lib, inputs, ... }:
|
{ config, pkgs, lib, inputs, ... }:
|
||||||
|
with lib;
|
||||||
let
|
let
|
||||||
patchedWaybar = pkgs.unstable.waybar.overrideAttrs (oldAttrs: {
|
cfg = config.custom.graphical.hyprland;
|
||||||
mesonFlags = oldAttrs.mesonFlags ++ [ "-Dexperimental=true" ];
|
|
||||||
});
|
|
||||||
|
|
||||||
#patchedHyprland = pkgs.hyprland.overrideAttrs (oldAttrs: {
|
|
||||||
# version = "0.28.0";
|
|
||||||
#});
|
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
imports = [
|
options.custom.graphical.hyprland = {
|
||||||
(import ../../home-manager/hyprland-settings.nix ({ user="${config.mainUser.name}"; pkgs = pkgs; layout = config.mainUser.layout; variant = config.mainUser.variant; }))
|
enable = mkEnableOption "Enables hyprland";
|
||||||
];
|
};
|
||||||
|
options.custom.graphical.hyprland.videobridge = {
|
||||||
|
enable = mkEnableOption "Enables xwaylandvideobridge for hyprland";
|
||||||
|
};
|
||||||
|
|
||||||
|
config = let
|
||||||
|
patchedWaybar = pkgs.unstable.waybar.overrideAttrs (oldAttrs: { mesonFlags = oldAttrs.mesonFlags ++ [ "-Dexperimental=true" ]; });
|
||||||
|
in mkIf cfg.enable {
|
||||||
services.xserver = {
|
services.xserver = {
|
||||||
layout = config.mainUser.layout;
|
layout = config.mainUser.layout;
|
||||||
xkbVariant = config.mainUser.variant;
|
xkbVariant = config.mainUser.variant;
|
||||||
enable = true;
|
enable = true;
|
||||||
displayManager = lib.mkIf (!config.services.xserver.displayManager.gdm.enable) {
|
displayManager = mkIf (!config.services.xserver.displayManager.gdm.enable) {
|
||||||
sddm.enable = true;
|
sddm.enable = true;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
environment.sessionVariables = {
|
environment.sessionVariables = {
|
||||||
# If your cursor becomes invisible
|
|
||||||
#WLR_NO_HARDWARE_CURSORS = "1";
|
|
||||||
# Hint electron apps to use wayland
|
# Hint electron apps to use wayland
|
||||||
NIXOS_OZONE_WL = "1";
|
NIXOS_OZONE_WL = "1";
|
||||||
WLR_NO_HARDWARE_CURSORS="1";
|
WLR_NO_HARDWARE_CURSORS="1";
|
||||||
#WLR_DRM_NO_ATOMIC="1";
|
#WLR_DRM_NO_ATOMIC="1";
|
||||||
WLR_DRM_DEVICES = "/dev/dri/card0";
|
#WLR_DRM_DEVICES = "/dev/dri/card0";
|
||||||
|
LIBVA_DRIVER_NAME="nvidia";
|
||||||
|
# black screen :(
|
||||||
|
#XDG_SESSION_TYPE = "wayland";
|
||||||
|
GBM_BACKEND = "nvidia-drm";
|
||||||
|
__GLX_VENDOR_LIBRARY_NAME = "nvidia";
|
||||||
|
WLR_RENDERER_ALLOW_SOFTWARE="1";
|
||||||
};
|
};
|
||||||
|
|
||||||
hardware = {
|
hardware = {
|
||||||
@@ -79,4 +83,5 @@ in
|
|||||||
#xdg-utils
|
#xdg-utils
|
||||||
#xwayland
|
#xwayland
|
||||||
];
|
];
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ in
|
|||||||
xkb.layout = config.mainUser.layout;
|
xkb.layout = config.mainUser.layout;
|
||||||
xkb.variant = config.mainUser.variant;
|
xkb.variant = config.mainUser.variant;
|
||||||
displayManager.sddm.enable = true;
|
displayManager.sddm.enable = true;
|
||||||
displayManager.sddm.settings.Wayland.SessionDir = "${pkgs.plasma5Packages.plasma-workspace}/share/wayland-sessions";
|
#displayManager.sddm.settings.Wayland.SessionDir = "${pkgs.plasma5Packages.plasma-workspace}/share/wayland-sessions";
|
||||||
#displayManager.sddm.wayland.enable = true;
|
#displayManager.sddm.wayland.enable = true;
|
||||||
|
|
||||||
libinput = {
|
libinput = {
|
||||||
|
|||||||
@@ -16,7 +16,7 @@
|
|||||||
settings.enable = true;
|
settings.enable = true;
|
||||||
};
|
};
|
||||||
graphical = {
|
graphical = {
|
||||||
plasma.enable = true;
|
hyprland.enable = true;
|
||||||
shared.enable = true;
|
shared.enable = true;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -22,6 +22,8 @@
|
|||||||
../../home-manager/kitty.nix
|
../../home-manager/kitty.nix
|
||||||
../../home-manager/rofi.nix
|
../../home-manager/rofi.nix
|
||||||
../../home-manager/kde-path.nix
|
../../home-manager/kde-path.nix
|
||||||
|
../../home-manager/hyprland-settings.nix
|
||||||
|
../../home-manager/hyprland-xwaylandvideobridge.nix
|
||||||
../../home-manager/firefox
|
../../home-manager/firefox
|
||||||
inputs.nix-colors.homeManagerModule
|
inputs.nix-colors.homeManagerModule
|
||||||
];
|
];
|
||||||
|
|||||||
@@ -7,6 +7,7 @@
|
|||||||
imports = [
|
imports = [
|
||||||
../../home-manager/nvim.nix
|
../../home-manager/nvim.nix
|
||||||
../../home-manager/zsh.nix
|
../../home-manager/zsh.nix
|
||||||
|
../../home-manager/hyprland-settings.nix
|
||||||
inputs.nix-colors.homeManagerModule
|
inputs.nix-colors.homeManagerModule
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user