Re: [dev] New utility "when"

From: Dimitris Zervas <dzervas_AT_dzervas.gr>
Date: Wed, 11 Dec 2013 19:32:54 +0200

_AT_nicholas: Sorry, I didn't see your email!
_AT_Andrew:oh, that's nice!

On Wed, Dec 11, 2013 at 7:21 PM, Andrew Gwozdziewycz <web_AT_apgwoz.com> wrote:
> On Wed, Dec 11, 2013 at 12:15 PM, Nicholas Hall <ngharo_AT_gmail.com> wrote:
>> On Wed, Dec 11, 2013 at 10:31 AM, Andrew Gwozdziewycz <web_AT_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_AT_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
>
Received on Wed Dec 11 2013 - 18:32:54 CET

This archive was generated by hypermail 2.3.0 : Wed Dec 11 2013 - 18:36:07 CET