Re: NSWorkspace and unmounting USB drives
Re: NSWorkspace and unmounting USB drives
- Subject: Re: NSWorkspace and unmounting USB drives
- From: "Shawn Erickson" <email@hidden>
- Date: Fri, 11 May 2007 11:07:44 -0700
On 5/11/07, Buddy Kurz <email@hidden> wrote:
I would like to be able to unmount a USB drive after copying data to it.
When the drive is plugged in, NSWorkspace notifies my app. The device
path is "/Volumes/LaCie-Disk"
When I use [ws getFileSystemInfoForPath:devicePath ...] ,the volume
is writable but not unmountable.
[ws unmountAndEjectDeviceAtPath:devicePath] fails - not surprisingly
since the device appears to not be unmountable.
...maybe use diskutil?
[0:509] > diskutil unmountDisk
Disk Utility Tool
Usage: diskutil [mount(Disk)|unmount(Disk)|eject] <force>
[Mount Point|Disk Identifier|Device Node]
Mount, unmount or eject local disks or volumes.
force is only valid on unmount or unmountDisk.
Example: diskutil unmount /Volumes/SomeDisk
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden