working around MacOS X bugs: multiple “open with” context menu entries

Obviously it’s impossible for Apple to fix that quite annoying bug in their operating system that leads to double/tripple/… program entries in the “Open with…” menu. Everytime an application is updated it adds a new entry but does not remove the old one.

This makes your open-width menu look like this:

Bildschirmfoto 2013-05-12 um 18.11.38To fix this you need to run a simple command in your terminal.app:

/System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Support/lsregister -kill -r -domain local -domain system -domain user;killall Finder

This simple command will kill the double/tripple/… entries and restarts your finder.app to make the change visible. Your “Open with…” menu should now only show singular entries per application:

Bildschirmfoto 2013-05-12 um 18.14.11