5
Information on how to configure Bazaar.
1
7
Location of configuration file
2
8
==============================
3
Each user gets a pair of configurations files in $HOME/.bazaar. The first
4
one, named bazaar.conf, includes default configuration options. The other
5
file, branches.conf, contains configuration information for specific
9
Each user gets a pair of configurations files in ``$HOME/.bazaar``. The first
10
one, named ``bazaar.conf``, includes default configuration options. The other
11
file, ``locations.conf``, contains configuration information for specific
12
branch locations. These files are sometimes referred to as ``ini files``.
10
16
An ini file has three types of contructs: section headers, section
11
17
variables and comments.
15
21
A comment is any line that starts with a "#" (sometimes called a "hash
16
22
mark", "pound sign" or "number sign"). Comment lines are ignored by
17
Bazaar-NG when parsing ini files.
23
Bazaar when parsing ini files.
21
27
A section header is a word enclosed in brackets that starts at the begining
22
of a line, typical section headers look like this::
28
of a line. A typical section header looks like this::
26
The only valid section header for bazaar.conf is [DEFAULT], which is case
27
senstive. The default section provides for setting variables which can be
28
overridden with the branch config file.
32
The only valid section header for bazaar.conf is [DEFAULT], which is
33
case sensitive. The default section provides for setting variables
34
which can be overridden with the branch config file.
30
For branches.conf, the variables from the section with the longest matching
31
section header are used to the exclusion of other potentially valid section
32
headers. A section header uses the path for the branch as the section
33
header. Some examples include::
36
For ``locations.conf``, the variables from the section with the
37
longest matching section header are used to the exclusion of other
38
potentially valid section headers. A section header uses the path for
39
the branch as the section header. Some examples include::
35
41
[http://mybranches.isp.com/~jdoe/branchdir]
36
42
[/home/jdoe/branches/]
43
49
A section variable resides within a section. A section variable contains a
44
variable name, an equals sign and a value and generally takes the following
50
variable name, an equals sign and a value. For example::
47
52
email = John Doe <jdoe@isp.com>
48
53
check_signatures = require
59
Variables defined in a section affect the named directory or URL plus
60
any locations they contain. Policies can be used to change how a
61
variable value is interpreted for contained locations. Currently
62
there are three policies available:
65
the value is interpreted the same for contained locations. This is
66
the default behaviour.
68
the value is only used for the exact location specified by the
71
for contained locations, any additional path components are
72
appended to the value.
74
Policies are specified by keys with names of the form "$var:policy".
75
For example, to define the push location for a tree of branches, the
76
following could be used::
79
push_location = sftp://example.com/location
80
push_location:policy = appendpath
82
With this configuration, the push location for ``/top/location/branch1``
83
would be ``sftp://example.com/location/branch1``.
51
86
The main configuration file, bazaar.conf
52
87
----------------------------------------
54
The main configuration file, $HOME/.bazaar/bazaar.conf, only allows one
55
section called '''[DEFAULT]'''. This default section contains the default
89
The main configuration file, ``$HOME/.bazaar/bazaar.conf``, only allows one
90
section called ``[DEFAULT]``. This default section contains the default
56
91
configuration options for all branches. The default section can be
57
overriden by providing a branch specific section in branches.conf.
92
overriden by providing a branch-specific section in ``locations.conf``.
59
A typical bazaar.conf section often looks like the following::
94
A typical ``bazaar.conf`` section often looks like the following::
62
97
email = John Doe <jdoe@isp.com>
95
130
The path of the editor that you wish to use if *bzr commit* is run without
96
a commit log message. This setting is trumped by the environment variables
97
$BZREDITOR or $EDITOR.
131
a commit log message. This setting is trumped by the environment variable
132
``$BZR_EDITOR``, and overrides ``$VISUAL`` and ``$EDITOR``.
101
136
Defines the behavior for signatures.
104
the gnupg signature for revisions must be present and must be valid
139
The gnupg signature for revisions must be present and must be valid.
107
142
Do not check gnupg signatures of revisions.
110
145
(default) If gnupg signatures for revisions are present, check them.
111
Bazaar-NG will fail if it finds a bad signature, but will not fail if
112
no signature is present
146
Bazaar will fail if it finds a bad signature, but will not fail if
147
no signature is present.
114
149
create_signatures
115
150
-----------------
116
Defines the behaviour of signing revisions. Has three possible values:
117
always, never and when-requied.
151
Defines the behaviour of signing revisions.
120
sign every new revision that is committed
154
Sign every new revision that is committed.
123
157
(default) Sign newly committed revisions only when the branch requires
127
Refuse to sign newly committed revisions, even if the branch requires signatures
161
Refuse to sign newly committed revisions, even if the branch
131
Only useful in branches.conf. Defines whether or not the configuration for
132
this section applies to subdirectories:
166
Only useful in ``locations.conf``. Defines whether or not the
167
configuration for this section applies to subdirectories:
135
(default) This section applies to subdirectories as well
170
(default) This section applies to subdirectories as well.
138
173
This section only applies to the branch at this directory and not
141
176
gpg_signing_command
142
177
-------------------
143
178
(Default: "gpg"). Which program should be used to sign and check revisions.
146
181
gpg_signing_command = /usr/bin/gnpg
187
These options apply only to branches that use the "experimental-branch6"
188
format. They are usually set in ``.bzr/branch/branch.conf`` automatically, but
189
may be manually set in ``locations.conf`` or ``bazaar.conf``.
191
append_revisions_only
192
---------------------
193
If set to "True" then revisions can only be appended to the log, not
194
removed. A branch with this setting enabled can only pull from
195
another branch if the other branch's log is a longer version of its
196
own. This is normally set by ``bzr init --append-revisions-only``.
200
If present, the location of the default branch for pull or merge.
201
This option is normally set by ``pull --remember`` or ``merge
206
If present, the location of the default branch for push. This option
207
is normally set by ``push --remember``.
211
The location that commits should go to when acting as a checkout.
212
This option is normally set by ``bind``.
216
If set to "True", the branch should act as a checkout, and push each commit to
217
the bound_location. This option is normally set by ``bind``/``unbind``.