Git Conditional Includes Question (possible bug?)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

I am attempting to use Git conditional includes, but it does not seem to work for me. Can you please help me find out what I’m doing wrong?

[Expectation]
When I run `cd ~/colton/github/coltonhurst.com` (this is a valid git repo) and then run `git config user.email`, I expect ‘colton@xxxxxxxxxxxxxxx’ will be returned.

[Actual Result]
When I run `cd ~/colton/github/coltonhurst.com` (this is a valid git repo) and then run `git config user.email`, nothing is returned.

Is this correct behavior? It seems like Git is not recognizing my `.gitconfig` file, and the configuration is not set correctly.

I’m using git version 2.30.0 with on a Mac version 11.1 (Big Sur)
My main shell is: fish, version 3.1.2
I also have tested & have the same issues using: GNU bash, version 3.2.57(1)-release (x86_64-apple-darwin20)

To reproduce, I have the two files at the listed locations:

`.gitconfig` at: `~/`, with the following contents:

[user]
	name = Colton Hurst

[includeIf "gitdir:~/colton/github"]
	path = ~/colton/github/.gitconfig

[includeIf "gitdir:~/colton/sourcehut"]
	path = ~/colton/sourcehut/.gitconfig

`.gitconfig` at: `~/colton/github`, with the following contents:

[user]
	name = Colton Hurst
	email = colton@xxxxxxxxxxxxxxx

This is the output from `git bugreport`:

[System Info]
git version:
git version 2.30.0
cpu: x86_64
no commit associated with this build
sizeof-long: 8
sizeof-size_t: 8
shell-path: /bin/sh
uname: Darwin 20.2.0 Darwin Kernel Version 20.2.0: Wed Dec  2 20:39:59 PST 2020; root:xnu-7195.60.75~1/RELEASE_X86_64 x86_64
compiler info: clang: 12.0.0 (clang-1200.0.32.28)
libc info: no libc information available
$SHELL (typically, interactive shell): /bin/zsh


Thank you for reading,


cdh





[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux