1
0
mirror of https://github.com/AvengeMedia/DankMaterialShell.git synced 2026-06-09 04:33:29 -04:00

fix(windowrules): honor $XDG_CONFIG_HOME for config paths

- Window rule read/write/includes detection and setup hardcoded
`$HOME/.config` so rules weren't applied when `XDG_CONFIG_HOME` pointed
elsewhere.
- Fixes #2289
This commit is contained in:
purian23
2026-06-03 19:01:25 -04:00
parent 82d4364032
commit 6f387b0481
3 changed files with 10 additions and 30 deletions
+3 -12
View File
@@ -87,10 +87,7 @@ func runResolveInclude(cmd *cobra.Command, args []string) {
}
func checkHyprlandInclude(filename string) (IncludeResult, error) {
configDir, err := utils.ExpandPath("$HOME/.config/hypr")
if err != nil {
return IncludeResult{}, err
}
configDir := filepath.Join(utils.XDGConfigHome(), "hypr")
targetPath := filepath.Join(configDir, "dms", filename)
result := IncludeResult{}
@@ -191,10 +188,7 @@ func hyprlandFindIncludeHyprlang(filePath, target string, processed map[string]b
}
func checkNiriInclude(filename string) (IncludeResult, error) {
configDir, err := utils.ExpandPath("$HOME/.config/niri")
if err != nil {
return IncludeResult{}, err
}
configDir := filepath.Join(utils.XDGConfigHome(), "niri")
targetPath := filepath.Join(configDir, "dms", filename)
result := IncludeResult{}
@@ -270,10 +264,7 @@ func niriFindInclude(filePath, target string, processed map[string]bool) bool {
}
func checkMangoWCInclude(filename string) (IncludeResult, error) {
configDir, err := utils.ExpandPath("$HOME/.config/mango")
if err != nil {
return IncludeResult{}, err
}
configDir := filepath.Join(utils.XDGConfigHome(), "mango")
targetPath := filepath.Join(configDir, "dms", filename)
result := IncludeResult{}