Where is .gitignore_global saved on OS X?

I have created a .gitignore_global file by running

git config --global core.excludesfile ~/.gitignore_global

However, I can’t find the file in question in my file system? Where was it saved?

  • Git branching while files are opened
  • git: publish from certain commit onward, keeping earlier history private, but provable
  • Undo unstaged modifications for a single file in git
  • Hide db's password with multiple git repository in Rails application
  • How to merge several Git repos into one and interleave histories
  • How to update npm modules, ignoring a git repo
  • SourceTree can't push to Bitbucket
  • How do I get the Git log for a specific branch only?
  • Maintain a separate branch for each platform
  • Bundling version control software with product
  • SVN:externals equivalent in GIT?
  • com.apple.dt.Xcode.sourcecontrol.Git overloading CPU
  • 2 Solutions collect form web for “Where is .gitignore_global saved on OS X?”

    I have created a .gitignore_global file using the command […]

    The command

    git config --global core.excludesfile ~/.gitignore_global
    

    does not create any file. In other words, if ~/.gitignore_global did not exist beforehand, running that command does not create it.

    The semantics of that command are

    Set the path of the user-level (because of the --global flag) Git ignore file to ~/.gitignore_global.

    In terms of implementation, that command adds the following entry

    excludesfile = ~/.gitignore_global
    

    under the core section of your ~/.gitconfig file, which is the default path for the user-level config file. See this section of the Pro Git book for more details about the three levels (system, user, repository) of Git configuration files.

    You can find the file location by running this command in Terminal:

    git config --get core.excludesfile
    
    Git Baby is a git and github fan, let's start git clone.