diskutil in shell script not working
diskutil in shell script not working
- Subject: diskutil in shell script not working
- From: "Jack (Shekhar) Stoller" <email@hidden>
- Date: Thu, 30 Mar 2006 15:14:05 -0500
- Thread-topic: diskutil in shell script not working
Hello,
In Tiger 10.4.5 I¹m trying to write an Applescript that finds a mounted
floppy disk and erases it using the diskutil command. This is my first
attempt with the do shell script command.
I tried this command in Terminal:
diskutil eraseVolume HFS+ 'untitled' '/Volumes/untitled'
and it worked perfectly. Dismounts, erases, and remounts.
Then I tried it in an Applescript as:
do shell script "diskutil eraseVolume HFS+ 'untitled' '/Volumes/untitled'"
The floppy spins a bit, stops, spins some more, then an error message is
displayed:
error with erase Could not unmount disk (-10000)
Then then drive spins some more and the volume dismounts. Remounting it
shows that it was not erased.
The Applescript is saved as an application, but the same thing happens if I
run it in Script Debugger.
Can this be made to work?
Thanks,
Jack
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden