Is there a way to force Finder to treat a folder named whatever.service as a folder and not a service?

To make it very clear it's easy to recreate my issue. I just created a new folder, rename it to name.service and I can no longer open the folder. Also, the file info does not let me change the kind or choose a different program to open with.

  • 1
    Does Right click (Ctrl-click) and "Show Package Contents" not do what you want? – Doon Oct 24 '11 at 19:32
  • @Doon, Not when we need to use it in an output path for other software. – bejumi Oct 25 '11 at 13:26

"Directories with file extensions" (bundles) are a common way on OS X to bundle stuff consisting of multiple files into a single package, such as kernel extensions, iWork files (before iWork 09), iMovie projects, applications, etc.

You usually can edit an application's Info.plist file to remove the definition of the offending bundle it defined — e.g. .theme for iMovie.

As .service is defined for system Services (see e.g. /System/Library/Services — access them from the application menu bar item, then select Services), you'd probably break stuff by removing this definition.

If you're feeling lucky:

Open /System/Library/CoreServices/CoreTypes.bundle/Contents/Info.plist for example using Xcode (after changing the file and directory permissions using chmod in Terminal) and remove the offending entry in the CFBundleDocumentTypes array.

enter image description here

You need admin permissions to do this. I recommend having current backups. It's possible something breaks if this association isn't purely cosmetic.

  • I wonder what disabling them through RCDefaultApp does. – slhck Oct 24 '11 at 20:13
  • @slhck Run opensnoop and see what happens on your disk when you change that setting. – Daniel Beck Oct 24 '11 at 20:15
  • I tried commenting out the entry in CoreTypes.bundle/Contents/Info.plist, but it didn't affect the way .services are treated by Finder. – Lri Oct 24 '11 at 21:22
  • @Lri Have you updated the Launch Services database as described in the linked topic? I forgot to mention it again here. – Daniel Beck Oct 25 '11 at 4:41
  • 2
    I should've mentioned this earlier, but both times I tried modifying CoreTypes.bundle/Contents/Info.plist it nearly locked me out of OS X. No graphical applications launched after a normal login. Restoring CoreTypes.bundle from a Time Machine backup appeared to fix it. (I'm still pretty puzzled why that happened — I didn't change the permissions or owner of the Info.plist and shouldn't have invalidated it.) – Lri Oct 25 '11 at 6:31

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.