{"thread":{"id":"6947","subject":"using the same repo with different OS","startedAt":"2007-02-25T17:13:57Z","lastAt":"2007-03-17T14:17:05Z","messageCount":11,"participants":["Stefano Spinucci","Johannes Schindelin","Junio C Hamano","Shawn O. Pearce"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"35434","messageId":"906f26060702250913g41658be6mffea613f25f9a847@mail.gmail.com","threadId":"6947","inReplyTo":null,"subject":"using the same repo with different OS","fromName":"Stefano Spinucci","fromEmail":"virgo977virgo@gmail.com","sentAt":"2007-02-25T17:13:57Z","receivedAt":"2007-02-25T17:13:57Z","isPatch":false,"sender":{"key":"virgo977virgo@gmail.com","avatar":null},"body":"I have my repos on a USB key (fat32 fs) and I work with git under\nlinux and windows (maybe also Solaris in the future).\n\nConsidering also the new MinGW port, should I use a different repo for\nevery OS I work with???\n\nAre planned/expected OS-specific files in the repo preventing me to\nuse the same whenever I'm working???\n\nthanks in advance\n\n---\nStefano Spinucci\n"},{"id":"35436","messageId":"906f26060702250917q55873a10ve878dbc2e7b93c3e@mail.gmail.com","threadId":"6947","inReplyTo":"906f26060702250913g41658be6mffea613f25f9a847@mail.gmail.com","subject":"Re: using the same repo with different OS","fromName":"Stefano Spinucci","fromEmail":"virgo977virgo@gmail.com","sentAt":"2007-02-25T17:17:44Z","receivedAt":"2007-02-25T17:17:44Z","isPatch":false,"sender":{"key":"virgo977virgo@gmail.com","avatar":null},"body":"On 2/25/07, Stefano Spinucci <virgo977virgo@gmail.com> wrote:\n> Are planned/expected OS-specific files in the repo preventing me to\n> use the same *whenever* I'm working???\n\n:-(\n\nobviously, I mean \"*wherever* I'm working???\"\n\n---\nStefano Spinucci\n"},{"id":"35438","messageId":"Pine.LNX.4.63.0702251829530.22628@wbgn013.biozentrum.uni-wuerzburg.de","threadId":"6947","inReplyTo":"906f26060702250913g41658be6mffea613f25f9a847@mail.gmail.com","subject":"Re: using the same repo with different OS","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2007-02-25T17:34:14Z","receivedAt":"2007-02-25T17:34:14Z","isPatch":false,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"Hi,\n\nOn Sun, 25 Feb 2007, Stefano Spinucci wrote:\n\n> I have my repos on a USB key (fat32 fs) and I work with git under\n> linux and windows (maybe also Solaris in the future).\n> \n> Considering also the new MinGW port, should I use a different repo for \n> every OS I work with???\n\nYou don't need to. But remember that the stat informations are likely to \nbe borked. For example, when you do a \"git-status\" on a sizable working \ntree on that stick, it will take a long, long time whenever you switch \nOSes. Basically the same amount of time as if git did not have an index!\n\n> Are planned/expected OS-specific files in the repo preventing me to use \n> the same whenever I'm working???\n\nIt could be possible that the index is saved in a slightly different \nformat, due to different alignment strategies. Maybe 64-bit vs 32-bit has \ndifferences there. I have no idea.\n\nCiao,\nDscho\n"},{"id":"35444","messageId":"7v3b4ut7yq.fsf@assigned-by-dhcp.cox.net","threadId":"6947","inReplyTo":"Pine.LNX.4.63.0702251829530.22628@wbgn013.biozentrum.uni-wuerzburg.de","subject":"Re: using the same repo with different OS","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2007-02-25T18:20:29Z","receivedAt":"2007-02-25T18:20:29Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:\n\n> It could be possible that the index is saved in a slightly different \n> format, due to different alignment strategies. Maybe 64-bit vs 32-bit has \n> differences there. I have no idea.\n\nAs far as I am aware of, there should be no such difference,\nalthough we probably rely on int being 32 and long being 64\nbit.  We do store our numbers in network byte order.\n\nHowever, did somebody say FAT-32?  I seem to recall that that\nfilesystem lacks uid/gid, so I am reasonably sure there would be\ndifferent return values for the same path from lstat(2) between\ngit on Cygwin/MinGW and on Linux that mounts the same filesystem\nusing vfat driver with different uid= & gid= mount options.\nThat difference which would make the paths stat-dirty.\n\nAlso there is the problem of i-num we discussed lately.  The\ni-num we get for the same path from lstat(2) can be different\nwhen same filesystem is mounted by different operating systems\n(remember that NTFS on Linux and Cygwin?).\n\nSo even though file format of the index may be designed and\nimplemented to be portable, it might not be practical to use\nthe same physical repository from different OSes, depending on\nthe combination of things.\n"},{"id":"35445","messageId":"Pine.LNX.4.63.0702251929170.22628@wbgn013.biozentrum.uni-wuerzburg.de","threadId":"6947","inReplyTo":"7v3b4ut7yq.fsf@assigned-by-dhcp.cox.net","subject":"Re: using the same repo with different OS","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2007-02-25T18:30:19Z","receivedAt":"2007-02-25T18:30:19Z","isPatch":false,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"Hi,\n\nOn Sun, 25 Feb 2007, Junio C Hamano wrote:\n\n> So even though file format of the index may be designed and implemented \n> to be portable, it might not be practical to use the same physical \n> repository from different OSes, depending on the combination of things.\n\nYes.\n\nHowever, in the case of a _bare_ repo, which is meant purely to transport \n(possibly huge) changes from A to B, a USB stick can be used _without_ \nproblems. I do that myself quite often.\n\nCiao,\nDscho\n"},{"id":"35446","messageId":"7vy7mmrspw.fsf@assigned-by-dhcp.cox.net","threadId":"6947","inReplyTo":"Pine.LNX.4.63.0702251929170.22628@wbgn013.biozentrum.uni-wuerzburg.de","subject":"Re: using the same repo with different OS","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2007-02-25T18:35:07Z","receivedAt":"2007-02-25T18:35:07Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:\n\n> However, in the case of a _bare_ repo, which is meant purely to transport \n> (possibly huge) changes from A to B, a USB stick can be used _without_ \n> problems. I do that myself quite often.\n\nI think we are in agreement, but read the thread again.  You\nbrought up the index and my response is only about the\nportability of the index.  Of course, the index does not matter\nin a bare repository ;-)\n"},{"id":"35861","messageId":"906f26060702281006l794173e8uea0f7174dd712e32@mail.gmail.com","threadId":"6947","inReplyTo":"7vy7mmrspw.fsf@assigned-by-dhcp.cox.net","subject":"Re: using the same repo with different OS","fromName":"Stefano Spinucci","fromEmail":"virgo977virgo@gmail.com","sentAt":"2007-02-28T18:06:29Z","receivedAt":"2007-02-28T18:06:29Z","isPatch":false,"sender":{"key":"virgo977virgo@gmail.com","avatar":null},"body":"I noticed today that my notes about compiling Git on cygwin to work\nwith FAT32 (export NO_MMAP=1) on the Wiki page WindowsInstall were\nremoved.\n\nThan I'm asking how you'd setup repos to work on some linux/windows\nmachines, transferring data only with an USB disk.\n\n* current repos scenario *\nr1.linux -> on fat32\nr2.windows -> on fat32\n\n* proposed (better???) repos scenario *\nr1.lin -> on ext3 (partition 1)\nr1.lin -> on fat32 (partition 2) mirrored with rsync from linux\nr2.win -> on fat32 (partition 2) mirrored with cwrsync from windows\nr2.win -> on ntfs (partition 3)\n\n\nbye, and thanks for the wonderful tool git is!\n\n---\nStefano Spinucci\n"},{"id":"35863","messageId":"20070228181251.GG5924@spearce.org","threadId":"6947","inReplyTo":"906f26060702281006l794173e8uea0f7174dd712e32@mail.gmail.com","subject":"Re: using the same repo with different OS","fromName":"Shawn O. Pearce","fromEmail":"spearce@spearce.org","sentAt":"2007-02-28T18:12:51Z","receivedAt":"2007-02-28T18:12:51Z","isPatch":false,"sender":{"key":"spearce@spearce.org","avatar":"https://avatars.githubusercontent.com/u/34844?v=4"},"body":"Stefano Spinucci <virgo977virgo@gmail.com> wrote:\n> I noticed today that my notes about compiling Git on cygwin to work\n> with FAT32 (export NO_MMAP=1) on the Wiki page WindowsInstall were\n> removed.\n\nThat was me.  NO_MMAP=1 is now the default on Cygwin.\n \n> Than I'm asking how you'd setup repos to work on some linux/windows\n> machines, transferring data only with an USB disk.\n\nJust create a bare repository on the USB stick and push/fetch to it.\nIt won't have a checkout directory or an index, the two sticking\npoints with mmap() on Windows and with a FAT32 filesystem being\naccessed through Git by both Linux and Windows.\n\n-- \nShawn.\n"},{"id":"36931","messageId":"906f26060703121133o6de42d66y9f3ada50149a852c@mail.gmail.com","threadId":"6947","inReplyTo":"20070228181251.GG5924@spearce.org","subject":"Re: using the same repo with different OS","fromName":"Stefano Spinucci","fromEmail":"virgo977virgo@gmail.com","sentAt":"2007-03-12T18:33:33Z","receivedAt":"2007-03-12T18:33:33Z","isPatch":false,"sender":{"key":"virgo977virgo@gmail.com","avatar":null},"body":"On 2/28/07, Shawn O. Pearce <spearce@spearce.org> wrote:\n>\n> Stefano Spinucci <virgo977virgo@gmail.com> wrote:\n> > Than I'm asking how you'd setup repos to work on some linux/windows\n> > machines, transferring data only with an USB disk.\n>\n> Just create a bare repository on the USB stick and push/fetch to it.\n> It won't have a checkout directory or an index, the two sticking\n> points with mmap() on Windows and with a FAT32 filesystem being\n> accessed through Git by both Linux and Windows.\n\nNeeding to have my repos backupped and only on fat32 usb keys, I was\nthinking to have the following layout:\non usb key one --> repo.linux\non usb key two --> repo.win\n\nThen, on repo.win, I'll do:\n# before daily work on windows\nfetch from repo.linux\n# after daily work on windows\npush to repo.linux\n\nOtherwise, on repo.linux:\n# before nightly work on linux\nfetch from repo.windows\n# after nightly work on linux\npush to repo.windows\n\nIt's possible, or I need a third bare repository between windows and linux ???\n\nthanks\n\n---\nStefano Spinucci\n"},{"id":"36958","messageId":"Pine.LNX.4.63.0703122100550.22628@wbgn013.biozentrum.uni-wuerzburg.de","threadId":"6947","inReplyTo":"906f26060703121133o6de42d66y9f3ada50149a852c@mail.gmail.com","subject":"Re: using the same repo with different OS","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2007-03-12T20:05:11Z","receivedAt":"2007-03-12T20:05:11Z","isPatch":false,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"Hi,\n\nOn Mon, 12 Mar 2007, Stefano Spinucci wrote:\n\n> On 2/28/07, Shawn O. Pearce <spearce@spearce.org> wrote:\n> > \n> > Stefano Spinucci <virgo977virgo@gmail.com> wrote:\n> > > Than I'm asking how you'd setup repos to work on some linux/windows\n> > > machines, transferring data only with an USB disk.\n> > \n> > Just create a bare repository on the USB stick and push/fetch to it.\n> > It won't have a checkout directory or an index, the two sticking\n> > points with mmap() on Windows and with a FAT32 filesystem being\n> > accessed through Git by both Linux and Windows.\n> \n> Needing to have my repos backupped and only on fat32 usb keys, I was\n> thinking to have the following layout:\n> on usb key one --> repo.linux\n> on usb key two --> repo.win\n> \n> Then, on repo.win, I'll do:\n> # before daily work on windows\n> fetch from repo.linux\n> # after daily work on windows\n> push to repo.linux\n> \n> Otherwise, on repo.linux:\n> # before nightly work on linux\n> fetch from repo.windows\n> # after nightly work on linux\n> push to repo.windows\n> \n> It's possible, or I need a third bare repository between windows and \n> linux ???\n\nNo need for a third one. You can even use alternates to save space:\n\n$ git clone -l -s repo.linux repo.windows\n\nWhen git-gc'ing, the objects will be packed, but if they are present in \nboth repo.linux and repo.windows, the objects from repo.linux will be \nreused in repo.windows.\n\nNote: USB sticks are almost as fragile as disks used to be... So, try \navoiding writes if you can...\n\nCiao,\nDscho\n"},{"id":"37314","messageId":"906f26060703170717t52094994taefad640c52c7faa@mail.gmail.com","threadId":"6947","inReplyTo":"20070228181251.GG5924@spearce.org","subject":"Re: using the same repo with different OS","fromName":"Stefano Spinucci","fromEmail":"virgo977virgo@gmail.com","sentAt":"2007-03-17T14:17:05Z","receivedAt":"2007-03-17T14:17:05Z","isPatch":false,"sender":{"key":"virgo977virgo@gmail.com","avatar":null},"body":"On 2/28/07, Shawn O. Pearce <spearce@spearce.org> wrote:\n> Stefano Spinucci <virgo977virgo@gmail.com> wrote:\n> > I noticed today that my notes about compiling Git on cygwin to work\n> > with FAT32 (export NO_MMAP=1) on the Wiki page WindowsInstall were\n> > removed.\n>\n> That was me.  NO_MMAP=1 is now the default on Cygwin.\n\nUnfortunately, the Git cygwin mantainer decided to compile git without\nthe NO_MMAP option (see the announcement\nhttp://cygwin.com/ml/cygwin-announce/2007-03/msg00005.html and a reply\nto my message http://cygwin.com/ml/cygwin/2007-03/msg00567.html).\n\nThen, I guess if on the Wiki page WindowsInstall we should add a note\nabout recompiling manually Git to work with FAT32.\n\n\nPS\n\nOn the Git cygwin announcement, the mantainer Eric Blake said:\n\"However, it means that this version does assume that you are not\nusing FAT or FAT32 to\nhold your repositories, since they *do not store file permissions very\naccurately*.\"\n\nWhat file permissions are not stored accurately ???\n\nShouldn't be added somewhere (maybe on the GitFaq) a note about Git on\nFAT32 problems (if there are any) ???\n\n\nbye\n\n---\nStefano Spinucci\n"}]}