autostart sway if tty1 and it is enabled via ~/.zshrc.d/sway_enabled existing

This commit is contained in:
tblyler 2020-06-09 21:14:15 -04:00
parent 626f21a911
commit 30aeab5cf9

View file

@ -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}"