/srv/irclogs.ubuntu.com/2011/08/20/#bzr.txt

fullermdbairui: So how did your designing-layouts/workflows stuff turn out?00:58
bairuiso far, so good... methinks. I have a workflow doc and I'm creating some images to go along with it now.00:59
fullermdCool.01:02
fullermd's long as it doesn't end up in a Powerpoint or something, anyway...01:03
bairuiI am just putting it in pastebin if you'd like to cast your critical eye over it, fullermd?01:03
fullermdWell, it'd be a pretty cursory glance.  I'm evaluating and collating incomplete and outdated information for a pointless meeting on Monday about a doomed project.01:05
bairuifullermd: http://pastebin.com/88sNi5Wv01:08
bairuiand thanks for even glancing at it :)01:08
bairuihate meetings... especially pointless ones, and so many are. :-(01:09
fullermdI would suggest using a checkout rather than a branch for trunk.  Then you can just merge/commit, and it also makes it harder to accidentally go the other way and swap around the mainline accidentally.01:13
fullermdAnd you're already using checkouts for the feature branches anyway, so might as well be consistent.01:13
* bairui is taking notes01:13
bairuiok. good to know.01:13
fullermdI'm not sure why you have the "merge --pull" stuff in youe trunk branch notes here either.01:14
fullermdI suspect you really meant just 'bzr pull'.01:14
bairuii think we were originally doing a   bzr pull   and saw someone use   merge --pull   and thought, well that saves a command if we had to merge... wrong?01:14
fullermdWell, for one thing, after a merge you'd have to commit the merge.01:15
bairuiah. ok.01:15
fullermdBut also, if pull failed on trunk, I'd think that's a red flag to stop and go "whoah, wait, wtf".  Not something to gloss over.01:15
bairuiso - we'll go back to    bzr pull   and be explicit about the merge if that was necessary01:15
bairuiagreed01:15
fullermdThat would mean that somehow your local 'trunk' ended up with something the upstream trunk doesn't have.  That shouldn't happen.01:15
bairuilike a local commit01:16
fullermdAnd if it did and you merge, you get into the mainline-swapping situation.01:16
bairuiok. to be avoided. noted :)01:16
fullermdIs it necessary to have the feature branches on the server?  I mean, sure, it's nice for longer lived stuff, but it may be overkill for simpler.01:17
bairuii was originally not putting them there - just keeping them on our local dev machines, but someone raised the concern that these are not on the server...01:18
fullermdWell, if a feature branch is taking weeks, or being worked on by multiple people, you definitely want it central there.  If it's lasting hours or a day or two, for just one person, though...01:19
bairuii guess after they get merged into trunk then they're 'available'... I think there was concern over being able to easily go back to that piece of work if rework was necessary01:19
fullermdMaybe you want to avoid people thinking case-by-case like that, which is valid.01:19
fullermdOh, yes.  Once it's merged into trunk, it can be recreated trivially.01:19
bairuiok...01:19
fullermdIf you do "bzr branch -r123.4.5 trunk newbranch" (assuming that rev is the head of the branch you had, that got merged in), you've [almost] recreated it exactly as it was before you merged.01:20
fullermdThe only stuff you miss is transient branch config (the nick, saved parent/push/etc branches, and so on).01:20
bairuinick?01:21
bairuithe local branch name?01:21
fullermdSo any time a branch is "completed" and merged, if you don't expect to pick it back up as-is, it can be rm'd away.01:21
fullermdBranches have nicknames, which are recorded in the revs created in them.  The default is just the dir name, but you can set it manually.01:21
bairuiright - and it was that rm'ing that freaked a team member (and I didn't know bzr well enough to assuage their fears)01:21
fullermdIt shows up in `log`, for instance.  Just cosmetic, but helps keep straight what you think you were doing.01:21
bairuiah - we've just been using dir name as branch name01:22
bairuiok - so for small dev work and bug fixes, you'd say: branch locally, hack, commit, merge, rm   ?01:23
bairuifor collab stuff, branch on server01:23
bairuior longer living / huge stuff01:23
fullermdI usually always branch locally, then also push the branch up to the server if it winds up being long-lived or needing collab.01:23
bairuiok. i saw that flow sometime yesterday - was nice to know one could always push a local branch at a later date01:24
fullermd`bzr branch bzr+ssh://some/thing bzr+ssh://some/thing/else` is kinda wacky, since you copy all the data across the network twice.01:24
fullermdMy work tends to go something like01:24
bairuigood to know01:24
fullermdcd ~/work/projfoo; bzr co bzr+ssh://central/trunk   # pretty much always a central trunk, just make local checkout.01:24
bairuiok01:25
fullermdFor utterly trivial stuff, I often just do and commit right on trunk.  If it's 5 minutes of work, and just one commit, why bother with the overhead of branches, I say.01:25
bairuiok01:25
fullermdIf it's going to be more than one rev, especially if half-broken in the middle, or take longer, I make a local branch01:25
fullermdcd ~/work/projfoo ; bzr branch trunk featfoo01:25
fullermdThen I can work in featfoo.  If I decide to put it central for some reason, I can just `bzr push bzr+ssh://central/featfoo` then.01:26
bairuiright. cool.01:26
fullermdAnd either remember to 'push' my changes Every So Often(tm), or convert the branch into a checkout at that point.01:26
bairuiso that each commit effectively pushes, right?01:26
fullermd(see `bzr reconfigure`; you can turn a checkout into a branch, a branch into a checkout, a standalone [non-repo-using] branch into one using a shared repo, a shared repo branch into a standalone, blah blah blah)01:26
bairuinice. awesome01:27
bairuiscary :)01:27
fullermdCorrect in essence [auto-pushes].  That gets into philosophical issues.01:27
bairuiheh, let's keep this pragmatic for now - my bzr-fu is not ready for philosophy :)01:28
fullermdNow, you may want to just fiat declare "all branches are always on the server", for either political reasons or to avoid asking people to make judgements.  That's down to your situation.01:28
fullermdSo anyway, over time, I can always `cd ~/work/projfoo/trunk ; bzr up` to have my trunk copy up to date.  Merge changes from it into featfoo if/as necessary.01:29
fullermdAnd when featfoo is done, I can just rm -rf it.01:29
fullermd(for various external reasons, I often don't exactly, but that's another matter)01:30
bairuimmm... I smell pancakes cooking... *drool*01:31
fullermdOh, I notice you mention a 'settings.php'.  Here's a trick I use a lot in webdev: we want separate configs in testing vs live (actually run credit cards vs. fake, different databases, all sorts of things)01:31
bairuiok, fullermd... that's cool. I'm logging this, so I will show it to the other team members.01:31
bairuiyep01:31
fullermdSo what I do is I have a 'live.conf.php' and 'dev.conf.php' versioned.  The includes look for "conf.php", which I make an [unversioned and ignored] symlink to whichever one is appropriate.01:32
bairuidrupal, as I'm sure you've guessed01:32
fullermdOr in some special cases, a hand-crafted one.  That way we don't worry about versioning local changes, but we still have standard configs versioned and ready.01:32
bairuiI keep a config.yml file and generate the appropriate settings.php from the current env01:32
fullermd(actualy deployment happens via Makefile, which creates the proper symlinks in the destination)01:32
bairuiconfig.yml gets versioned and the settings.php is always re-created01:33
bairuiI don't have the luxury of running a Makefile on some of my deployment hosts - cheap :)01:33
fullermdIf I don't admin the system, it's not a deployment host; it's something I complain to the client about and bill triple time for any interaction with  :p01:34
bairuiheh... that will be a glorious future, but for now, we suck it up. :-/01:34
fullermdAs far as the testing/XPT/later stuff, it sounds like something particular to your process, so I don't have much of an opinion.01:35
bairuii will compare your settings.php approach with our current way and reconsider our choice.01:35
bairuifair01:35
fullermdIs //todd/ on the LAN?01:35
bairuithe XPT is now a single branch that we merge releases into and tag if happy01:35
bairuiyep01:35
fullermd'k.  I'd avoid using lightweight checkouts across anything slower than a very fast LAN.  They work great on local disk; on an uncongested LAN it's not too bad.  But I wouldn't try it farther than that.01:36
bairuiwow. really? why?01:36
fullermdThey're really made for use on local disk, so they move a lot of data and a lot of round trips.01:37
bairuiah... didn't know that. ok - so, what? branch or checkout as necessary?01:37
bairuiinstead01:37
fullermdWith a gigabit of bandwidth and sub-millisecond latency, that's ignorable.  With a couple megabit and dozens or hundreds of ms, not so much   :)01:37
fullermdUsing a [regular, 'heavy'] checkout in their place would be fine.01:37
bairuioh - so it's merely a speed issue? not a lost-data one?01:37
bairuiok01:37
fullermdOh, yes.  No data safety; just speed.  But a lot of speed.01:38
bairuicool - good to know. if we notice lag, heavy she is.01:38
fullermdA heavy checkout is basically the same as a light one, except it keeps a local cache of the whole history (like a branch).01:38
bairuiironic - i thought light would move less - no history, after all... what am I missing?01:38
fullermdIf you can spare the space, it can be worth doing heavy just because it gives you an extra 'free' backup on another box, too.01:39
bairuithat is a good point01:39
bairuispace is easy to spare01:39
fullermdWell, on the one hand, because it has no history, it has to go to the server to even find out what the pristine state of the _current_ files are.01:39
bairuiah... which reminds me... I haven't read about bzr backup yet... it's on the todo list01:39
bairuithat makes sense (light)01:39
fullermdSo doing e.g. 'bzr diff' has to go grab the originals of all the changed files from the server, every time.01:40
bairuiyuck01:40
bairuiok - sold.01:40
fullermdAnd it does the internal lookups in very network-unoptimized ways.01:40
fullermdThere are cases where somebody has done light checkouts of couple-meg trees, and foudn that an 'update' moves hundreds of megs across the network.01:40
fullermd(due to egregious bugs, rather than the suboptimal-for-usecase design, but still)01:41
bairui*shudder*01:41
bairuiok - we'll go heavy - space is not a concern.01:41
bairuiso, any other nasties in our proposed workflow, mate?01:42
fullermdWell, all your uses of "--remember bzr+ssh://...." are a bit of an eyesore.01:42
fullermdIf you're --remember'ing, why specify each time?  ;)01:42
bairuiok... i think the designer had assumed that these were previously non-existing dirs - recreated as necessary.01:43
bairuiwe'll look at that.01:43
bairuithank you very much, fullermd, for your time and advice on all that. <301:44
fullermdI'm somewhat curious about the "rm -rf web ; bzr co [...]" bit at the end of the XPT migration thing.01:45
* bairui smells pancakes, honey and maple syrup...01:45
fullermdSurely you don't want to do that every time?  Maybe that's just meant to be a "first time" instruction block...01:45
bairui/var/www/xpt/web held the last (view into) a site in xpt01:46
fullermdYah, but wouldn't it already be the existing branch/checkout from last time you do it?  So why rm ; re-checkout instead of just 'update'?01:46
bairuiwe would do that *if* we didn't care for the previous view01:46
bairuiright - so it it's the same view (site), we'd update01:46
bairuiif it's a different website then we'd rm01:47
fullermdAh.  So it's a single location potentially used by different things.01:47
bairuiwe were just being lazy - keeping a single xpt site01:47
bairuiyep01:47
fullermdSpeaking of some of my unfavorite things about webdev...01:47
bairuiheh01:47
fullermd(this is why I often don't rm my feature branches when I'm done with them; instead I rename them to a new feature branch, because webdev means there's always extra setup to do when creating a new workspace   :|  )01:48
bairuiah, yes... we generate code for that reason01:48
fullermdCan people just use userdirs on todd?01:48
bairuiuserdirs? like  /home/user/public_html  ?01:48
* fullermd nods.01:48
bairuium... i haven't set that up... why? what would that give me?01:49
bairuigack! pancake call! :-o01:49
bairuican we pick this up again in a bit, fullermd? :-D01:49
fullermdWell, maybe it's usable instead of xpt; that way you don't worry about stomping on each other so much.01:49
fullermdOr maybe it fit your flow; I'm just spitballing.01:49
bairuiwe can create multiple xpt sites (with our generator scripts) very easily - we were just documenting the lazy case :)01:49
fullermdAh.  Laziness is next to godliness.01:50
fullermdBut both are far removed from pancakes, so I dunno why you're wasting time talking about them when the latter are in offing   :p01:50
bairuiagreed! thanks, mate. later! :-#01:50
fullermdOh, [when you get back] have you worked out in-repo perms on todd so things keep working for everyone?01:53
bairuiback... delicious pancakes.  And oh, my gosh, yes... permissions. A colleague has threatened nasty things with pliers if I don't sort out the permissions thing pretty soon. What's the good oil there, fullermd?03:02
fullermdI dunno.  Break-Free maybe?  That should make the pliers run smoothly.03:03
bairuikeeping my bits away from pliers is the goal here, fullermd...03:03
* bairui suspects fullermd's still looking for that stick ;)03:04
fullermdOh, I'm supposed to be helping YOU in this instance, then?03:07
fullermdThat's way less entertaining.  Hold oh, I'll go cancel the popcorn then...03:07
* bairui needs to invest more in team management skills...03:08
fullermdTeam management is tough sometimes.  Depending on the floor plan, it can be difficult to get enough voltage to everyone's chair.03:08
bairuilol03:08
fullermdWhat OS it the server running?03:08
bairuilinux03:09
fullermdWow, people still use that thing?  Amazing...03:09
bairuioi!03:09
fullermdOK, so you've got SysV filesystem semantics.  Presumably you're using a shared group with everyone in it?03:10
bairuiyep03:10
fullermd'k.  So you'll need g+s on all the dirs under the repos, to keep the group ownership.03:10
fullermdAnd g+w of course.03:10
bairuiout of curiosity, what OS are you on? BSD?03:10
bairuigot that03:10
fullermdbzr will preserve that in existing bzrdirs.  The tricky thing is new branches; they'll get set based on umask.03:10
fullermdYah.03:11
bairuimy current umask is g-w03:11
bairuiwhich sucks03:11
fullermdAs it probably should be.  And anyway, you couldn't make them g+s with umask anyway.03:11
bairuioh03:11
bairuii haven't even *tried* looking into solving this yet03:11
fullermdSo, any time a new branch is created (or a new repo, though that would be way less often), its perms will wind up wrong.03:11
bairuicorrect03:12
bairuiso, bsd then... also in the curiosity realm... editor preference?03:13
fullermdThe cheap easy ugly solution is to brute force the living crap out of it, and setup a cron job to `chgrp -R ; chmod g+ws -R` on /mnt/repos/websites every {hour,day,whatever}.03:13
bairuiah - I was thinking of a script to do the same - manually atm, cronned probably later03:13
bairuii was wondering if a hook might work03:13
fullermdThen anything new will be "correct" soon enough as to hopefully not matter.03:13
bairuiright - is that my *best* approach?03:13
fullermdvi, of course.  Is there another choice somehow?03:14
bairuiit certainly is... easy03:14
bairuivim03:14
fullermdThat falls under the rubric.  Shoot, I've even used elvis.03:14
bairuias long as it has a v and an i in there somewhere, we're cool03:14
fullermdIt may be your best approach.  The other option is for people to do it manually (and that means logging into todd directly and doing stuff).03:15
bairuinope03:15
fullermdIt's possible you could create a third option by hacking bzr on the server.03:15
bairuinope03:15
bairuiok - so, scripts it is03:15
bairuigood to know03:15
fullermdSquirreling with the VFS stack to auto-force perms on the filesystem is another outstanding choice.  I kinda like it, personally.03:15
fullermdIt's a sorta-bug (call it a misfeature, maybe) that bzr won't propogate the repo's permission to newly created branches.  If that got fixed, it would take care of most of your situation.03:16
bairuiand there's no harm in   chmod -R g+ws   on a repo, eh? I mean, don't waste time cherry-picking dirs for that treatment - just smack the lot.03:16
fullermdYou'd still need manual intervention on creating new repos though, whenever you started a new project.03:16
bairuii have a repo-making script that does that atm03:17
bairuiit's not remotely callable yet03:17
fullermdNot as far as bzr is concerned, no.  So as long as it's the same group for everything, and everyone gets equal access to everything, should be OK.03:17
bairuithat is the case. cool.03:17
fullermdNever try to be clever when brute force will solve them problem   :)03:18
fullermd(and when it won't, redefine the problem!)03:18
bairuiheh - never underestimate the power of force03:18
bairuiwe share quite a few aphorisms, fullermd. Chances are we have a common ancestor, at least academically :p03:19
bairuiwell, thanks again, fullermd for your advice. That clears up quite a few todos on my bzr/server plate. yay. :)03:20
fullermdI just think of it as "sharing good sense"   ;)03:22
bairuifair03:22
bairuii tend to do much the same on #vim03:22
bairuiwhat goes around comes around03:22
bairuiand as long as the pliers *never* come around, all's good03:22
fullermdOh, them coming around is fine, as long as they don't close first...03:23
bairuiclosing after would be uncomfortable too...03:23
bairuiespecially were they to encompass *bits* between arrival and said closing oO03:24
fullermdAnyway, glad to be of help.  Now I have to go find a way to explain to people why their plans are impossible and their project is hopeless, without continual profanity...03:24
bairuiwell, you just had some good warm-up training with me :)03:24
bairuithanks again, mate. enjoy. later.03:25
fullermdThough I'm not sure why I'm bothering.  I've been doing that to date, and the project still won't die.  Maybe I should stop censoring...03:25
bairuistart supporting it03:25
bairuiamazing how that kills a project, I've found ;)03:25
=== Mkaysi_ is now known as Mkays
=== Mkays is now known as Mkaysi
=== krow_ is now known as krow
=== gour1 is now known as gour
=== Mkaysi is now known as Mkaysii_
=== Mkaysii_ is now known as Mkaysi
=== Vorpal_ is now known as Vorpal
maxbHmm18:19
maxbcriss-cross merges are annoying18:19
maxbAnd bzr doesn't seem to be being as smart as I'd have hoped about not generating conflicts18:20
maxbOh, no, I was wrong to blame bzr18:25
* jelmer waves to maxb18:25
maxbjelmer: Your latest merge into ~bzr/bzr/daily-ppa seems to have gone rather wrong, and included text changes from bzr.dev, without recording their ancestry18:26
maxbhence the conflicts18:26
jelmerthat's something that often happens during criss crosses18:27
jelmeras there isn't an obvious common base18:28
maxbuhm18:28
maxbWhy would bzr even be considering any text versions that happened in the future, with respect to all of the tips being merged?18:29
maxbI'm inclined to just push --overwrite the daily-ppa branch with the Debian unstable-2.5 one18:31
jelmermaxb: I'm not sure what you mean18:32
jelmermaxb: +1 on overwriting with unstable-2.518:32
maxbThe current daily-ppa branch contains text changes from bzr.dev r603818:32
maxbHowever, it does not include bzr.dev's r6038 in its ancestry18:32
vilajelmer: lp:~jelmer/bzr/more-get-transport-from => 5878 lines ? You're overdoing it ;-p18:33
maxbThis seems rather WTF-worthy18:33
vilajelmer: something went wrong with test_controldir.py, can you check ?18:33
mgzlooked like a line ending change to me.18:34
vilamgz: I thought that at first, but unlikely from jelmer, instead a looks like including 2 copies of itself or something18:34
mgzI nearly commented but was reading mail in a hurry and didn't have time to check if it was18:34
vilas/a looks/it looks/18:34
vilamgz: hello by the way :)18:35
jelmervila: looking18:35
* mgz waves18:35
jelmermaxb: what lines are in daily-build from bzr.dev r6038?18:36
jelmermaxb: r6038 was manually backported to lp:bzr/2.418:38
vilaone should always merge up asap after backporting so *others* don't wtf'ed on further merges18:40
vilajust saying18:40
jelmervila: well, the debian packaging wasn't updated for bzr.dev until recently18:41
jelmerso there wasn't much to merge up to18:42
maxbahhh18:42
maxbright, I think I understand18:43
vilajelmer: I was talking about upstream backport, packaging is a totally different beast (but merges not done upstream are likely to impact packaging too)18:43
maxbSo really the problem is that bzr doesn't track backports, so it's necessary to ensure backports get merged back up into their source branch ASAP to avoid surprises18:43
vilamaxb: exactly18:44
vilamaxb: err, sorry, we're talking about two different kind of backports, your point is similar to mine though18:46
jelmervila: I've updated the more-get-transport-from branch18:49
james_whello all19:14
jelmerHey James19:19
* maxb wonders which is the lesser evil - forking the bzr-daily recipe into three, or backporting python-meliae-dbg and python-configobj19:21
=== yofel_ is now known as yofel

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