mirror of
https://github.com/jarun/nnn.git
synced 2024-09-11 13:06:14 +03:00
preview-tabbed: warn & prevent running on Wayland
This commit is contained in:
parent
789449a464
commit
dac5fb0af9
@ -27,6 +27,7 @@
|
|||||||
# 1. This plugin needs a "NNN_FIFO" to work. See man.
|
# 1. This plugin needs a "NNN_FIFO" to work. See man.
|
||||||
# 2. If the same NNN_FIFO is used in multiple nnn instances, there will be one
|
# 2. If the same NNN_FIFO is used in multiple nnn instances, there will be one
|
||||||
# common preview window. With different FIFO paths, they will be independent.
|
# common preview window. With different FIFO paths, they will be independent.
|
||||||
|
# 3. This plugin only works on X, not on Wayland.
|
||||||
#
|
#
|
||||||
# How it works:
|
# How it works:
|
||||||
# We use `tabbed` [1] as a xembed [2] host, to have a single window
|
# We use `tabbed` [1] as a xembed [2] host, to have a single window
|
||||||
@ -51,6 +52,10 @@ XDOTOOL_TIMEOUT=2
|
|||||||
PAGER=${PAGER:-"vim -R"}
|
PAGER=${PAGER:-"vim -R"}
|
||||||
NUKE="${XDG_CONFIG_HOME:-$HOME/.config}/nnn/plugins/nuke"
|
NUKE="${XDG_CONFIG_HOME:-$HOME/.config}/nnn/plugins/nuke"
|
||||||
|
|
||||||
|
if [ -n "$WAYLAND_DISPLAY" ] ; then
|
||||||
|
echo "Wayland is not supported in preview-tabbed, this plugin could freeze your session!" >&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
if type xterm >/dev/null 2>&1 ; then
|
if type xterm >/dev/null 2>&1 ; then
|
||||||
TERMINAL="xterm -into"
|
TERMINAL="xterm -into"
|
||||||
|
Loading…
Reference in New Issue
Block a user