From 8c5aa85c54105eb11452c1e6edf00cb55a6fb1f2 Mon Sep 17 00:00:00 2001 From: digitalsleuth Date: Sun, 8 Jan 2023 02:40:26 +0000 Subject: [PATCH] Fix issue with dbus-launch on Jammy --- mat/VERSION | 2 +- mat/theme/terminal.sls | 11 ++++++++--- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/mat/VERSION b/mat/VERSION index b701b78..e1d2989 100644 --- a/mat/VERSION +++ b/mat/VERSION @@ -1 +1 @@ -v2022.5.3 +v2022.5.4 diff --git a/mat/theme/terminal.sls b/mat/theme/terminal.sls index 1822ac6..259a2ee 100644 --- a/mat/theme/terminal.sls +++ b/mat/theme/terminal.sls @@ -4,7 +4,6 @@ {%- else -%} {%- set home = salt['user.info'](user).home -%} {%- endif -%} -{%- set dbus_address = salt['cmd.run']("dbus-launch | grep DBUS_SESSION_BUS_ADDRESS | cut -d= -f2-", shell="/bin/bash", runas=user, cwd=home, python_shell=True) -%} include: - mat.apt-packages.git @@ -39,9 +38,15 @@ mat-theme-terminal-profile-install: - runas: {{ user }} - cwd: {{ home }} - shell: /bin/bash - - env: - - DBUS_SESSION_BUS_ADDRESS: "{{ dbus_address }}" + - onlyif: + - fun: cmd.run + cmd: export DBUS_SESSION_BUS_ADDRESS=$(dbus-launch | grep DBUS_SESSION_BUS_ADDRESS | cut -d= -f2-) + shell: /bin/bash + python_shell: True + runas: {{ user }} - require: - file: mat-theme-terminal-profile + - sls: mat.apt-packages.dbus-x11 - watch: - file: mat-theme-terminal-profile + - sls: mat.apt-packages.dbus-x11