17

gitconfig(1):

If not set explicitly with --file, there are four files where git config will search for configuration options:

...

$(prefix)/etc/gitconfig

    System-wide configuration file.

What is $(prefix) on $(prefix)/etc/gitconfig?

talles
  • 14,356
  • 8
  • 45
  • 58

1 Answers1

15

The prefix environment variable git was compiled with. Usually, it's /usr/local, so the path is /usr/local/etc/gitconfig.

More information can be found in the INSTALL file in the git repository.

Femaref
  • 60,705
  • 7
  • 138
  • 176
  • Can you please elaborate? … What do you mean by “git was compiled”? Do you mean installed? How is the variable that “git was compiled with” specified? How does one see the value of this variable? How does one change it? – chharvey Aug 04 '20 at 03:05
  • you supply it to the `configure` script before compiling git. – Femaref Aug 05 '20 at 13:31
  • @Famaref Can you explain it like I have no idea what you’re talking about? Please edit your answer with more details. It’s worth an upvote. – chharvey Aug 07 '20 at 15:55
  • have a look in the git repository in the INSTALL file. Details the build process. – Femaref Aug 14 '20 at 07:47