aboutsummaryrefslogtreecommitdiffstats
path: root/bin/startsway
blob: 0809fb8f13aafbb562d547d8db3071b159ece40d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#!/usr/bin/env bash

export XKB_DEFAULT_LAYOUT=us,de
export XKB_DEFAULT_OPTIONS=grp:alt_shift_toggle,caps:escape

export CLUTTER_BACKEND=wayland
export QT_QPA_PLATFORM=wayland-egl
export QT_WAYLAND_FORCE_DPI=physical
export SDL_VIDEODRIVER=wayland
export BEMENU_BACKEND=wayland

# crashes sway on reload:
# export MOZ_ENABLE_WAYLAND=1

export RUST_BACKTRACE=full

mkdir -p "$HOME/.log"
config="$HOME/.config/sway/config"

if [ -f "$HOME/.config/sway/${HOSTNAME}" ]; then
  config="$HOME/.config/sway/${HOSTNAME}"
fi
/usr/bin/sway -c "$config" > "$HOME/.log/sway.log" 2>&1