working on hyor
This commit is contained in:
+350
-350
File diff suppressed because it is too large
Load Diff
@@ -9,6 +9,7 @@
|
||||
|
||||
let
|
||||
hyprlandConfigDir = "${config.home-manager.users.${user.username}.xdg.configHome}/hypr";
|
||||
# Dynamically read all files in assets/hyprland/conf/
|
||||
hyprlandConfs =
|
||||
lib.genAttrs (builtins.attrNames (builtins.readDir "${flakeRoot}/assets/hyprland/conf/hypr"))
|
||||
(name: {
|
||||
@@ -22,28 +23,22 @@ in
|
||||
};
|
||||
|
||||
# Home Manager: Hyprland-specific configurations
|
||||
home-manager.users.${user.username} = rec {
|
||||
home.stateVersion = "25.11";
|
||||
home.username = user.username;
|
||||
home.homeDirectory = user.homeDirectory;
|
||||
home-manager.users.${user.username} = {
|
||||
# Use config.home-manager.users.${user.username} instead of userConfig
|
||||
home.stateVersion = config.home-manager.users.${user.username}.stateVersion or "23.11"; # Default fallback
|
||||
home.username = user.username; # Use the 'user' argument
|
||||
home.homeDirectory =
|
||||
config.home-manager.users.${user.username}.homeDirectory or "/home/${user.username}";
|
||||
|
||||
wayland.windowManager.hyprland = {
|
||||
enable = true;
|
||||
};
|
||||
|
||||
# Ensure the Hyprland config directory exists and has the correct permissions
|
||||
# Ensure the Hyprland config directory exists
|
||||
xdg.configFile = {
|
||||
"hypr/.keep" = {
|
||||
text = "";
|
||||
};
|
||||
}
|
||||
// hyprlandConfs;
|
||||
|
||||
# Ensure the home directory and .config directory have the correct permissions
|
||||
home.file.".config".source = pkgs.writeDashScriptBin "mkdir-config" ''
|
||||
mkdir -p $HOME/.config
|
||||
chown -R ${user.username}:users $HOME/.config
|
||||
chmod -R 755 $HOME/.config
|
||||
'';
|
||||
} // hyprlandConfs;
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user