Question

I'm having a difficult time finding any decent documentation for packaging on OSX. My package needs to run a Python script that will do some launchd magic right after the app is installed. I tried using -s scripts with packagemaker and put my script in the directory scripts, but I had no luck. Is there something I'm missing? More importantly, where is all the packagemaker documentation? How can I get my Python script to run? The only thing I've seen is this, which is way outdated and doesn't cover the command line version.

I don't want to use the GUI; it makes my life too difficult.

Was it helpful?

Solution

I've resolved this issue.

  1. The script needs to be named postflight and have a proper shebang line.
  2. The script needs to exit with specific status codes (0 for success, which is the default, I believe).
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top