IT Management Begins With Security
SecurityProNews > Articles > Operating Systems > Two Safari's
Search:
[ articles_operating_systems ]

Two Safari's



A.P. Lawrence
Contributing Writer
2004-05-11

SecurityProNews RSS Feed SecurityProNews RSS Feed


Look carefully at the image below. You see two Safari icons in the Dock (one third from the left, the other next to the app/doc divider), and also two Safari browsers open, both on the same site and page, but displaying very differently. The Font preferences are also shown, and this is what makes them different.



Note that having two Safari's in the dock is simple: just run /Applications/Safari.app/Contents/MacOS/Safari in a terminal Window. Those will share the same preferences and bookmarks though.

Although I am using Safari as the example here, this technique can actually be applied to any Mac OS X application.

Why would you want to do this? Well, for one reason so that you can have separate preferences or bookmarks. Another reason is because of application crashes which take down all your open Windows. For example, I often do things in Terminal that can crash all my terminal sessions, but not if I keep separate instances of Terminal open. You might want to do this with an Email application to keep two totally separate accounts - there are all kinds of reasons.

The copy


The first step is to make an identical copy of Safari. We'll use "ditto" for this because we may need to copy resource forks.

cd /Applications
sudo ditto Safari.app Safari2.app
cd Safari2.app/Contents
sudo mv MacOS/Safari MacOS/Safari2


Now we need to edit Info.plist. Basically, any place it says Safari will be changed to Safari2. The most important change is the

<key>CFBundleIdentifier</key>
    <string>com.apple.Safari2</string>


because that is your ~/Library/Preferences location, and we need it to be different for these two versions. Here are the other places:

<key>CFBundleExecutable</key>
   <string>Safari2</string>
<key>CFBundleName</key>
   <string>Safari2</string>


If you aren't sure whether something needs to be changed, leave it alone and try running the app. If it works as you expect, then you are fine.

One thing that won't change with Safari is its default home page. That's because Safari looks instead in ~/Library/Preferences/com.apple.internetconfig.plist for that information.

Once this is done, you can run the new Safari2 and if you change its preferences, that has no effect on the original Safari.

View All Articles by A.P. Lawrence





About the Author:
A.P. Lawrence provides SCO Unix and Linux consulting services http://www.pcunix.com

More articles_operating_systems Articles

SecurityProNews RSS Feed SecurityProNews RSS Feed


Get Your Site Submitted for Free in the World's Largest B2B Directory!

Email Address:
* URL:
*
*Indicates Mandatory Field

Terms & Conditions

iEntry Featured Services: Jayde Member Services | Forums | Freeware | Advertise with Us

Virus Warnings

Subscribe to
SecurityProNews FREE!



[ more newsletters ]

article resources
Search Articles:
[advanced search]

WebProWorld.com
Get in-touch with industry experts and leaders
Post your site for review by expert and peers
Ask Security, IT, Development and Design questions

Free Membership: Join Now!

Visit WebProWorld.com

Titan Quest Forum
The #1 Titan Quest forum
Halo 3 Forum
The best Halo, Halo 2, Halo 3 forum
Nintendo Wii
Nintendo Wii news and views
Mac Software
The best in OS X freeware
Graphics Forum
Your source for graphic tutorials
SecurityProNews.com | Breaking eBusiness News Get Your IT Questions Answered - Click Here SecurityProNews News Feeds