Multiplying Mac Opera — Operiply, the automated profile maker…
Saturday, 13. June 2009, 11:44:23
When I get a new build, I often make 3 copies of the Opera.app package, one build (Peregrine) running my main profile, one build (Munin, old Opera users know the history of that name) running an optimised benchmarking profile, and one build (Virgin) running a freshly deleted clean profile. So I made a ruby script to automagic several build which:
- Copy the Opera.app direct from the DMG install container
- Edit / add PrefsSuffix with the correct directory prefix
- Add nicer icons ;-)
- Rename Opera.app with profile+build number, to give something like Opera.Peregrine6477.app
- Update in 1.0c+: Optionally edits CFBundleName in Info.plist to modify the Opera Application menu name. This is OFF by default as I prefer editing opera:config#UserPrefs|Title to see the build number.
- If a profile has the name "Virgin" in it, it will delete all preferences/caches to ensure a new clean profile. This is really important when issue hunting, and not having to do this manually for each build makes lazy testing easier!
- Optionally: a copy of Trimmit is bundled which can strip out extra resources, remove unused platform binaries etc. so Opera takes less space - this is OFF by default. You need to edit the script to enable it.
Instructions
Download the attachment and open Operiply.dmg. Just drag the operiply.app wherever you want. You then simply drag-n-drop an Opera.app package on the operiply icon. You can drag straight from the Opera install DMG, making this really fast as you just open the DMG from the volunteer server instead of saving it, then drag Opera to Operiply instead of to Applications. It will output modified builds to the desktop (you can change this); move them wherever you store your builds.
Tweaking
-
operiply.app/Contents/Resources/buildlist.txtcontains a line-delimited list of names for builds — edit that to your needs. It can handle having only a single build name. By default it creates Peregrine, Munin & Virgin. The peregrine betas default to "10", so just add/edit that to get a classic peregrine beta build. Leave this file blank and you will get a normal Opera profile - use with caution if you don't want to upgrade a 9.x profile! - The script can be modified at
operiply.app/Contents/Resources/script. The first section has some constants you can change:- $PURGEVIRGIN turns on/off the deletion of virgin profile prefs/caches.
- $CHANGEPLIST turns on/off the CFBundle name changer.
- $LOSEWEIGHT turns on/off the Trimmit app stripper
Download: Operiply.dmg
Future Updates
This does what I need, but I think one easy thing to add would be a profile backup option - so you can easily roll back if a beta build nuked your profile
Geek details
Ruby is really wonderful for this kind of stuff. I use XmlSimple to parse the .PLIST file to get the build number.
I use Platypus for the package, which wraps scripts & resources into an easy to use OS X application as if by magic.








Chas4 # 14. June 2009, 06:39
mabdul # 14. June 2009, 12:51
FataL # 23. June 2009, 21:13
non-troppo # 26. June 2009, 20:34
mabdul: not sure - my tool doesn't make a munin install for you, still need a custom prefs.ini. I could share mine but it is not really for public consumption.