mirror of
https://github.com/hyprwm/Hyprland
synced 2024-11-26 00:05:58 +01:00
env: Add HYPRLAND_NO_SD_VARS env condition (#7358)
* Add HYPRLAND_NO_SD_VARS env condition wip #7083 * Formatting shuffle * Formatting
This commit is contained in:
parent
12d9901472
commit
682b30fba8
1 changed files with 6 additions and 2 deletions
|
@ -429,7 +429,7 @@ void CCompositor::cleanEnvironment() {
|
|||
if (m_bDesktopEnvSet)
|
||||
unsetenv("XDG_CURRENT_DESKTOP");
|
||||
|
||||
if (m_pAqBackend->hasSession()) {
|
||||
if (m_pAqBackend->hasSession() && !envEnabled("HYPRLAND_NO_SD_VARS")) {
|
||||
const auto CMD =
|
||||
#ifdef USES_SYSTEMD
|
||||
"systemctl --user unset-environment DISPLAY WAYLAND_DISPLAY HYPRLAND_INSTANCE_SIGNATURE XDG_CURRENT_DESKTOP QT_QPA_PLATFORMTHEME PATH XDG_DATA_DIRS && hash "
|
||||
|
@ -659,7 +659,11 @@ void CCompositor::prepareFallbackOutput() {
|
|||
void CCompositor::startCompositor() {
|
||||
signal(SIGPIPE, SIG_IGN);
|
||||
|
||||
if (m_pAqBackend->hasSession() /* Session-less Hyprland usually means a nest, don't update the env in that case */) {
|
||||
if (
|
||||
/* Session-less Hyprland usually means a nest, don't update the env in that case */
|
||||
m_pAqBackend->hasSession() &&
|
||||
/* Activation environment management is not disabled */
|
||||
!envEnabled("HYPRLAND_NO_SD_VARS")) {
|
||||
const auto CMD =
|
||||
#ifdef USES_SYSTEMD
|
||||
"systemctl --user import-environment DISPLAY WAYLAND_DISPLAY HYPRLAND_INSTANCE_SIGNATURE XDG_CURRENT_DESKTOP QT_QPA_PLATFORMTHEME PATH XDG_DATA_DIRS && hash "
|
||||
|
|
Loading…
Reference in a new issue