Reputation: 28306
I'm using GitKraken 1.4.1 for version control of some project files. The source files are in a network folder with a unc path (not mapped to a drive letter but could be). I want to keep the .git folder and any other evidence of the presence of Git on my local machine, off the network where the files reside. How do I do this? I could keep everything (source files and git-related files) in a working folder on my local machine and manually copy them to the network but that seems like a pain and prone to error.
Upvotes: 0
Views: 316
Reputation: 32484
With regular Git, you can keep the .git
directory outside your project, as explained here:
One of the things that people that come from the Subversion world tend to find pretty cool about Git is that there is no .svn directory in every subdirectory of your project, but instead just one .git directory in the root of your project. Actually, it's even better than that. The .git directory does not even need to actually be within your project. Git allows you to tell it where your .git directory is, and there are a couple of ways to do that.
Those two way are:
Use the --git-dir
option:
$ git --git-dir=/path/to/git/dir command ...
Use the GIT_DIR environment variable
$ export GIT_DIR=/path/to/git/dir
I don't know whether GitKraken supports that functionality.
Upvotes: 1