19.1.2022 |

Global Git Ignore files

Projects should not care about what OS or editor you are using. Git ignore files are perfect for excluding file you don't want inside your git history. One of those files is usually your editor configuration. As this is rarely project specific and may include personal settings which won't help other developers. But adding your personal editor of choice to every project you work on is tedious. In those cases a global git ignore file is a perfect solution.

As part of your users git config file you configure a global git ignore file. (While writing this I saw that it maybe also works by placing the ignore file at $HOME/.config/git/ignore. But I haven't tested that yet)

	excludesfile = /Users/jansauer/.gitignore_global

In that file you can then add the patterns you want ignored in all projects.

# Folder view configuration files

# Thumbnail cache files

# Files that might appear on external disks

# Visual Studio Code

# JetBrains
Jan Sauer
Zur Übersicht

Mehr vom DevSquad...

Jörg Herbst

Fullscreen im Firefox

Sophia Brandt

Git: Stelle den Kommentiercharakter auf "auto"