OS X will automatically associate programs to handle file types they are built to read. For instance, if you have a file with a non-standard extension such as .xyz, then if you double-click it OS X will likely ask you to select an application to use; however, if you have installed an application that can handle .xyz file types, then OS X will detect this and launch this application when you open a file of this type. While convenient, if you would like to unlink this association then you will have to jump through a couple of hoops.
This approach can be done on two levels: file-specific, or system-wide.
If you have a specific file for which you would like to change the default application that is launched when you open it, you can do so:
- Select the file in the Finder and press Command-i to get info on it
- Go to the Open With section and select an application, or choose “Other” from the drop-down menu and locate one on-disk.
If you would like to unlink a file so the system does not launch a program when you open the file, then instead of choosing a program from the list, perform the following action:
- Select “Other” from the drop-down menu.
- Choose “All Applications” from the “Enable” menu at the bottom of the Open dialogue that appears.
- Navigate to the Macintosh HD > System > Library > CoreServices
- Select the Finder in this folder as the program to use for opening the file.
The above procedures will change the default application for opening a file, or if the Finder is used, will effectively unlink the file from a default application; however, this will only affect the given file. To make this change system-wide, you can click the “Change All” button in the file’s information window, which will update the system’s launch services to handle all files of this type in the manner specified.
Another approach for having a document be unlinked and have the system require you ask for a program to handle it each time you launch it, is to create an Automator workflow that will ask you which program you would like to open the file in:
- Create a new Application workflow in Automator
- Locate and drag the “Open Finder Items” action to the Workflow area
- Click the action’s Options button and check “Show this action when the workflow runs”
- Save the workflow as an application called “Launcher” in your Utilities folder (though you can save it anywhere and with any name)
With this application created, go back to your document and change its default handling program as described previously, but instead of using the Finder as the application to open with, choose the newly created “Launcher” program. Now when you open any documents of this type the system will open the Launcher and ask you to choose a program from the drop-down menu.
What about rebuilding the Launch Services database? For instance, with Cocktail
On the other hand, “How to change or unlink a files” should read “How to change or unlink files”.
This article is not about problems with the launch services, but about changing a pre-assigned application association that is set up by the launch services. Resetting the launch services will only result in the system setting up this association with some default application again.