Make sure the image files you are using are in the $PROJECT_DIR/$PROJECT_NAME/ directory! SetFile -a C "$BUILT_PRODUCTS_DIR/$PRODUCT_NAME.dmg" Rez -append "$dir/tmpicns.rsrc" -o "$BUILT_PRODUCTS_DIR/$PRODUCT_NAME.dmg" Rm -f "$BUILT_PRODUCTS_DIR/$PRODUCT_"ĭeRez -only icns "$dir/some_other_image.png" > "$dir/tmpicns.rsrc" Hdiutil convert "$BUILT_PRODUCTS_DIR/$PRODUCT_" -format UDZO -imagekey zlib-level=9 -o "$BUILT_PRODUCTS_DIR/$PRODUCT_NAME.dmg" Rm -f "$BUILT_PRODUCTS_DIR/$PRODUCT_NAME.dmg" #unmount the temp image file, then convert it to final image file Script 3 (Make Final Disk Image Script): #!/bin/bashĬp "$PROJECT_DIR/$PROJECT_NAME/some_other_image.png" "$dir/" The above measurement for the window work for my project specifically due to the size of my background pic and icon resolution you may need to modify these values for your own project. In this example, the bash variable "size" contains the size in Kb and the contents of the folder in the "source" bash variable will be copied into the DMG: hdiutil create -srcfolder "$ It must be larger than the result will be. You may have to reboot after this change (it doesn't work otherwise on Mac OS X Server 10.4).Ĭreate a R/W DMG. It is required for the AppleScript to work. Make sure that "Enable access for assistive devices" is checked in System Preferences>Universal Access. After lots of research, I've come up with this answer, and I'm hereby putting it here as an answer for my own question, for reference:
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |