feat(hyprland): init hyprland as nixos and home-manager modules

This commit is contained in:
Mohammad Rafiq 2025-03-05 08:04:20 +08:00
parent f51b21889c
commit ee0aa7c4a3
6 changed files with 40 additions and 1 deletions

View file

@ -0,0 +1,11 @@
{ inputs, pkgs, ... }: {
programs.uwsm = {
enable = false;
};
programs.hyprland = {
enable = true;
#withUWSN = true;
package = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland;
portalPackage = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.xdg-desktop-portal-hyprland;
};
}

View file

@ -5,6 +5,7 @@
./modules/systemd-boot.nix
./modules/locale.nix
./modules/networking.nix
./modules/hyprland.nix
];
networking.hostName = "nemesis";

View file

@ -0,0 +1,10 @@
monitor = , preferred, auto, 1
$mainMod = SUPER
$terminal = kitty
$browser = firefox
bind = $mainMod, Q, exec, $terminal
bind = $mainMod, W, killactive
bind = $mainMod, E, exec, $browser
bind = $mainMod, M, exit

View file

@ -2,9 +2,10 @@ _: {
imports = [
./modules/git.nix # git specific configs
./modules/sh.nix # bash and other shell specific configs
./modules/wm.nix # window manager configs
./modules/nvim.nix # nvim specific configs
./modules/terminal.nix # terminal emulator configs
./modules/firefox.nix # firefox configs
./modules/hyprland.nix # hyprland settings
./modules/utils.nix # miscellaneous utilities
];

View file

@ -0,0 +1,7 @@
{ pkgs, ... }:
{
home.packages = with pkgs; [
firefox
];
}

View file

@ -0,0 +1,9 @@
{ config, lib, ... }: {
wayland.windowManager.hyprland = {
enable = true;
package = null;
portalPackage = null;
};
xdg.configFile."hypr".source = config.lib.file.mkOutOfStoreSymlink "${config.home.homeDirectory}/repos/dotfiles/users/rafiq/.config/hypr";
xdg.configFile."hypr/hyprland.conf".enable = false; # Needed so home-manager won't create the config file
}