Hi,

Thanks.  I managed this to determine if something was typed -

has_text=$(tmux capture-pane -p | tac | sed '/^$/d' | head -n 1 | awk
'{print NF-1}')

(probably don't need the sed to remove esc seq)

take care,
-mark


On Thu, Aug 15, 2019 at 11:50 AM Nicholas Marriott <
[email protected]> wrote:

> You could probably script it with capture-pane and grep and maybe the
> cursor_y format.
>
> On Thu, 15 Aug 2019, 16:46 M Kelly, <[email protected]> wrote:
>
>> Hi,
>>
>> Anyone know if its possible to know within tmux if there is any text
>> currently present on the command-line ?
>> (ie something other than spaces after the shell prompt)  In eiither root
>> or copy-mode.
>>
>> thx for everything tmux,
>> -mark
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "tmux-users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to [email protected].
>> To view this discussion on the web, visit
>> https://groups.google.com/d/msgid/tmux-users/CAD5ox-E0uGJxTKWTaycF%3DvQgDM_RYvG7AErLhfcnNVZ_HusJKg%40mail.gmail.com
>> <https://groups.google.com/d/msgid/tmux-users/CAD5ox-E0uGJxTKWTaycF%3DvQgDM_RYvG7AErLhfcnNVZ_HusJKg%40mail.gmail.com?utm_medium=email&utm_source=footer>
>> .
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"tmux-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web, visit 
https://groups.google.com/d/msgid/tmux-users/CAD5ox-H8QXet8dE2GZ9bhcp5taj2uTcw2O1-wq9c6uHrRwU5SA%40mail.gmail.com.

Reply via email to