Files
sxmo-utils/scripts/core/sxmo_killwindow.sh
ArenM 228b936f08 Remove useless dirname calls
sxmo_common.sh is in $PATH so we can let the shell handle finding it.
Running a script with sh -x <scriptname> can be handy for debugging, but
doesn't work with these because $0 doesn't get set to the full path to
the script.

Signed-off-by: Willow Barraco <contact@willowbarraco.fr>
2023-08-29 19:03:21 +02:00

13 lines
284 B
Bash
Executable File

#!/bin/sh
# SPDX-License-Identifier: AGPL-3.0-only
# Copyright 2022 Sxmo Contributors
# include common definitions
# shellcheck source=scripts/core/sxmo_common.sh
. sxmo_common.sh
case "$SXMO_WM" in
sway) swaymsg kill;;
dwm) xdotool windowkill "$(xdotool getactivewindow)";;
esac