From: Johannes Schindelin Date: Mon, 12 Mar 2007 20:05:11 GMT Subject: Re: using the same repo with different OS Message-ID: In-Reply-To: <906f26060703121133o6de42d66y9f3ada50149a852c@mail.gmail.com> Hi, On Mon, 12 Mar 2007, Stefano Spinucci wrote: > On 2/28/07, Shawn O. Pearce wrote: > > > > Stefano Spinucci wrote: > > > Than I'm asking how you'd setup repos to work on some linux/windows > > > machines, transferring data only with an USB disk. > > > > Just create a bare repository on the USB stick and push/fetch to it. > > It won't have a checkout directory or an index, the two sticking > > points with mmap() on Windows and with a FAT32 filesystem being > > accessed through Git by both Linux and Windows. > > Needing to have my repos backupped and only on fat32 usb keys, I was > thinking to have the following layout: > on usb key one --> repo.linux > on usb key two --> repo.win > > Then, on repo.win, I'll do: > # before daily work on windows > fetch from repo.linux > # after daily work on windows > push to repo.linux > > Otherwise, on repo.linux: > # before nightly work on linux > fetch from repo.windows > # after nightly work on linux > push to repo.windows > > It's possible, or I need a third bare repository between windows and > linux ??? No need for a third one. You can even use alternates to save space: $ git clone -l -s repo.linux repo.windows When git-gc'ing, the objects will be packed, but if they are present in both repo.linux and repo.windows, the objects from repo.linux will be reused in repo.windows. Note: USB sticks are almost as fragile as disks used to be... So, try avoiding writes if you can... Ciao, Dscho