# Setting the \`.gitconfig\` file to be used by Pkg/Pkg3

**URL:** https://discourse.julialang.org/t/setting-the-gitconfig-file-to-be-used-by-pkg-pkg3/10795
**Category:** General Usage
**Tags:** windows, git
**Created:** [May 9, 2018, 12:25pm UTC](https://discourse.julialang.org/t/setting-the-gitconfig-file-to-be-used-by-pkg-pkg3/10795 "2018-05-09T12:25:50Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![digital\_carver](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/digital_carver/32/33818_2.png) [@digital\_carver](https://discourse.julialang.org/u/digital_carver)
#### Post date: [May 9, 2018, 12:25pm UTC](https://discourse.julialang.org/t/setting-the-gitconfig-file-to-be-used-by-pkg-pkg3/10795/1 "2018-05-09T12:25:50Z")

</div>

Is it possible to specify the gitconfig file to be used when running the `add` commands in Pkg or Pkg3? I’m running Julia under Cygwin, and get GitConfig errors when running `add` commands due to symlink issues ([explained here](https://github.com/JuliaLang/julia/issues/24128#issuecomment-387423471), basically my `.gitconfig` file is a symlink, and Julia Windows build doesn’t understand Cygwin symlinks).

I’ve tried setting the GIT\_CONFIG environment variable to directly point to my actual gitconfig file (instead of to a symlink), but that doesn’t seem to make any difference. I still get the same:

```julia
ERROR: GitError(Code:ERROR, Class:Config, failed to parse config file: Invalid configuration key (in C:/cygwin64/home/Sundar/.gitconfig:1, column 0))

```

This happens both in 0.6 and 0.7, I get the same error from `Pkg.add`, `update` , etc. (`Pkg3` gives a different message - `package names could not be resolved` - but there too the message goes away if I use the command outside Cygwin (in a PowerShell terminal), so the issue might be the same there too.)

Do the Pkg modules have a way to specify which gitconfig file to use? The GitConfig parts of LibGit2 are full of ccalls, so I’m not able to make sense of them and figure it out from the code.

---

<div class="post-metadata">

### Author: ![crbinz](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/crbinz/32/1919_2.png) [@crbinz](https://discourse.julialang.org/u/crbinz)
#### Post date: [July 31, 2019, 2:57pm UTC](https://discourse.julialang.org/t/setting-the-gitconfig-file-to-be-used-by-pkg-pkg3/10795/2 "2019-07-31T14:57:55Z")

</div>

Did you ever figure this out? I’m running into this issue now in julia 1.1.1 after switching to Windows 10 (from Windows 7).
