I needed to be able to set a system clock remotely, and ran into the same problem, with needing to send the authentication password to the shell command. Here is what I use to get around this:

  set the shellCommand to "/bin/sh"
  put "#!/bin/sh" & cr into tScript
  put "pw=" & myPassword & cr after tScript
  put "echo $pw | sudo -S date " & tDate & tTime & cr after tScript
  put shell(tScript) into tCheck

myPassword is a variable containing the current user's password. It would be a good idea to store this encrypted somewhere. You will need to replace everythig after the "sudo" on the fourth line, with whatever shell script you want to execute.

Cheers,
Sarah

On 17 Jan 2004, at 6:15 pm, [EMAIL PROTECTED] wrote:

I've been using the Shell() command quite a lot for a number of unix tasks that I need to do in my app. It works great, except in one case. It appears that if I launch a shell() call to a unix command and that unix command requires Mac OS X authentification (which spawns a popup asking for username/password), Revolution hangs after the popup is dismissed.

Can anyone think of a way around this? I'm positive that it's the authentification popup that's the issue (I can even hit CANCEL on the popup and Rev will still hang) It's like the shell() command losses control at that point and the popup never gives it back to the Rev process or something.
_______________________________________________
use-revolution mailing list
[EMAIL PROTECTED]
http://lists.runrev.com/mailman/listinfo/use-revolution





_______________________________________________ use-revolution mailing list [EMAIL PROTECTED] http://lists.runrev.com/mailman/listinfo/use-revolution

Reply via email to