Commit changes into a new revision.


bzr commit [SELECTED...]

-v, --verbose

Display more information.


Set the author’s name, if it’s different from the committer.


Manually set a commit time using commit date format, e.g. ‘2009-10-10 08:00:00 +0100’.


Commit even if nothing has changed.


Mark a bug as being fixed by this revision (see “bzr help bugs”).

-q, --quiet

Only display errors and warnings.

-p, --show-diff

When no message is supplied, show the diff along with the status summary in the message editor.


Refuse to commit if there are unknown files in the working tree.


When committing to a foreign version control system do not push data that can not be natively represented.


Take commit message from this file.


Show usage message and options.

-x ARG, --exclude=ARG

Do not consider changes made to a given path.

-m ARG, --message=ARG

Description of the new revision.


Perform a local commit in a bound branch. Local commits are not pushed to the master branch until a normal commit is performed.

-h, --help

Show help message.


An explanatory message needs to be given for each commit. This is often done by using the –message option (getting the message from the command line) or by using the –file option (getting the message from a file). If neither of these options is given, an editor is opened for the user to enter the message. To see the changed files in the boilerplate text loaded into the editor, use the –show-diff option.

By default, the entire tree is committed and the person doing the commit is assumed to be the author. These defaults can be overridden as explained below.

Selective commits:

If selected files are specified, only changes to those files are committed. If a directory is specified then the directory and everything within it is committed.

When excludes are given, they take precedence over selected files. For example, to commit only changes within foo, but not changes within foo/bar:

bzr commit foo -x foo/bar

A selective commit after a merge is not yet supported.

Custom authors:

If the author of the change is not the same person as the committer, you can specify the author’s name using the –author option. The name should be in the same format as a committer-id, e.g. “John Doe <>”. If there is more than one author of the change you can specify the option multiple times, once for each author.


A common mistake is to forget to add a new file or directory before running the commit command. The –strict option checks for unknown files and aborts the commit if any are found. More advanced pre-commit checks can be implemented by defining hooks. See bzr help hooks for details.

Things to note:

If you accidentially commit the wrong changes or make a spelling mistake in the commit message say, you can use the uncommit command to undo it. See bzr help uncommit for details.

Hooks can also be configured to run after a commit. This allows you to trigger updates to external systems like bug trackers. The –fixes option can be used to record the association between a revision and one or more bugs. See bzr help bugs for details.


ci, checkin

See also:

add, bugs, hooks, uncommit

Previous topic


Next topic


This Page