u6f6o u6f6o - 1 year ago 97
Git Question

Is "tags" a reserved keyword in git?

One of my projects has a sub folder called "tags". As it looks like, this folder is ignored by git although I've not defined it in my .gitignore file.

So I guess there is a list of "keywords" like "tags" that is ignored by git on default?

Here is the content of the .gitignore file

# Java: https://github.com/github/gitignore/blob/master/Java.gitignore

# Package Files #

# IDEA: https://github.com/github/gitignore/blob/master/Global/IntelliJ.gitignore


# Mac OS X: https://github.com/github/gitignore/blob/master/Global/OSX.gitignore


# Thumbnails

# Files that might appear on external disk

# Gradle

# Leiningen and others

Answer Source

tags is a good candidate for a global ignore rule because of its use by the ctags command.

ctags generates an index of identifiers in your source code and writes them to a file called tags, which vi uses to quickly jump to the definition of the identifier under your cursor when you press ^]. For this reason, lots of source directories tend to contain a tags file that is not of interest to version control.

Do you have a global ignore file set up? An answer to this question suggests:

git config --get core.excludesfile

to find out.

And reading further down the answers in that other question: also $XDG_CONFIG_HOME/git/ignore and $HOME/.config/git/ignore

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download