2977.1.3
by Ian Clatworthy
1st cut at the 'Personal version control' chapter |
1 |
Releasing a project |
2 |
=================== |
|
3 |
||
4 |
Packaging a release |
|
5 |
------------------- |
|
6 |
||
7 |
The ``export`` command is used to package a release, i.e. to |
|
8 |
take a copy of the files and directories in a branch and |
|
9 |
package them into a fresh directory or archive. For example, |
|
10 |
this command will package the last committed version into |
|
11 |
a ``tar.gz`` archive file:: |
|
12 |
||
13 |
bzr export ../releases/my-stuff-1.5.tar.gz |
|
14 |
||
15 |
The ``export`` command uses the suffix of the archive file |
|
16 |
to work out the type of archive to create as shown below. |
|
17 |
||
18 |
================= ========================= |
|
19 |
Supported formats Autodetected by extension |
|
20 |
================= ========================= |
|
21 |
dir (none) |
|
22 |
tar .tar |
|
23 |
tbz2 .tar.bz2, .tbz2 |
|
24 |
tgz .tar.gz, .tgz |
|
25 |
zip .zip |
|
26 |
================= ========================= |
|
27 |
||
3431.4.1
by Benjamin Rister
Cleaned up a sentence's structure |
28 |
If you wish to package a revision other than the last one, use |
2977.1.3
by Ian Clatworthy
1st cut at the 'Personal version control' chapter |
29 |
the ``-r`` option. If you wish to tune the root directory inside |
30 |
the archive, use the ``--root`` option. See the online help or |
|
31 |
User Reference for further details on the options supported by |
|
32 |
``export``. |
|
33 |
||
34 |
Tagging a release |
|
35 |
----------------- |
|
36 |
||
37 |
Rather than remembering which version was used to package a release, |
|
38 |
it's useful to define a symbolic name for a version using the ``tag`` |
|
39 |
command like this:: |
|
40 |
||
41 |
bzr tag version-1-5 |
|
42 |
||
43 |
That tag can be be used later whenever a revision identifier is |
|
44 |
required, e.g.:: |
|
45 |
||
46 |
bzr diff -r tag:version-1-5 |
|
47 |
||
48 |
To see the list of tags defined in a branch, use the ``tags`` command. |