Hello,
I use the unofficial and community Manjaro Sway edition. The swayidle
does not have sleep or suspend option. It only turns the display off, but keeps hardware and keyboard on. I need Swayidle to make the whole computer suspending after inactivity. I use the processor AMD Ryzen 7 2700X and the video card AMD Raaedon RX 5700XT.
Here is the small code in the ~/.config/sway/definitions
set $share_dir /usr/share/sway
set $config_dir /etc/sway
set $user_config_dir $HOME/.config/sway/
set $theme_dir $share_dir/themes
set $script_dir $share_dir/scripts
set $theme $theme_dir/matcha-green
set $locking swaylock --daemonize --config $theme/swaylock
set $idle swayidle -w \
timeout 10 'light -G > /tmp/brightness && light -S 10' resume 'light -S $([ -f /tmp/brightness ] && cat /tmp/brightness || echo 100%)' \
timeout 10 'exec $locking' \
timeout 10 'swaymsg "output * dpms off"' \
resume 'swaymsg "output * dpms on"' \
before-sleep 'exec $locking'
- The computer does not inactivate itself within 10 seconds. It inactivates itself within 5 minutes.
- The computer does not suspend automatically after inactivity.
The file is located in the ~/config/sway
. I believe it does not overwrite the /etc/sway/
of the unofficial and community Manjaro Sway edition.
I modified /etc/sway/definitions
to reduce Swayidle time to 10 seconds for testing, but it did not inactivate itself within 10 seconds.