Branching a project¶
Before someone else can get a copy of your work, you need to agree on a transfer technology. You may decide to make the top level directory of your branch a network share, an approach familiar to Windows users. Unix users might prefer access to be via SSH, a secure protocol built-in to most SSH servers. Breezy is very flexible in this regard with support for lots of protocols some of which are given below.
Access using the standard filesystem (default).
Access over SSH (best remote option).
Access using SFTP (most SSH servers provide SFTP).
Fast access using the Breezy smart server.
Access using passive FTP.
Access to branches exported by a web server.
Encrypted access to branches exported by a web server.
As indicated above, branches are identified using URLs with the
prefix indicating the transfer technology. If no prefix is given,
normal filenames are assumed. For a complete list of supported
protocols, see the
urlspec online help topic or the
section of the Breezy User Reference.
URLs are normally resolved relative to the root directory of the server,
ftp://example.com/repo/foo means the
/repo/foo directory of
that host. (We say ‘normally’ because some server software like Apache
can be configured to remap URLs arbitrarily, in which case you’ll need to
look at the server configuration to find out which URL corresponds to
To address a path relative to your home directory on the server, use a
tilde like so:
bzr+ssh://example.com/~/public_html should map to
public_html within your home directory.
Access over HTTP or HTTPS is read-only by default. See Pushing over the HTTP smart server for details on configuring read-write access.
The branch command¶
To get a branch based on an existing branch, use the
The syntax is:
brz branch URL [directory]
If a directory is not given, one is created based on the last part of the URL. Here are some examples showing a drive qualified path (M:/) and an SFTP URL respectively:
brz branch M:/cool-trunk brz branch sftp://bill@mary-laptop/cool-repo/cool-trunk
This example shows explicitly giving the directory name to use for the new branch:
brz branch /home/mary/cool-repo/cool-trunk cool
Time and space considerations¶
Depending on the size of the branch being transferred and the speed and latency of the network between your computer and the source branch, this initial transfer might take some time. Subsequent updates should be much faster as only the changes are transferred then.
Keep in mind that Breezy is transferring the
complete history of the branch, not just the latest snapshot.
As a consequence, you can be off the network (or disconnected
from the network share) after
branch completes but you’ll
still be able to
diff the history of the
branch as much as you want. Furthermore, these operations
are quick as the history is stored locally.
Note that Breezy uses smart compression technology to minimize the amount of disk space required to store version history. In many cases, the complete history of a project will take up less disk space than the working copy of the latest version.
As explained in later chapters, Breezy also has support for lightweight checkouts of a branch, i.e. working trees with no local storage of history. Of course, disconnected usage is not available then but that’s a tradeoff you can decide to make if local disk space is really tight for you. Support for limited lookback into history - history horizons - is currently under development as well.
Viewing branch information¶
If you wish to see information about a branch including where it came from,
info command. For example:
brz info cool
If no branch is given, information on the current branch is displayed.