Re: mr: chaining to absolute paths
On Sun, Nov 6, 2011 at 9:48 PM, Joey Hess wrote: > Adam Spiers wrote: >> Thanks for the info, but I'm confused because that doesn't seem to >> correspond exactly with the layout you gave earlier. For example, you >> said that you have a ~/doc/.mrconfig, but you didn't say that there >> was a repository tracking ~/doc itself - only that ~/doc had various >> document repositories inside it. > > Every directory I showed is a separate repository. I see, so you are indeed nesting. >> So is your ~/doc/.mrconfig tracked by a repository? If so it sounds >> like you have nested repositories, which git would presumably detect >> as submodules unless you are using a symlink manager? > > git does not detect nested git repos as submodules, that would have to > be explicitly set up. True - I just did a quick experiment to confirm that the subdirectory containing the nested repo shows up as an untracked file until you add it (which registers it as a submodule) or ignore it. So if you are not using submodules then presumably you are adding your nested repos to .gitignore, or just simply tolerating the noise in 'git status' output? ___ vcs-home mailing list vcs-home@lists.madduck.net http://lists.madduck.net/listinfo/vcs-home
Re: mr: chaining to absolute paths
Adam Spiers wrote: > Thanks for the info, but I'm confused because that doesn't seem to > correspond exactly with the layout you gave earlier. For example, you > said that you have a ~/doc/.mrconfig, but you didn't say that there > was a repository tracking ~/doc itself - only that ~/doc had various > document repositories inside it. Every directory I showed is a separate repository. > So is your ~/doc/.mrconfig tracked by a repository? If so it sounds > like you have nested repositories, which git would presumably detect > as submodules unless you are using a symlink manager? git does not detect nested git repos as submodules, that would have to be explicitly set up. -- see shy jo ___ vcs-home mailing list vcs-home@lists.madduck.net http://lists.madduck.net/listinfo/vcs-home
Re: mr: chaining to absolute paths
On Thu, Nov 3, 2011 at 5:46 PM, Joey Hess wrote: > Adam Spiers wrote: >> > > - Do you track your mrconfig files with version control? >> > >> > yes >> >> How do you do that? Are they all in one repo? How do you get each >> one into the right subdirectory of ~ ? > > They're checked out by mr as part of the repositories that provide the > subdirectories they're in. Thanks for the info, but I'm confused because that doesn't seem to correspond exactly with the layout you gave earlier. For example, you said that you have a ~/doc/.mrconfig, but you didn't say that there was a repository tracking ~/doc itself - only that ~/doc had various document repositories inside it. So is your ~/doc/.mrconfig tracked by a repository? If so it sounds like you have nested repositories, which git would presumably detect as submodules unless you are using a symlink manager? Thanks! By the way there are good reasons for my curiosity ;-) I'm mulling over a similar layout but want to avoid nested repositories and also prefer a symlink manager to detached git working directories. ___ vcs-home mailing list vcs-home@lists.madduck.net http://lists.madduck.net/listinfo/vcs-home
Re: mr: chaining to absolute paths
Adam Spiers wrote: > > > - Do you track your mrconfig files with version control? > > > > yes > > How do you do that? Are they all in one repo? How do you get each > one into the right subdirectory of ~ ? They're checked out by mr as part of the repositories that provide the subdirectories they're in. -- see shy jo signature.asc Description: Digital signature ___ vcs-home mailing list vcs-home@lists.madduck.net http://lists.madduck.net/listinfo/vcs-home
Re: mr: chaining to absolute paths
On Thu, Nov 03, 2011 at 12:22:48PM -0400, Joey Hess wrote: > Adam Spiers wrote: > > On Wed, Nov 02, 2011 at 05:02:13PM -0400, Joey Hess wrote: > > > Adam Spiers wrote: > > > > I notice that chaining to absolute paths does not work, e.g.: > > > > Is this a feature or a bug? I would have thought it would be useful > > > > to chain to absolute paths. > > > > > > Probably because nobody noticed since when you're in ~/foo/bar, > > > ~/foo/bar/.mrconfig will be read anyway without chaining. > > I probably meant to say ~/foo/.mrconfig fwiw. Ah, OK. [snipped] > > I guess it would really help me if one or two people would be kind > > enough to briefly describe the way they use mr, e.g. > > > > - How is your home directory structured, i.e. where do your mrconfig > > files and repos live within it, and which mrconfig files point to > > which repos? > > Sure: [snipped] Thanks, this is really useful! > > - Do you track your mrconfig files with version control? > > yes How do you do that? Are they all in one repo? How do you get each one into the right subdirectory of ~ ? > > - Do you frequently use the -d or -c options? > > never > > > - Do you usually cd to a particular directory before running mr, and > > if so, why? > > I always run mr in the directory I want to affect. Sometimes this > directory contains many repositories, sometimes only one. The point of > mr is I don't need to care how many underlying repositories there are. > If I run it in ~/src/d-i, I want to act on d-i; in > ~/src/d-i/package/main-menu I'm only dealing with one package; in ~/src > I want to act on all my source repos. Very helpful and food for thought, thanks again. ___ vcs-home mailing list vcs-home@lists.madduck.net http://lists.madduck.net/listinfo/vcs-home
Re: mr: chaining to absolute paths
Adam Spiers wrote: > On Wed, Nov 02, 2011 at 05:02:13PM -0400, Joey Hess wrote: > > Adam Spiers wrote: > > > I notice that chaining to absolute paths does not work, e.g.: > > > Is this a feature or a bug? I would have thought it would be useful > > > to chain to absolute paths. > > > > Probably because nobody noticed since when you're in ~/foo/bar, > > ~/foo/bar/.mrconfig will be read anyway without chaining. I probably meant to say ~/foo/.mrconfig fwiw. > I'm beginning to suspect that the way I imagine using mr is > fundamentally different to everyone else's way. Your previous point > about mr working best with locality of reference (i.e. each .mrconfig > being in a parent or near ancestor of the directories containing the > repos it manages) also contributed to this suspicion. I can > understand how that makes for clean .mrconfig files with short > relative paths in the section headers, but I can't understand how you > could then version control all your .mrconfig files and share them > across computers. And if you can't, then doesn't that discard a very > large part of the advantage of using mr in the first place? > > I guess it would really help me if one or two people would be kind > enough to briefly describe the way they use mr, e.g. > > - How is your home directory structured, i.e. where do your mrconfig > files and repos live within it, and which mrconfig files point to > which repos? Sure: ~ .mrconfig doc .mrconfig (various document repositories) src .mrconfig (many package sources) d-i .mrconfig lib/backup .mrconfig (only exists on a few machines, various repositories) > - How many mrconfig files and mr-managed repos do you have? 190 repos, mostly in src > - Do you track your mrconfig files with version control? yes > - Do you frequently use the -d or -c options? never > - Do you usually cd to a particular directory before running mr, and > if so, why? I always run mr in the directory I want to affect. Sometimes this directory contains many repositories, sometimes only one. The point of mr is I don't need to care how many underlying repositories there are. If I run it in ~/src/d-i, I want to act on d-i; in ~/src/d-i/package/main-menu I'm only dealing with one package; in ~/src I want to act on all my source repos. -- see shy jo signature.asc Description: Digital signature ___ vcs-home mailing list vcs-home@lists.madduck.net http://lists.madduck.net/listinfo/vcs-home
Re: mr: chaining to absolute paths
On Wed, Nov 02, 2011 at 05:02:13PM -0400, Joey Hess wrote: > Adam Spiers wrote: > > I notice that chaining to absolute paths does not work, e.g.: > > Is this a feature or a bug? I would have thought it would be useful > > to chain to absolute paths. > > Probably because nobody noticed since when you're in ~/foo/bar, > ~/foo/bar/.mrconfig will be read anyway without chaining. But ~/foo/bar is just a single repo, so if that's already your current working directory, wouldn't you just end up invoking git (or whatever) directly instead? I'm beginning to suspect that the way I imagine using mr is fundamentally different to everyone else's way. Your previous point about mr working best with locality of reference (i.e. each .mrconfig being in a parent or near ancestor of the directories containing the repos it manages) also contributed to this suspicion. I can understand how that makes for clean .mrconfig files with short relative paths in the section headers, but I can't understand how you could then version control all your .mrconfig files and share them across computers. And if you can't, then doesn't that discard a very large part of the advantage of using mr in the first place? I guess it would really help me if one or two people would be kind enough to briefly describe the way they use mr, e.g. - How is your home directory structured, i.e. where do your mrconfig files and repos live within it, and which mrconfig files point to which repos? - How many mrconfig files and mr-managed repos do you have? - Do you track your mrconfig files with version control? - Do you frequently use the -d or -c options? - Do you usually cd to a particular directory before running mr, and if so, why? To me, it's important that a tool like mr can act on an arbitrary list of repositories regardless of my current working directory. In other words, I'd rather choose which repositories mr should act on via the parameters I'm invoking mr with, rather than by cd'ing to a particular directory, running mr, then potentially having to repeat the cd + mr steps multiple times. > And there's rarely a reason to use an absolute path. I can't see how to accomplish what I need without them. Hopefully answers to the above questions would help me realise what I'm missing. > Fixed in git. Great, thanks! ___ vcs-home mailing list vcs-home@lists.madduck.net http://lists.madduck.net/listinfo/vcs-home
Re: mr: chaining to absolute paths
Adam Spiers wrote: > I notice that chaining to absolute paths does not work, e.g.: > > [$HOME/foo/bar] > checkout = ... > chain = true > > This is due to the way the chaining code checks for an .mrconfig in > the chained repository: > > if ($parameter eq 'chain' && > length $dir && $section ne "DEFAULT" && > -e $dir.$section."/.mrconfig") { > > Is this a feature or a bug? I would have thought it would be useful > to chain to absolute paths. Probably because nobody noticed since when you're in ~/foo/bar, ~/foo/bar/.mrconfig will be read anyway without chaining. And there's rarely a reason to use an absolute path. Fixed in git. -- see shy jo signature.asc Description: Digital signature ___ vcs-home mailing list vcs-home@lists.madduck.net http://lists.madduck.net/listinfo/vcs-home
mr: chaining to absolute paths
I notice that chaining to absolute paths does not work, e.g.: [$HOME/foo/bar] checkout = ... chain = true This is due to the way the chaining code checks for an .mrconfig in the chained repository: if ($parameter eq 'chain' && length $dir && $section ne "DEFAULT" && -e $dir.$section."/.mrconfig") { Is this a feature or a bug? I would have thought it would be useful to chain to absolute paths. Thanks, Adam ___ vcs-home mailing list vcs-home@lists.madduck.net http://lists.madduck.net/listinfo/vcs-home