Fwd: Q: use '-C' flag with 'git config --global'

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

 



Hi,

I'm running into issue that if I run `git -C <pwd/to/showmax/project>
config --global user.email` I don't get expected email.
Expected: tomas.prochazka@xxxxxxxxxxx
Got: tomas.prochazka5d@xxxxxxxxx

My config contains a little catch:

~/.gitconfig
```
[user]
       name = Tomáš Procházka
       email = tomas.prochazka5d@xxxxxxxxx

[includeIf "gitdir:~/Workspace/Showmax/"]
   path = ~/Workspace/Showmax/.gitconfig
```
~/Workspace/Showmax/.gitconfig
```
[user]
    name = Tomáš Procházka
    email = tomas.prochazka@xxxxxxxxxxx
```

I get correct email setting if I run command without `--global` flag.
But What I understand from the [`git-config`
docs](https://git-scm.com/docs/git-config#_description) if no flag is
passed the values are read from system, global and local.

If I run commands one by one, No returns the ~correct~ expected email:

~ $ git -C <pwd/to/showmax/project> config --system user.email
~ $ git -C <pwd/to/showmax/project> config --global user.email
tomas.prochazka5d@xxxxxxxxx
~ $ git -C <pwd/to/showmax/project> config --local user.email

Am I missing something?
Thanks for the answer.

Regards
Tomáš Procházka




[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