ErikReider/SwayNotificationCenter

[Feature] Multi File Includes

オープン

#607 opened on 2025/07/18

 (1 件のコメント) (1 件のリアクション) (0 人の担当者)Vala (98 件のフォーク)auto 404
documentationenhancementhelp wanted

Repository metrics

Stars
 (2,535 個のスター)
PR merge metrics
 (PR metrics pending)

説明

Please read through the README and the Man pages before submitting Please also make sure that there isn't any prior issue describing this feature

Thank you for maintaining this great project!

Is your feature request related to a problem? Please describe.

I'm maintaining a dotfiles repo with a very small fraction of user base. It would be helpful for QOL, to have at least a capability to do multi-file configuration. This way we can make the e.g modules grid modular etc.

Describe the solution you'd like

To avoid codebase breakage, I would suggest to add includes property that accepts an array. This is pretty similar to waybar. As I use waybar, I think the rules are:

  1. Whatever property comes first supersedes. ( unlike css)
  2. The includes path can be recursive, but should avoid looping.
  3. Maybe support env vars for the paths array e.g $XDG_CONFIG_HOME, and support /path/to/files/*.json or similar approach.
  4. The included modules should still follow the structure of the config.json.
  5. validate the includes and throw warning, and don't crash (as notif daemon we shouldn't)
  6. Ignore unknown props but warn

ps For 4 in waybar configuration it is flat therefore it is not an issue. In swaync we have nesting of properties therefore each include files should conform to how config.json is structure.

Describe alternatives you've considered

Anything that is approved by the developer should suffice.

Additional context

Ahhh I love the gtk4 port! That gives the courage to open this FeatReq.

Thank you again for this project !

コントリビューターガイド