Mounting

Joined
Jan 31, 2006
Messages
10
Reaction score
0
Silly question, but if i just ejected say my HDD without meaning to, is there an applescript i can run to remount it, or do i need to unplug it then plug it bk in?
Thanks in advance - Anthony
 

Ric

Joined
May 14, 2004
Messages
4,260
Reaction score
5
Hi there,

sorry missed this post...

This should do it, I haven't tested it yet will do tomorrow...

Code:
property diskname : "your disk"

tell application "Finder"
if not (exists the disk diskname) then
do shell script "diskutil mount `disktool -l | grep 'your disk' | sed 's/.*\\(disk[0-9s]*\\).*/\\1/'`"
delay 1
end if
end tell

replace the "your disk" with your disk name...

The simplest way is to turn the drive off, then back on again, and it will reappear.

I'll check the script tomorrow...

regards

Ric
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top