How to prevent HDIUTIL from opening a finder window when mounting a dmg?

6

1

When I mount a DMG image with

hdiutil -noautoopen

and try to suppress the finder window with any and all command line arguments to HDIUTIL it still open's a Finder window. There must be a way to prevent this... am I wrong?

ClintM

Posted 2011-03-01T14:47:35.817

Reputation: 207

Since I´ve just tried hdiutil attach -noautoopen /path/to/read-only.dmg and it worked fine, could you please specify what kind of .dmg you are trying to open (read-only or not, which format)? – Asmus – 2011-03-01T16:32:44.083

I'm specifically testing with this one... http://airdownload.adobe.com/air/mac/download/latest/AdobeAIR.dmg

– ClintM – 2011-03-01T16:56:03.257

Answers

10

In Mountain Lion (10.8.3), none of the -noautoopen options worked. The -nobrowse option does, though:

hdiutil attach -nobrowse /path/to/file.dmg

kipkoan

Posted 2011-03-01T14:47:35.817

Reputation: 351

This should be the accepted answer. – Meow – 2016-08-01T05:40:47.263

1

By default the Finder will always auto open read only images. Try to pass -noautoopenro!

MacLemon

Posted 2011-03-01T14:47:35.817

Reputation: 492