#15 open
Jon Hancock

disable finder integration

Reported by Jon Hancock | October 13th, 2008 @ 07:22 AM

I would like to disable the feature that launches gitx from clicking on a git directory. This feature get in my way to navigate into the directory structure with the finder and other tools.

Is there a way to turn this feature off?

Comments and changes to this ticket

  • Pieter de Bie

    Pieter de Bie October 13th, 2008 @ 08:48 PM

    • State changed from “new” to “open”

    You can edit the plist to remove the format. Other than that, no, not yet.. I'll look into it to see if that's easily done as an option. In that case, we can add it once the prefpane gets in

  • Tom Locke

    Tom Locke December 9th, 2008 @ 03:18 PM

    I have removed CFBundleDocumentTypes from /Applications/GitX.app/Contents/Info.plist but that doesn't seem to have fixed the problem. Do I need to do something to tell the Finder about this change?

  • Pieter de Bie

    Pieter de Bie December 10th, 2008 @ 03:09 PM

    I'm not sure, really -- I never tried it. Unregistering an association might be different than just removing the part from the plist.

  • Stephen Bannasch

    Stephen Bannasch February 7th, 2009 @ 09:32 PM

    Tom,

    As soon as I apply this patch and clean and rebuild the app:

    https://gist.github.com/1c408624...
    
    

    My directories with names ending with the suffix ".git" change in the Finder from Applications back to directories.

    I only have one copy of the GitX app on my system:

    ./gitx.git/builds/Releases/GitX.app

    Perhaps you also have another GitX app with the string "git" in the CFBundleDocumentTypes element on your system.

    See this email for how I build a GitX that doesn't have this problem:

    http://groups.google.com/group/c...

  • Johannes Gilger

    Johannes Gilger February 7th, 2009 @ 10:15 PM

    Well, might not be directly related, but I would name directories "foo.git" only if they are bare, i.e. have no worktree attached. This is, of course, just a convention, but if you stick with you're always gonna know which git-directories are bare, and which are not. And since there is not that much need to browse bare repos with the finder (imho) it's ok. Even if you want to browse, you can right-click and select "Show package content".

    Just my take on your problem

  • Stephen Bannasch

    Stephen Bannasch February 8th, 2009 @ 12:36 AM

    Johannes,

    That's a reasonable convention but so is mine -- at least for me.

    I have a bunch of external projects I am tracking, most are git and a reasonable percentage are git clones of svn repos, some are hg clones, a just a few bazzar.

    By adding a suffix to the dir name when I am in the project I know immediately whether to update using git svn or just git.

    What doesn't work as well for me is having all these directories treated as applications by the Finder.

    I've done a little work to add a new option to the Integration pref pane

    Enable Finder Integration of '.git' files
    
    

    But I've found that even if I just open and save

    English.lproj/Preferences.xib
    
    

    without making any changes it appears to end up corrupted,

    This invalid string is added to the IBDocument.PluginDependencies

      {{211, 334}, {400, 74}}

    This is a diff showing what happens when I open it in IB and then immediately save it without making any changes:

    http://gist.github.com/60080

    Particularly note lines 29 and 82

    You can see some differences in the environment from the diff: I'm using IB v7.03 and the xib was made with 7.02.

    But I haven't used Cocoa/XCode much and am not sure if that's the root of the problem -- seems unlikely.

  • Johannes Gilger

    Johannes Gilger September 8th, 2009 @ 10:29 PM

    • Tag changed from finder to finder, integration

    Although there haven't been any more complaints I think it wouldn't be too hard to make this user-switchable from within GitX. I did some googling today (took a while), but I found this:

    1. Whenever you change the Info.plist in /Applications/GitX.app/Contents to include/not-include the dict with CFBundleTypeExtensions in it you'll have to issue the following command afterwards (and open a new Finder-window to see the result):
      /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/LaunchServices.framework/Versions/A/Support/lsregister -r -f /Applications/GitX.app to load or /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/LaunchServices.framework/Versions/A/Support/lsregister -u -r -f /Applications/GitX.app to unload the .git-directory association.
    2. If that doesn't work you probably have a GitX-key somewhere in ~/Library/Preferences/com.apple.LaunchServices.plist which you'll have to delete.

    Obviously it would suck if GitX would have to rewrite its own Info.plist in order to change that setting. Writing/Deleting an entry to the ~/Library/Preferences would be much nicer, but I haven't found out how to reload that without reloading a bunch of other stuff.

  • Pieter de Bie

    Pieter de Bie September 9th, 2009 @ 10:25 AM

    Yeah, that's the hack I was talking about :) I really don't like
    having to rewrite our own internal files, so I would rather wait until
    we can d

  • Richie Vos

    Richie Vos September 18th, 2009 @ 08:02 PM

    I just started using Gitx the other day and it seemed really cool, but I just uninstalled it since I was trying to open a folder in a directory I wanted named something.git and the file open dialog wouldn't let me browse into it due to Gitx taking over directories that end in .git

  • Phil Crosby

    Phil Crosby September 18th, 2009 @ 09:53 PM

    @Richie Vos

    A workaround is to rename your git repository's folder to not have a .git extension.

  • meowsqueak

    meowsqueak July 1st, 2012 @ 07:40 AM

    • Milestone order changed from “0” to “0”

    This 'feature' is a complete show-stopper for me and I want to be rid of it - please advise how to completely uninstall GitX and restore original Finder behaviour for .git directories.

  • danmurphy

    danmurphy October 2nd, 2017 @ 05:52 PM

    The classified ads website Donedeal.ie run a featured charity scheme where every two months they very kindly donate a percentage of profits to a selected ...

    donedeal

  • Martha Wilson

    Martha Wilson February 18th, 2018 @ 02:40 PM

    Well, don't get too excited, my javascript skills consist of typing "javascript blah blah" into Google over and over, and making sweeping generalizations from other languages I know ;). Double click is supposed to select the whole "sub-hunk", i.e. a group of contiguous add/del lines, and their surrounding context. Let me know if it's not. Think of it as "this block of changes, who cares what diff thinks". This is the granularity git-add --interactive uses, btw. Since there will already be a "[Stage]" button for each full hunk, there's no need to have another method to select it in entirety.
    fnaf games, let's try to play now.

  • Emily12

    Emily12 May 9th, 2018 @ 11:15 AM

    Thank you for posting such a great article! I found your website perfect for my needs. minion rush It contains wonderful and helpful posts. Keep up the good work!

  • Quentin0

    Quentin0 May 17th, 2018 @ 12:32 PM

    Actually, It's adding a suffix to the dir name when I am in the undertaking I know promptly whether to refresh utilizing git svn or just git. Some more detail i want to know about this project. However, I try to get quality papers starting from but there will be good and useful stuff found in this site.

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

GitX is the nice-looking gitk clone for OS X

Referenced by

Pages