After a bit of testing and consideration, I have come to a conclusion that X11 hierarchy is not fit for this purpose since Wayland or pure virtual terminal sessions never get to source those files.
A more suitable destination for such an init file would be /etc/profile.d, which contains system-wide init files for login shells (sourced upon shell invocation). Ideally, this should be standardized across all XDG-compliant systems.
For now, another file should be placed in debian and included in d/gnome-session-common.install for installation at /etc/profile.d
After a bit of testing and consideration, I have come to a conclusion that X11 hierarchy is not fit for this purpose since Wayland or pure virtual terminal sessions never get to source those files.
A more suitable destination for such an init file would be /etc/profile.d, which contains system-wide init files for login shells (sourced upon shell invocation). Ideally, this should be standardized across all XDG-compliant systems.
For now, another file should be placed in debian and included in d/gnome- session- common. install for installation at /etc/profile.d