From 30aeab5cf9520540f77eec5ae557fd185f730957 Mon Sep 17 00:00:00 2001 From: tblyler Date: Tue, 9 Jun 2020 21:14:15 -0400 Subject: [PATCH] autostart sway if tty1 and it is enabled via ~/.zshrc.d/sway_enabled existing --- home/.zshrc | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/home/.zshrc b/home/.zshrc index f35855e..e1f7e60 100644 --- a/home/.zshrc +++ b/home/.zshrc @@ -1,3 +1,8 @@ +if [ -f "${HOME}/.zshrc.d/sway_enabled" ] && command -v tty &> /dev/null && command -v sway &> /dev/null && [ "$(tty)" = '/dev/tty1' ]; then + exec sway + exit $? +fi + export PATH="/usr/local/sbin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:${PATH}" if [ -d "${HOME}/bin" ]; then export PATH="${HOME}/bin:${PATH}"