The problem with Windows or NFS file shares is that the contents are not version-controlled and (unless you use the Windows "available off line" feature) not available while you're disconnected from the office network. However, it is very easy to set up a git repository for a team to share code and documents, if they all have at least intermittent access to the same file share.
First install yourself a git command-line client if you have not done so yet (see http://git-scm.com/downloads).
Creating the repository
- You already have a local git repository called "test-repo", which you want to share
- Your local git repositories are under %HOMEDRIVE%\%HOMEPATH%\git
- Your shared git repositories are going to be under \\myserver\myshare\git
To add a remote copy of your own git repository to the share:
>git init --bare test-repo.git
>git remote add origin "//myserver/myshare/git/test-repo.git"
>git push origin master
Note that the git commands require slashes to be forward - unlike normal Windows commands.
Verify that the file .git\config within your local git repository looks something like this:
repositoryformatversion = 0
filemode = false
bare = false
logallrefupdates = true
symlinks = false
ignorecase = true
hideDotFiles = dotGitOnly
url = //myserver/myshare/git/test-repo.git
fetch = +refs/heads/*:refs/remotes/origin/*
remote = origin
merge = refs/heads/master
rebase = true
Ensure that the sections [remote "origin"] and [branch "master"] in particular are set up correctly.
Cloning the repository
Another team member can now share your code - you both push your local commits to the shared repository and pull other team members' commits from it to your local repository. Here's what each team member wishing to access the shared repository should do, assuming that they also have their local git repositories under %HOMEDRIVE%\%HOMEPATH%\git.
>git clone "//myserver/myshare/git/test-repo.git" test-repo
The status should look like this:
# On branch master
nothing to commit (working directory clean)