Swtich back from running apps with systemd
systemd integration for Sway is cool, but introduces a lot of unexpected problems, such as race conditions. So switch back to classic config-based systemd for autostarting services until all major problems with systemd integration (sway-systemd) will resolved
This commit is contained in:
parent
1be042ad16
commit
6b0a66e6be
10 changed files with 47 additions and 1 deletions
2
debian/control
vendored
2
debian/control
vendored
|
@ -8,7 +8,7 @@ Homepage: https://github.com/Tile-OS/tileos-settings-sway.git
|
||||||
Rules-Requires-Root: no
|
Rules-Requires-Root: no
|
||||||
|
|
||||||
Package: tileos-settings-sway
|
Package: tileos-settings-sway
|
||||||
Architecture: any
|
Architecture: all
|
||||||
Depends: ${shlibs:Depends}, ${misc:Depends}
|
Depends: ${shlibs:Depends}, ${misc:Depends}
|
||||||
Conflicts: tileos-settings-river
|
Conflicts: tileos-settings-river
|
||||||
Description: default settings for Sway on TileOS
|
Description: default settings for Sway on TileOS
|
||||||
|
|
5
etc/skel/.config/waybar/config.jsonc.example
Normal file
5
etc/skel/.config/waybar/config.jsonc.example
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
{
|
||||||
|
"include": [
|
||||||
|
"/etc/xdg/xdg-tileos/waybar/config.jsonc"
|
||||||
|
]
|
||||||
|
}
|
1
etc/skel/.config/waybar/style.css.example
Normal file
1
etc/skel/.config/waybar/style.css.example
Normal file
|
@ -0,0 +1 @@
|
||||||
|
@import "/etc/xdg/xdg-tileos/waybar/style.css";
|
9
etc/sway/config.d/20-waybar.conf
Normal file
9
etc/sway/config.d/20-waybar.conf
Normal file
|
@ -0,0 +1,9 @@
|
||||||
|
#
|
||||||
|
# Status Bar:
|
||||||
|
#
|
||||||
|
# Read `man 5 sway-bar` for more information about this section.
|
||||||
|
bar {
|
||||||
|
id default
|
||||||
|
swaybar_command /usr/share/sway/scripts/waybar.sh
|
||||||
|
position top
|
||||||
|
}
|
|
@ -3,7 +3,9 @@
|
||||||
|
|
||||||
exec {
|
exec {
|
||||||
$polkit_agent
|
$polkit_agent
|
||||||
|
$idle
|
||||||
$swappy_notify
|
$swappy_notify
|
||||||
|
$dex_autostart
|
||||||
$wlsunset
|
$wlsunset
|
||||||
$autotiling
|
$autotiling
|
||||||
$term_server
|
$term_server
|
||||||
|
@ -16,8 +18,10 @@ exec_always {
|
||||||
$kanshi
|
$kanshi
|
||||||
$spice_vdagent
|
$spice_vdagent
|
||||||
$nwg_drawer_daemon
|
$nwg_drawer_daemon
|
||||||
|
$poweralertd
|
||||||
$watch_playerctl
|
$watch_playerctl
|
||||||
$calendar_daemon
|
$calendar_daemon
|
||||||
$import_gsettings
|
$import_gsettings
|
||||||
$update_rofi_theme
|
$update_rofi_theme
|
||||||
|
$swayr_daemon
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,6 +2,9 @@
|
||||||
# from /usr/bin/start-sway script for all users of the system.
|
# from /usr/bin/start-sway script for all users of the system.
|
||||||
# User-specific variables should be placed in $XDG_CONFIG_HOME/sway/environment
|
# User-specific variables should be placed in $XDG_CONFIG_HOME/sway/environment
|
||||||
|
|
||||||
|
# TileOS specific config dir
|
||||||
|
export XDG_CONFIG_DIRS=/etc/xdg/xdg-tileos:/etc/xdg
|
||||||
|
|
||||||
# Force Wayland for Mozilla Firefox
|
# Force Wayland for Mozilla Firefox
|
||||||
export MOZ_ENABLE_WAYLAND=1
|
export MOZ_ENABLE_WAYLAND=1
|
||||||
export MOZ_DBUS_REMOTE=1
|
export MOZ_DBUS_REMOTE=1
|
||||||
|
|
|
@ -113,6 +113,15 @@ set $kanshi '[ -x "$(command -v kanshi)" ] && pkill kanshi; exec kanshi'
|
||||||
# Workaround for applying GTK theme
|
# Workaround for applying GTK theme
|
||||||
set $import_gsettings '[ -f /usr/share/sway/scripts/import-gsettings.sh ] && /usr/share/sway/scripts/import-gsettings.sh'
|
set $import_gsettings '[ -f /usr/share/sway/scripts/import-gsettings.sh ] && /usr/share/sway/scripts/import-gsettings.sh'
|
||||||
|
|
||||||
|
# Dex autostart daemon
|
||||||
|
set $dex_autostart '[ -x "$(command -v dex)" ] && gdbus wait --session org.kde.StatusNotifierWatcher && dex --autostart'
|
||||||
|
|
||||||
|
# Swayr daemon
|
||||||
|
set $swayr_daemon '[ -x "$(command -v swayrd)" ] && env RUST_BACKTRACE=1 RUST_LOG=swayr=debug swayrd &> /tmp/swayrd.log'
|
||||||
|
|
||||||
|
# Power notifications daemon
|
||||||
|
set $poweralertd '[ -x "$(command -v poweralertd)" ] && pkill poweralertd; poweralertd -s -i "line power" &'
|
||||||
|
|
||||||
# Start PCmanFM as a daemon
|
# Start PCmanFM as a daemon
|
||||||
set $pcmanfm_daemon '[ -x "$(command -v pcmanfm)" ] && pcmanfm -d'
|
set $pcmanfm_daemon '[ -x "$(command -v pcmanfm)" ] && pcmanfm -d'
|
||||||
|
|
||||||
|
|
15
usr/share/sway/scripts/waybar.sh
Executable file
15
usr/share/sway/scripts/waybar.sh
Executable file
|
@ -0,0 +1,15 @@
|
||||||
|
#!/bin/sh
|
||||||
|
# wrapper script for waybar with args, see https://github.com/swaywm/sway/issues/5724
|
||||||
|
|
||||||
|
USER_CONFIG_PATH=$HOME/.config/waybar/config.jsonc
|
||||||
|
USER_STYLE_PATH=$HOME/.config/waybar/style.css
|
||||||
|
|
||||||
|
if [ -f "$USER_CONFIG_PATH" ]; then
|
||||||
|
USER_CONFIG=$USER_CONFIG_PATH
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -f "$USER_STYLE_PATH" ]; then
|
||||||
|
USER_STYLE=$USER_STYLE_PATH
|
||||||
|
fi
|
||||||
|
|
||||||
|
waybar -c "${USER_CONFIG:-"/etc/xdg/xdg-tileos/waybar/config.jsonc"}" -s "${USER_STYLE:-"/etc/xdg/xdg-tileos/waybar/style.css"}" &
|
Loading…
Add table
Reference in a new issue