aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xinstall.sh1
-rwxr-xr-xsway/run-sway.sh7
2 files changed, 8 insertions, 0 deletions
diff --git a/install.sh b/install.sh
index c49ce4f..aa4fe02 100755
--- a/install.sh
+++ b/install.sh
@@ -177,6 +177,7 @@ done
# sway
symlink ~/.dotfiles/sway ~/.config/sway
+symlink ~/.dotfiles/sway/run-sway.sh ~/bin/run-sway
# tmux
symlink ~/.dotfiles/tmux ~/.config/tmux
diff --git a/sway/run-sway.sh b/sway/run-sway.sh
new file mode 100755
index 0000000..6980cd4
--- /dev/null
+++ b/sway/run-sway.sh
@@ -0,0 +1,7 @@
+#!/bin/sh
+
+if pidof dbus-daemon > /dev/null; then
+ exec sway > ~/.sway.log
+else
+ exec dbus-run-session -- sway > ~/.sway.log
+fi