Skip to content

Latest commit

 

History

History
26 lines (18 loc) · 538 Bytes

create-a-global-gitignore-on-macos.md

File metadata and controls

26 lines (18 loc) · 538 Bytes

Create A Global Gitignore On MacOS

Category: Git

In certain situations, you may have OS specific files across many different projects that you do not want to add to version control. To do this, create a file called .gitignore_global on your machine.

Create the file in your home directory:

touch ~/.gitignore_global

Add system entries to this file:

# Mac
.DS_Store
.AppleDouble
.idea

Configure git to use .gitignore_global:

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