diff --git a/bin/berth-herdr-app b/bin/berth-herdr-app index 2b4deaa..5e01518 100755 --- a/bin/berth-herdr-app +++ b/bin/berth-herdr-app @@ -142,9 +142,13 @@ worker_tab() { # # labels yet, so a refusal is tried again for a while. window_wait_seconds=5 +window_open() { + command -v herdr-app >/dev/null && herdr-app status >/dev/null 2>&1 +} + window() { # ... local out deadline=$((SECONDS + window_wait_seconds)) - command -v herdr-app >/dev/null && herdr-app status >/dev/null 2>&1 || return 0 + window_open || return 0 until out=$(herdr-app "do" "$@" 2>&1); do if [ "$SECONDS" -ge "$deadline" ]; then echo "berth (herdr-app): the window refused $1: $out" >&2 @@ -154,16 +158,33 @@ window() { # ... done } -# Names whatever an independent berth's place gives it: the space and its -# first tab for one opened apart, and the tab for one opened in a tab. The -# window takes a command with no id to mean what it shows, so a berth that -# the window does not show names nothing. +# pane.rename takes a pane, which only the window's listing ties to a +# terminal. +name_pane() { #