Re: Feedback on merging via bzr
On 2010-01-18 16:18:44 +1100, Andrew Bennetts wrote: That's right. If you're interested, bug 491711 https://bugs.launchpad.net/bzr/+bug/491711 is tracking progress on this, and there's a branch at adds the hook point going through code review at the moment. Perhaps there should be a bzr-builddeb bug (or bug task on 491711?) too? I've filed a bug against bzr-builddeb about this before I knew about the ongoing work on hooks: https://bugs.launchpad.net/bugs/501754 (Better support for merging debian/changelog) Michael -- ubuntu-distributed-devel mailing list ubuntu-distributed-devel@lists.ubuntu.com Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-distributed-devel
Re: Feedback on merging via bzr
On 2010-01-17 22:45:53 -0500, Scott Kitterman wrote: Currently I often insert a step 0 before starting on merging with bzr: - Check if the Debian branch is uptodate. Perhaps I got unlucky when picking a package to merge but several of the packages I wanted to merge had outdated Debian branches so I had to do it by hand (download the Debian .dsc and the Ubuntu delta from PTS and merge it). Step 1: Getting the source: Using MoM, I would have grab-merge.sh regina-normal and then had local copies of the common ancestor package, the current Debian package, the current Ubuntu package, and a proposed merge with any conflicting files listed. The UDD equivalent seems to be: $bzr branch lp:ubuntu/regina-normal regina-normal $password for ssh key $cd regina-normal $bzr merge-package lp:debian/squeeze/regina-normal I usually do a bzr init-repo before and branch both the Ubuntu and Debian branch and use the local Debian branch for merging and diffing. It would be really nice if bzr warned one if the format of local branch and the remote repository differ *before* I start working on something. I merged fuse the usual way (and used bzr init-repo for storing the branches) and when I was about to push the branch towards my LP account for sponsoring, I got told that bzr can't push it because the LP branch uses a different format. I branched the Ubuntu branch once again (this time without bzr init-repo so it keeps its format) and kind of redid the merge (I copied the changed files from the other branch into this one). This time the pushing worked. But it cost me unnecessary time. Michael -- ubuntu-distributed-devel mailing list ubuntu-distributed-devel@lists.ubuntu.com Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-distributed-devel
Re: Feedback on merging via bzr
On Mon, 2010-01-18 at 12:07 +0100, Michael Bienia wrote: On 2010-01-17 22:45:53 -0500, Scott Kitterman wrote: Currently I often insert a step 0 before starting on merging with bzr: - Check if the Debian branch is uptodate. This has bitten me a few times. When you go to a packages launchpad page under branches, it would be nice if there were links to the ubuntu and debian branches. This way one could quickly determine if the debian branch has been updated. Best regards Charlie -- ubuntu-distributed-devel mailing list ubuntu-distributed-devel@lists.ubuntu.com Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-distributed-devel
Re: Feedback on merging via bzr
2010/1/18 Scott Kitterman ubu...@kitterman.com: I spent some time over the holidays giving merging via bzr and the UDD tools. I understand that development of the tools to support this is still a work in progress and the much of this feedback probably represents work that you already know needs doing. This mail is based on notes I took recently while doing a merge of regina-normal. As merges go, it was not a complex one. I'm writing this from the perspective of someone who is reasonably familiar with merging using merge-o-matic (~3 years of experience), but relatively knew to bzr. I would have been dead almost immediately if not for the w.u.c documentation [1]. Step 1: Getting the source: Using MoM, I would have grab-merge.sh regina-normal and then had local copies of the common ancestor package, the current Debian package, the current Ubuntu package, and a proposed merge with any conflicting files listed. The UDD equivalent seems to be: $bzr branch lp:ubuntu/regina-normal regina-normal $password for ssh key $cd regina-normal $bzr merge-package lp:debian/squeeze/regina-normal I do $bzr init-repo package $cd package $bzr branch lp:ubuntu/package lucid $bzr branch lp:debian/package squeeze Text conflict in debian/changelog 1 conflicts encountered. The merge resulted in 1 conflicts. Please resolve these and commit the changes with bzr commit. Hopefully per-file hook will solve this Step 2 working on the package: Step 3 checking the package: At this point I want to check the package against the previous Debian and Ubuntu packages to make sure I have it correct. Traditionally, I would locally debdiff the proposed merge with both the previous Debian and Ubuntu packages to make sure I had documented all of the Ubuntu diff and not lost any needed changes in the merge. To do it the new way, I did: $bzr diff --old lp:debian/squeeze/regina-normal | less ssh key (repeat, including redownloading each time the diff is done) At this point in the package/lucid branch you have all package revisions and tags so you can do this : $bzr diff -r tag:0.1-3ubuntu5 #debdiff against old ubuntu $bzr diff -r tag:0.1-6 #debdiff against debian Or any package release for that matter. see $bzr tags Also you might want to add --prefix=old-version/:new-version/ such that bzr diff looks like debdiff. I assume bzr diff --old lp:ubuntu/regina-normal would have worked for the diff from the previous Ubuntu package, but it isn't documented and I didn't think to try it at the time. Again use your local revisions. After you grab debian ubuntu branch disconnect your network =) It will make you think UDD way. Then commit the result: $ bzr ci -m * Update debian/changelog to include undocumented differences from Debian * Remove extraneous whitespace changes Committing to: ~/devel/boost/merge/regina-normal/ modified debian/changelog modified python/testsuite/trigeneral.test Committed revision 20. Better use debcommit it takes new entries from debian/changlog and appends --fixes lp:XX such that when you push this branch it will get linked to bugs in lp. This method of diffing works fine, except that the previous branch has to be re- downloaded each time the diff is done. In this case I was trying to remove extraneous white space changes that had crept into the packages so it took several tries to get them all. For larger packages or people with a slow internet connection, the need to re-download the diff will have a substantial negative impact. Additionally, I miss a way to diff just the debian directories. For new upstream releases (which this wasn't, so I didn't hit it) I find this a critical way to review the packaging differences between the old and new packages. No see above Step 4: Building the package: In the old method, I would debuild -S (-sa if needed) -v and have a package ready for uploading. bzr builddeb -S -- -v4.6-1ubuntu1 ? huh I just use $bzr bd#regular build $bzr bd --quick #customised to build with pbuilder (should be named slow) $bzr bd --source #create source package Now this one looks easy, but has the hidden trap of bzr builddeb providing only -S from dpkg-buildpackage and requiring an extra flag to pass other options to dpkg-buildpackage (--). I think this needs a rethink [2]. See builddeb manual for builddeb.conf Step 5: Testing the package: This is orthogonal to UDD, so I won't cover it. Step 6: Uploading the package: I don't have upload rights so I can't comment. $ dput ubuntu regina-normal_4.6-1.1ubuntu1_source.changes At this point, I'd be done under the old method (and I could have stopped here now and let the branch be created from the uploaded package, but I decided to persevere). $ bzr mark-uploaded $ bzr push lp:ubuntu/regina-normal ssh key ... Now we are done and have both an updated package in the archive and an updated branch on
Re: Feedback on merging via bzr
On Mon, Jan 18, 2010 at 12:21 PM, Scott Kitterman ubu...@kitterman.com wrote: I usually use the ancestor revision shortcut for selecting the revision to diff: Ubuntu patch compared to the common base version: ~/src/pkg-name/lucid/ $ bzr diff -rancestor:../squeeze/ Debian patch compared to the common base version: ~/src/pkg-name/squeeze/ $ bzr diff -rancestor:../lucid/ These two commands should generate the equivalent of the .patch files from MoM. That doesn't solve the issue with the data being local versus remote, but it definitely looks very helpful. As mentioned earlier in the thread, it makes sense to always work from local branches with a local repository: 1. Create a local repository: ~/src/$ bzr init-repo src-pkg-name 2. Checkout latest Ubuntu version: ~/src/pkg-name/$ bzr co lp:ubuntu/pkg-name/ lucid 3. Checkout latest Debian version: ~/src/pkg-name/$ bzr co lp:debian/pkg-name/ squeeze 4. Create a local branch to work on the merge: ~/src/pkg-name/$ bzr branch lucid l-merge Would you add that to the wiki page on merging? Done (it's a wiki page - anyone can edit it ;) ). -- Mathias Gug Ubuntu Developer http://www.ubuntu.com -- ubuntu-distributed-devel mailing list ubuntu-distributed-devel@lists.ubuntu.com Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-distributed-devel
Re: Feedback on merging via bzr
On Jan 17, 2010, at 10:45 PM, Scott Kitterman wrote: I spent some time over the holidays giving merging via bzr and the UDD tools. I understand that development of the tools to support this is still a work in progress and the much of this feedback probably represents work that you already know needs doing. This mail is based on notes I took recently while doing a merge of regina-normal. As merges go, it was not a complex one. This is good stuff Scott. It mirrors some of my recent experience using UDD to do various kinds of development. Of course, my packaging experience is weeks old, not years old :), so I don't have much comparison of the traditional way to draw on. The UDD equivalent seems to be: $bzr branch lp:ubuntu/regina-normal regina-normal $password for ssh key ssh-agent helps here so that you only have to enter this once. $cd regina-normal $bzr merge-package lp:debian/squeeze/regina-normal Text conflict in debian/changelog 1 conflicts encountered. The merge resulted in 1 conflicts. Please resolve these and commit the changes with bzr commit. This gives me the proposed merge. The conflict in this case seems to occur with every merge I try. The most recent Debian and Ubuntu debian/changelog entries conflict with each other and the file has to be edited to move the most recent Debian entry above the most recent Ubuntu entry. Yep, I noticed exactly the same thing. To get ready to start to work on the actual merge, I need to also do: $ vim debian/changelog (re-arrange as described) $ bzr resolve All conflicts resolved. Emacs to the rescue here (for the crazy people who use it :). Emacs auto-resolves files when you save them. It's a nice convenience that hasn't bitten me yet :). Step 3 checking the package: At this point I want to check the package against the previous Debian and Ubuntu packages to make sure I have it correct. Traditionally, I would locally debdiff the proposed merge with both the previous Debian and Ubuntu packages to make sure I had documented all of the Ubuntu diff and not lost any needed changes in the merge. To do it the new way, I did: $bzr diff --old lp:debian/squeeze/regina-normal | less ssh key (repeat, including redownloading each time the diff is done) It would probably be better branch these locally if you're going to do a lot of diffing. I know a huge amount of work has gotten to getting things as far as they are. This feedback is not meant to miminize this accomplishment. I do not, however, feel like this facility is really ready for general use yet. I think it would make sense to submit bug reports to help streamline things, but I'm not sure where those bug reports would go. On the bzr-builddeb plugin on Launchpad? -Barry signature.asc Description: PGP signature -- ubuntu-distributed-devel mailing list ubuntu-distributed-devel@lists.ubuntu.com Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-distributed-devel
Re: Feedback on merging via bzr
On Jan 17, 2010, at 10:45 PM, Scott Kitterman wrote: I spent some time over the holidays giving merging via bzr and the UDD tools. I understand that development of the tools to support this is still a work in progress and the much of this feedback probably represents work that you already know needs doing. This mail is based on notes I took recently while doing a merge of regina-normal. As merges go, it was not a complex one. Oh, also, there are some interesting steps you took that I did not notice were documented on the wiki page. Maybe you can take a pass through them and update them with some of the things you learned (e.g. bzr mark-uploaded, diffing the Ubuntu and Debian sources). https://wiki.ubuntu.com/DistributedDevelopment/Documentation -Barry signature.asc Description: PGP signature -- ubuntu-distributed-devel mailing list ubuntu-distributed-devel@lists.ubuntu.com Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-distributed-devel
Re: Feedback on merging via bzr
On Mon, Jan 18, 2010 at 12:21 PM, Scott Kitterman ubu...@kitterman.com wrote: I usually use the ancestor revision shortcut for selecting the revision to diff: Ubuntu patch compared to the common base version: ~/src/pkg-name/lucid/ $ bzr diff -rancestor:../squeeze/ Debian patch compared to the common base version: ~/src/pkg-name/squeeze/ $ bzr diff -rancestor:../lucid/ These two commands should generate the equivalent of the .patch files from MoM. That doesn't solve the issue with the data being local versus remote, but it definitely looks very helpful. As mentioned earlier in the thread, it makes sense to always work from local branches with a local repository: 1. Create a local repository: ~/src/$ bzr init-repo src-pkg-name 2. Checkout latest Ubuntu version: ~/src/pkg-name/$ bzr co lp:ubuntu/pkg-name/ lucid 3. Checkout latest Debian version: ~/src/pkg-name/$ bzr co lp:debian/pkg-name/ squeeze 4. Create a local branch to work on the merge: ~/src/pkg-name/$ bzr branch lucid l-merge Would you add that to the wiki page on merging? Done (it's a wiki page - anyone can edit it ;) ). Certainly, but I think wiki edits should generally be done by people who understand what they are talking about. In this area, I don't particularly qualify yet. Thanks, Scott K -- ubuntu-distributed-devel mailing list ubuntu-distributed-devel@lists.ubuntu.com Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-distributed-devel
Re: Feedback on merging via bzr
On Mo, Jan 18, 2010 at 04:45:53 (CET), Scott Kitterman wrote: This method of diffing works fine, except that the previous branch has to be re- downloaded each time the diff is done. In this case I was trying to remove extraneous white space changes that had crept into the packages so it took several tries to get them all. For larger packages or people with a slow internet connection, the need to re-download the diff will have a substantial negative impact. As already mentioned, fetching both branches (the ubuntu and debian import) into a local repository mitigates this problem. The 'grab-merge'-like wrapper that you proposed could and probably should do exactly that. Additionally, I miss a way to diff just the debian directories. For new upstream releases (which this wasn't, so I didn't hit it) I find this a critical way to review the packaging differences between the old and new packages. This is possible and in fact for me a killer argument for using DVCS tools for managing packages in the first place: bzr diff --old lp:debian/package debian/control for diffing only debian control, or bzr diff --old lp:debian/package debian for diffing the debian subdirectory only. -- Gruesse/greetings, Reinhard Tartler, KeyID 945348A4 -- ubuntu-distributed-devel mailing list ubuntu-distributed-devel@lists.ubuntu.com Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-distributed-devel
Re: Feedback on merging via bzr
forgot mailing list sorry silly gmail So then you get to read the reply twice. ;-) -- Forwarded message -- From: Dmitrijs Ledkovs dmitrij.led...@gmail.com Date: 2010/1/18 Subject: Re: Feedback on merging via bzr To: Scott Kitterman ubu...@kitterman.com 2010/1/18 Scott Kitterman ubu...@kitterman.com: Ubuntu patch compared to the common base version: ~/src/pkg-name/lucid/ $ bzr diff -rancestor:../squeeze/ Debian patch compared to the common base version: ~/src/pkg-name/squeeze/ $ bzr diff -rancestor:../lucid/ These two commands should generate the equivalent of the .patch files from MoM. That doesn't solve the issue with the data being local versus remote, but it definitely looks very helpful. Â Would you add that to the wiki page on merging? Scott K What do you mean? These commands _do not_ require access to remote branches at all! It's all local no trips to launchpad. I'd missed that he was working from local checkouts when I read the message. Scott K -- ubuntu-distributed-devel mailing list ubuntu-distributed-devel@lists.ubuntu.com Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-distributed-devel