threads / discuss / 31262

How to pull from windows box

Subject: How to pull from windows box

## tl;dr

2 messages between Aug 16, 2012 and Aug 16, 2012.

replies: 1people: 2as markdown or json

J.V.· Aug 16, 2012, 13:11 UTC · lore

We have a central/shared bare repo setup on a Linux box by our scc/build team.

Each developer pulls/pushes to this repo. I have two windows boxes where I have cloned the repo. I want to commit and then on my second windows box pull from my other box and keep those in sync until it is time to push to central.

What do I need to setup on each Windows 7 box to get this working?
J.V.
Konstantin Khomoutov· Aug 16, 2012, 16:28 UTC · re: J.V. · lore

Re: How to pull from windows box

On Thu, 16 Aug 2012 07:11:28 -0600 "J.V." <jvsrvcs@gmail.com> wrote:

Show 9 quoted lines
> We have a central/shared bare repo setup on a Linux box by our
> scc/build team.
> 
> Each developer pulls/pushes to this repo.  I have two windows boxes 
> where I have cloned the repo.  I want to commit and then on my second 
> windows box pull from my other box and keep those in sync until it is 
> time to push to central.
> 
> What do I need to setup on each Windows 7 box to get this working?

Create a regular Windows share for the project directory on the box you want to fetch from, ensure your user from another box is able to successfully authenticate on that share, and then on that box add the created share as a remote like this:

git remote add otherbox file:////thatbox/sharename
To fetch from that "otherbox" remote you then go like this:
1) Run Windows Explorer, navigate to \\thatbox\sharename,
   authenticate (if needed).  This will ensure all the next accesses
   will be automatically authenticated.
2) Do `git fetch otherbox`.

Of course, you can just attach that share as a network drive and then modify the URL for your remote accordingly.

Note that since the repos are normal (non-bare) this will work well only for fetches (see the FAQ for more info).

← back to recent threads