[MERGE] Add support for branch-associated locations

Aaron Bentley aaron at aaronbentley.com
Thu Jun 26 07:12:31 BST 2008


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi all,

This patch adds support for branch-based location lookups.
Specifically, the values ':bound', ':parent', ':public', ':push',
':this' and ':submit'.

This is more convenient at the commandline, and makes scripting and
aliasing more powerful.

Some examples:

# Which revisions are present locally, but not have not been pushed?
# (alias as "unpushed")
bzr missing --mine-only :push

# Which revisions are unpulled?
bzr missing --theirs-only :parent

# Equivalent to diff -r submit:
bzr diff -r ancestor::submit

# Update the local mirror of trunk (I do this prior to merging all
# the time).  (Alias as spull)
bzr pull -d :submit

# Preview a merge of this branch into trunk (alias as premerge?)
bzr merge -d :submit :this --preview

The branch containing the current directory is opened, and the relevant
location is determined.  The branch is then thrown away.  This is not
terribly efficient, but the price is only paid when a string starting
with ':' is supplied as a location.

I used ':' because it is the shortest value that looks like a URL
prefix.  Files beginning with ':' can be be referred to with file:// URLs.

':this' may seem redundant with '.', but they have different behaviors
when used in a subdirectory. :this refers to the containing branch's
root, and '.' refers to the current directory.

Aaron
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFIYzNP0F+nu1YWqI0RAlmvAJ4q4KU/0OhJeA3Wsf8s3RiEvLJYXgCfQsLC
MIVRsel8cALBgaEuwi335NQ=
=j6P3
-----END PGP SIGNATURE-----
-------------- next part --------------
A non-text attachment was scrubbed...
Name: alias.lookup.patch
Type: text/x-diff
Size: 9797 bytes
Desc: not available
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20080626/17c69fe2/attachment-0001.bin 


More information about the bazaar mailing list