0

As i am newbie on mac and .dmg for me is a black box. And i don't know is it possible rewrite some files in it like on Windows.

Someone can explain how user can update my app for one click: "There new version available. Do you want to install it now?" - [OK] [Cancel]

user3444737
  • 41
  • 1
  • 7

1 Answers1

0

A .dmg container is read-only (typically, you can make them writable though). The recommended behaviour with an OS X application is to do one of two things:

  1. Put a note in the .dmg to move the application to Applications (see: Creating nice dmg "installer" for Mac OS X)
  2. Auto-move the Application on first run, however you need to be incredibly explicit to the user about what's happening and where they need to go to load the application in future.

I always go for option 1, it's clear and concise and there's a wealth of other software that go for it so it's understood by most OS X users.

In terms of doing an autoupdate, once it's in the user filesystem you can do it a number of ways. There's the Sparkle Framework, you can build a simple HTTP request service to grab the new .app bundle and copy it into place and then restart. Sparkle is good, well tested and very popular for OS X autoupdating, if you're going cross-platform then build the HTTP service.

Community
  • 1
  • 1
Nicholas Smith
  • 11,642
  • 6
  • 37
  • 55