• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: 'do shell script'-bug?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: 'do shell script'-bug?


  • Subject: Re: 'do shell script'-bug?
  • From: christian vick <email@hidden>
  • Date: Sat, 12 Jan 2002 08:58:36 +0100

on 1/12/02 6:29 AM, christian vick at email@hidden wrote:

> on 1/12/02 5:53 AM, Jon Pugh at email@hidden wrote:
>
>> At 4:31 AM +0100 1/12/02, christian vick wrote:
>>> If i use...
>>>
>>> tell application "Terminal"
>>> do script with command "echo password | sudo bless -folder9
>>> \"/Volumes/9disk/System Folder 922\" -setOF"
>>> end tell
>>>
>>> ... it works. But if i use...
>>>
>>> do shell script "echo password | sudo bless -folder9 \"/Volumes/9disk/System
>>> Folder 922\" -setOF"
>>>
>>> ... i get an error "sudo: bless: command not found".
>>> Is this a bug or am i missing something?
>>
>> Could it be because you had previously entered a password for sudo in the
>> terminal that was running,
> No, it works in Terminal providing the password with 'echo'. I didn't type the
> password manually.
Ok, i didn't realize that the Terminal (sudo?) still holds my password when
i close the window. The proper syntax is:

tell application "Terminal"
do script with command "echo 'password' | sudo -S bless -folder9
\"/Volumes/9disk/System Folder 922\" -setOF"
end



>> but not in the process running the script
>> (ScriptRunner, I believe it is called)? That could account for it.
> I execute it directly from Script Debugger. Making it an Applet or launching
> from ScriptRunner didn't help (would be strange if it does).
>
> If i use...
>
> do shell script "bless -folder9 \"/Volumes/9disk/System Folder 922\" -setOF"
>
> ... then i get "zsh: command not found: bless".
But this problem still remains.



Greetings
cris :-)
--
English is my second language.


References: 
 >Re: 'do shell script'-bug? (From: christian vick <email@hidden>)

  • Prev by Date: Re: downgrading from AS 1.7 to AS 1.6 in OS 9.2.2
  • Next by Date: Re: 'do shell script'-bug?
  • Previous by thread: Re: 'do shell script'-bug?
  • Next by thread: Re: 'do shell script'-bug?
  • Index(es):
    • Date
    • Thread