Tuesday, April 9, 2013
OSX Cmd: Getting Rid of "Open With" duplicates
You right-click icon in the Finder, choose "Open With", and a submenu pops up with an absurd number of duplicate entries.
The duplicate entries in the "Open With" submenu are caused by some corruption of the Launch Services database. The lsregister command, which is buried many layers under the /System/Library folder, will rebuild the database if you invoke it with the right options.
Here’s a on how to fix it (and you can add to your .bashrc):
# Quick way to rebuild the Launch Services database and get rid
# of duplicates in the Open With submenu.
alias fixopenwith='/System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Support/lsregister -kill -r -domain local -domain system -domain user'
Now you can get rid of the duplicates from the Terminal by running:
fixopenwith
You may need to follow that up with a:
killall Finder
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment