[ Dekstop Help ] First Contributions - Lesson Learned

Stephen M. Webb stephen.webb at canonical.com
Sun Jan 12 14:59:12 UTC 2014


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

On 01/12/2014 04:35 AM, Greg Beam wrote:
> 
> - Repository Tab: ----------------- * This page needs an overhaul. It uses Natty and Karmic as examples, and points
> users to Apps >> Accessories >> Terminal. That should have sounded alarm bells, but it didn't. Blunder #1 on my
> part.

/self grumbles about too many unmaintained web pages on Ubuntu.com...

> * The biggest issue was local repository setup methodology. Long story short, if we use the Advanced method, which
> is recommended in the standard method section to speed up downloads, one can only a single MP or bzr bundle at a
> time. This was not obvious to me at the time. Those new to working in bzr or in a bzr Distributed + Gatekeeper work
> flow may or may not put that together.

The Bazaar terminology is 'branch.'  You can only work on a single branch at a time.  This is identical to other
distributed version control systems, like git.  The difference is that without using Bazaar plugins, each branch is a
separate directory on your filesystem.  Git and Mercurial allow you to work on separate branches in the same directory
by providing a virtual filesystem that can be swapped in and out.

There is good Bazaar documentation on this [1].  Is it not linked from the Wiki page?

> * Only after several long conversations in IRC, I finally figured out I was causing all sorts of problems for the
> commiters, and sending the wrong data to launchpad.
> 
> knome gave me a solution that works. Further discussion with godbyk confirmed it to be a commonly used. The work
> around is as follows:
> 
> .. bzr branch lp:ubuntu-docs .. cp -R ./ubuntu-docs ./ubuntu-docs-lp12345 .. cd ubuntu-docs-lp12345 .. do work .. 
> .. commit --fixes lp:12345 -F "./commit-notes.txt" .. bzr push lp:~ki7mt/ubuntu-docs/lp1234-fix

The only problem with that workflow is that you're trying to subvert Bazaar.  It's better to do this:

 bzr branch lp:ubuntu-docs ubuntu-docs-lp12345
 cd ubuntu-docs-lp12345
 do work ...
 commit --fixes lp:12345 -F "./commit-notes.txt"
 bzr push lp:~ki7mt/ubuntu-docs/lp1234-fix

Why not check out once and copy?  Because in the mean time someone could have checked in changes to lp:ubuntu-docs and
you would be working from a stale branch.  You could even end up overwriting someone else's changes, although Bazaar
is pretty good about preventing that, forcing you to go back and redo everything with a fresh checkout anyway.  Always
start with a fresh checkout.  On busy projects (ones with more than one active developer), I usually merge from
Launchpad again before create a merge proposal in case the branches have diverged.

If you need to reduce bandwidth, you can use --lightweight to not copy history.

[1] http://doc.bazaar.canonical.com/latest/en/user-guide/branching_a_project.html

- -- 
Stephen M. Webb  <stephen.webb at canonical.com>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.14 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQIcBAEBCAAGBQJS0q2/AAoJEAoP+EW32zQnO3YQAMC6lXgVCQAQZzKdfL4pOU/1
XmJYcID84opKZvkw5LGtSwWpE880X+U6edx61JgbN85se78wfdT63E3snLAp7Idc
p4jAXhIFpE/92wQMXJ2tbW13HJWHaxML6KV4ALN7ditddrDbPQ7j3VnE4yi41gCY
9xveif/HQE/jz7CUBYalkoaIDr/knqwOhScjKoviE5gWFPYOBvYAe8Y8mL2vzbCK
gPygMysDtbYioc7PneggVlzZ1Rdf6ETTssA7EUu91W1tlJb2vJJtdd+mExn5YYEy
HcHwTEdumO/ekFIq6KPI1Eq936yXGwmcbyzVPO4tvKqvSMTxRJ/5yM8EMyaL9OwO
Sg9v4spRYdQosHAUVii90n8e9mM5NQsSBccS6Kvcm8aMD/ajsndpuodNak2TC85/
LIge0s8PHhYtKskSpDpHst5KDlP9w/9DFgMz1SOP8k3a0ARP+1zj4ZQKISq7z90k
lclcQFk4EKOgm9dhSreQQfOD+rdzO/8iUDPbPW3LySgwX5Srg5Q2WdA0efiP7nsx
UMz7wGEUwExhlYywGbF5MD2t241uSgwolD0mdI/CGlBLcTWmIWrWCORksxVWjnIj
/1XR/FjVS4UjakXbQmeElBf0FczWyK8wGn8/m64GI1PIBK2ViMeziBlLSY3EqbJb
8U0UAoKysNQTylyKjFzw
=xBXi
-----END PGP SIGNATURE-----



More information about the ubuntu-doc mailing list