• 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: Path to Disk Image
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Path to Disk Image


  • Subject: Re: Path to Disk Image
  • From: Martin Orpen <email@hidden>
  • Date: Fri, 02 Sep 2005 22:07:21 +0100

on 2/9/05 19:16, Luther Fuller at email@hidden wrote:

> When one does a Get Info on a disk mounted from a disk image (.dmg)
> file, the Get Info window shows the item Disk Image: followed by the
> path to the disk image file that mounted the disk. And this is
> exactly the info I need to get via an AppleScript command.
>
> Does anyone know how to do this?

Hacking aliases is a messy but useful way of getting this sort of
information. I use this as a method of getting IP addresses from mounted
servers.

Make an alias of the mounted disk and then use strings to look at the rsrc
information:

    strings /path/to/Desktop/Target\ alias/rsrc | head

And you should see both Mac and Unix paths as the last couple of lines.

If you know the boot disk name and username then you'll be able to return
just the paths using something like:

   | awk 'Macintosh\ HD:|username\//'

Regards

--
Martin Orpen

 _______________________________________________
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

  • Follow-Ups:
    • Re: Path to Disk Image
      • From: Laine Lee <email@hidden>
References: 
 >Path to Disk Image (From: Luther Fuller <email@hidden>)

  • Prev by Date: Re: Determining if a scripting addition is installed
  • Next by Date: Re: How to determine whether launched automatically at login
  • Previous by thread: Re: Path to Disk Image
  • Next by thread: Re: Path to Disk Image
  • Index(es):
    • Date
    • Thread