On Wed, Dec 11, 2013 at 12:15 PM, Nicholas Hall <ngh...@gmail.com> wrote: > On Wed, Dec 11, 2013 at 10:31 AM, Andrew Gwozdziewycz <w...@apgwoz.com> wrote: >> I wondered if I could do it in shell, but figured it might be too >> tricky to do concisely > > $ while ! command; do continue; done; xmessage 'returned truthy' >
Yes. You can do exactly that. But you *can't* do: when -t "ssh user@host" "xmessage 'Connected'" which is the real reason I wrote this. With -t, xmessage 'Connected' will be run when you get a prompt, e.g. the command didn't "time out" / die before 5 seconds (-n <seconds> to change that). -- http://apgwoz.com