From 9f75635596d0a01282156eb9e17fde6f4205c05c Mon Sep 17 00:00:00 2001 From: nicm Date: Fri, 3 May 2019 20:44:24 +0000 Subject: Allow panes to be empty (no command), output can be piped to them with split-window or display-message -I. --- format.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'format.c') diff --git a/format.c b/format.c index abcdb1d7..a3a58d92 100644 --- a/format.c +++ b/format.c @@ -2031,7 +2031,10 @@ format_defaults_pane(struct format_tree *ft, struct window_pane *wp) if ((wp->flags & PANE_STATUSREADY) && WIFEXITED(status)) format_add(ft, "pane_dead_status", "%d", WEXITSTATUS(status)); - format_add(ft, "pane_dead", "%d", wp->fd == -1); + if (~wp->flags & PANE_EMPTY) + format_add(ft, "pane_dead", "%d", wp->fd == -1); + else + format_add(ft, "pane_dead", "0"); format_add(ft, "pane_left", "%u", wp->xoff); format_add(ft, "pane_top", "%u", wp->yoff); -- cgit