/srv/irclogs.ubuntu.com/2012/10/28/#bzr.txt

=== yofel is now known as Guest39202
=== Guest39202 is now known as yofel
mark06how to merge a branch without a common ancestor?19:15
fullermdManually specify the rev range to merge.  Usually the whole history, i.e. "-r0..-1".19:17
jelmerI wonder if we should just add that as suggestion to the error message.19:18
fullermdI'd hesitate, I think.19:18
fullermdWorth a FAQ entry, maybe.  If we have a FAQ.19:22
mark06I think clarify the error message would be nice, because I went through exactly the same steps as described here, without knowing this page: http://selfdocumentingcode.blogspot.com.br/2009/04/merging-unrelated-branches-in-bazaar.html19:30
mark06is there a way to specify a bug in commit comment without using full URL?19:32
mark06I want to reference bug 308562 in the dummy initial commit19:33
ubot5Launchpad bug 82555 in Bazaar "duplicate for #308562 Merging to an empty branch doesn't work" [High,Confirmed] https://launchpad.net/bugs/8255519:33
jelmermark06: there is the --fixes option which adds a commit property19:33
mark06I know, but it doesn't fix the above bug :)19:33
jelmermark06: it allows you to use shortcuts for bug tracker URLs19:33
jelmermark06: --fixes lp:4545 will reference http://bugs.launchpad.net/454519:34
ubot5Ubuntu bug 4545 in amsn (Ubuntu) "amsn crashes on start-up/won't load" [Medium,Fix released]19:34
mark06ok, I know, but it doesn't fix that bug, it's that bug which required the commit, so would be rather --forced-by19:35
jelmermark06: I'm not sure I follow what you mean in that case19:35
jelmermark06: do you want to reference a bug without actually changing anything else?19:35
jelmermark06: you want --unchanged in that case19:36
mark06I'm already using --unchanged19:36
fullermdI think you're just trying to outsmart yourself   :)19:36
mark06I want to reference the bug in the commit comment, something like:19:36
fullermdJust reference "LP bug 12345" in the commit message.19:36
ubot5Launchpad bug 12345 in isdnutils (Ubuntu) "isdn does not work, fritz avm (pnp?)" [Medium,Fix released] https://launchpad.net/bugs/1234519:36
fullermdISDN?  Yeesh.  How 1990's   :p19:37
mark06yeah fullermd, just wondered if it was possible19:37
jelmermark06: Why though? This is what the commit properties are used for, and what all bzr tools will display19:37
jelmerHaving two different ways of referencing bugs would seem very confusing to me, and not particularly useful.19:38
mark06jelmer: ...something like: bzr commit -m "This is a dummy, empty commit required because of bug lp:308562"19:39
jelmermark06: ah, no, there isn't any way to do that. I don't think that would be particularly useful.19:41
mark06btw, it would be nice if tags weren't unique, or if we had options like --not-very-important (e.g. code formatting) --broken (for broken revisions we don't open a bug for)19:42
mark06about the dummy commit, nothing much important19:43
mark06or --fixes=revision19:43
jelmermark06: what do you mean with --not-very-important, what would that do?19:43
mark06add a metadata to the commit stating it is not as important as "regular" commits, so we could for example bzr qlog --exclude-not-much-important19:45
jelmermark06: one of the fundamental properties of tags is that they're unique; without that; if you want to use them to annotate revisions I think what you want is a different feature (perhaps stored as revision property?)19:45
mark06yeah, as a property then...19:45
mark06is it possible to add arbitrary properties and have them showing in qlog juts like tags or --fixes?19:46
jelmermark06: you'd have to have a plugin installed that can display those properties19:47
jelmersimilarly though, you'd need a plugin to set them19:47
mark06:(19:48
mark06what's the difference between -r 0..-1 and -r 1..-1?19:51
fullermd1   8-}19:51
fullermdThe former runs from null, the latter from rev1.  Just what the result is probably varies a bit by command and how they interpret the rev range.19:52
Guest40826Could someone explain to me the relationship between repositories and branches in bzr?19:53
jelmerGuest40826: the repository is the thing that holds the revisions, and a branch is a line of history19:54
mark06how about the merge command, does it make any difference like merging uncommitted commits or something?19:54
fullermdmark06: Yes, -r1..-1 would mean the revs {2,3,4,...,-1}, in contrast to 0..-1 meaning {1,2,3,...,-1}19:55
Guest40826So, if I want to have two completely separate projects, would I create two separate repositories for them?19:55
jelmerGuest40826: no, you can have them in the same repository without problems. The repository is merely a container for the revisions, it doesn't require them to be related in any way and it doesn't have any effect on their relation either.19:56
fullermdHowever, if they really are completely separate, there would be no _gain_ from having them both in the same repo.19:57
jelmerindeed19:57
fullermdPotentially a minor loss in performance in some cases, since half (or whatever proportion) of the data to be sorted through would be pointless for any individual activity.19:57
mark06fullermd: ah thanks!19:58
fullermdProbably pretty unimportant, unless either branch is huge.19:58
Guest40826So, I could create one repository (using the init-repo command?) that would have multiple branches inside of it (created using the init command?) and could develop two different codebases within that one repository?19:58
Guest40826Do I have that right?19:59
jelmerGuest40826: yep19:59
fullermdYou could, yes.  The repository doesn't care; all it knows is it gets told "find me revision XYZ" or "here's a revision; hold onto it"19:59
mark06maybe just create standalone branches (each branch contains its own repo)19:59
Guest40826mark06: What do you mean by that?20:00
fullermdGuest40826: What's your VCS background?20:00
Guest40826almost strictly svn20:00
fullermdOK.  So the difference here is that svn is very repo-centric, whereas bzr is branch-centric.20:01
fullermdIn svn, the repo boundary is important.  You checkout the whole thing, or some arbitrary subpart of it.  All your operations take place inside it.20:01
fullermdWhereas in bzr, you deal only with branches; the whole branch, and nothing but the branch.  You checkout the whole thing, you make a new branch of the whole thing, etc.20:02
fullermdOperations like merge take place between two branches.  And any two branches; they don't have to be in the same repo (or in any shared repos at all)20:02
Guest40826okay, so what is a standalone branch?20:03
Guest40826(mentioned by mark06)20:03
fullermdWhether a branch is in a shared repo or not doesn't make any difference to how you interact with it; it only changes some backend storage details.20:03
fullermdA branch that's not in a shared repo.20:03
fullermdHow about an example...20:04
fullermd"mkdir ~/work ; cd ~/work ; bzr init projA ; bzr init projB"20:04
fullermdNow you've got two unrelated branches to work in, each of which is standalone.  All the history for projA is in ~/work/projA, and for projB in ~/work/projB.20:05
fullermdOr add a step instead:20:05
fullermd"mkdir ~/work ; cd ~/work ; bzr init-repo . ; bzr init projA ; bzr init projB"20:05
fullermdNow you've got two unrelated branches to work in, both of which use the shared repo for their history storage.20:06
fullermdInside ~/work/ is a giant bucket that all the revisions get dumped into.  projA knows which of them belong to it, and projB know which belong to it.20:06
fullermdFor pretty much anything you _do_ day to day, the two cases are identical.20:06
fullermdUnlike svn, the repo isn't [generally] a semantically meaningful unit.  It's the branches that are the granularity you work with.20:07
fullermdAnd in this case, it doesn't convey any advantages, since the two projects don't share any history.20:07
fullermdWhere it's useful is when you have projA-trunk/ and projA-frob_foo/ and projA-from_bar/ branches, which _are_ related.20:08
fullermdStandalone, each would have the entire history (both the stuff common to all of them, and the new stuff in each)20:08
fullermdWith a shared repo, all the history is in one place, so the common history isn't duplicated.  Saves disk space, I/O bandwidth, buffer cache, etc.20:09
Guest40826Here is my situation: I have two development teams, neither of which has any relationship to the other (outside of that fact that they have them same system admin). Team A is dealing with one codebase, Team B is dealing with two codebases (for two entirely separate pieces of software). I want to give Team B one domain at which they can access both codebases and choose which one to modify based on what they are going to be working on.20:09
Guest40826Which sounds to me like one repo with two branches in it for Team B.20:10
fullermdIs that 3 codebases, or 2 (one shared, one B-only)?20:11
Guest408263 total - one for team A, the other two for team B20:11
fullermdI'd just make one repo for each codebase then.20:11
fullermdSharing a repo between unrelated codebases doesn't gain you anything, so go for simplicity.20:12
Guest40826okay20:12
Guest40826so how do I serve those two repos for team B at the same domain?20:14
Guest40826Just by placing the two repos in the same directory and giving team B access to that parent?20:14
fullermdYeah.20:14
fullermdHow are you accessing them?  bzr+ssh?20:15
Guest40826That is another question I have :(20:15
Guest40826Is there a difference between bzr and bzr+ssh20:15
Guest40826?20:15
fullermdbzr is a standalone server, like svn://.  bzr+ssh ssh's into the server and talks to a spawned process over that channel, like svn+ssh20:16
Guest40826so I bzr:// what you would use when running the http://doc.bazaar.canonical.com/bzr.2.5/en/admin-guide/other-setups.html#direct-smart-server-access setup?20:17
Guest40826*is20:17
fullermdNote that bzr doesn't have any concept of AAA, so in general you'd only use it for readonly stuff.20:18
fullermd(bzr:// that is)20:18
Guest40826Okay,20:18
Guest40826I am going to be accessing this using bzr+ssh20:18
Guest40826With user accounts being restricted to bzr20:19
mark06http://i.imgur.com/z0zsX.png o/20:28
fullermdDefinitely an odd use of tags.20:32
mark06actually I changed it to fixes_rev_0.11.5 on 0.11.620:42
fullermdYeah, that would also fall under "pretty odd"   :p20:43
mark06yeah I know :)20:45
mark06oh wait, fixed_by_0.11.6 :)20:46
* fullermd reaches for the smelling salts.20:47
mark06I think I've found a bug, if merged branch contains tags already present in current branch, then it gets deleted after merge! (current branch wins the tag)20:54
fullermdThat's not exactly a bug.20:55
mark06I would personally add a merge conflict to let the user decide21:07
fullermdThe trouble is, there's no way to record a resolution.21:07
fullermdActually, I'd expect merge to spit out a warning about it.  pull does.  But maybe it gets lost in all the other stuff merge outputs.21:08
fullermdI guess it doesn't.  That's probably worth a bug.21:09
mark06hmm ok leaving... thank you all!21:21
fullermdOh look, a Wacky Log Bug.22:25
jelmerfullermd: where?22:27
fullermdI'm gonna have to work up a repro script.  's hard to explain, but it winds up with "bzr log $DIR" (or $FILE I presume) not showing you what it should.22:28
Konomihi I am trying to use checkout and I am doing bzr checkout sftp://user:pass@host22:29
Konomiand bazaar seems to ignore hte pass field entirely and still ask for a password22:30
fullermdThat's because bzr doesn't have access to the password-asking; sftp talks to your terminal directly for that.22:30
Konomiis there anyway to automate it at all?22:30
KonomiI get sick of typing in a password everytime?22:30
fullermdUse key auth (possibly with the aid of ssh-agent).22:32
Konomimeh okay thanks for your help fullermd22:33
fullermdPossibly you could force it to use paramiko instead of an outside ssh client, and pass it in that way?  I dunno.  Not as nice a solution at any rate.22:34
Konomiwhat is a bit annoying is http://doc.bazaar.canonical.com/bzr.1.11/developers/authentication-ring.html22:35
Konomisays I can embed the pass in the url but I guess it doesn't note the exception for sftp22:35
Konomifullermd: I'll just put up with entering the password for now at least I know the url is remembered I was typing that too22:37
Konomithanks again22:37
fullermdBoy, this thing is tricksy...23:03
lifelessfullermd: which thing ?23:21
fullermdWeird log bug I'm tracking.23:21
bob2why would you not just use keys23:27
lifelessharmony23:29
fullermdYeah, you might be Berg or Schoenberg.23:30
bob2it is far too early on a monday for classical music jokes23:31
fullermdGood thing it's late on a sunday   8-}23:31
* fullermd writes up a terribly confusing bug...23:53

Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!