``bfiles`` is a Mercurial extension for handling large binary files.
You can enable it like any other Mercurial extension: add

  bfiles = /path/to/hg-bfiles/bfiles

to the ``[extensions]`` section of your ``.hgrc`` or ``.hg/hgrc`` file.
(/path/to/hg-bfiles is the directory containing this README.txt file.)

See usage.txt for information on using the extension.

bfiles was designed and written by Greg Ward (greg at gerg dot ca)
with design/interface help from Peter Neelin.

bfiles requires Mercurial 1.4 or later.

The Future

bfiles has been superseded by the largefiles extension in Mercurial
2.0. For new work, you really should upgrade to Mercurial 2.0 and use
largefiles. For migrating existing bfiles repositories to largefiles, 
update to the 'migrate' branch ("hg update migrate") and see


Please use the main Mercurial user mailing list for bfiles questions:


If you want to contribute patches, great!  Please use the patchbomb
extension to prepare and send patches.  Send them to the
mercurial-devel@selenic.com list with the flag "bfiles", e.g.

  hg email -t mercurial-devel@selenic.com --flag bfiles -r tip

Just follow all the guidelines for submitting Mercurial patches:


Latest version

You can get the latest version by cloning my canonical public


There's also a backup on bitbucket.org:


Compatibility guarantee

bfiles is still under development, and therefore makes ABSOLUTELY NO
PROMISES about backwards or forwards compatibility.  I reserve the
right to change the command-line interface, store format, or any
network protocols with no advance notice and no provisions for

In practice, this means that:

  * in case of changes to the SSH protocol, you will have to upgrade
    client and server versions of bfiles at the same time

  * if you have different ways of accessing the same store (e.g.
    locally on the server machine and over SSH), then make sure
    that all copies of bfiles that are used are upgraded at the same

Also, when/if I change the store format (e.g. for case-insensitive
filesystems), I will at least provide a script to convert existing

My vague plan is that after releasing bfiles 0.9, I will only make
incompatible changes if absolutely necessary; after releasing bfiles
1.0, then bfiles will conform to Mercurial's compatibility policy.  That
is, I will make no incompatible changes after 1.0.

Copyright and license

Copyright 2009-2011 Intelerad Medical Systems Incorporated.
Copyright 2009-2011 Gregory P. Ward.

(hg-bfiles was written by Greg Ward <greg at gerg dot ca> while an
employee of Intelerad Medical Systems.)

hg-bfiles is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 2 of the License, or
(at your option) any later version.

hg-bfiles is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with hg-bfiles.  If not, see <http://www.gnu.org/licenses/>.

Bug reports

I'm using an issue tracker at bitbucket.org:


Please search the tracker before reporting new bugs!


If you want to hack on bfiles, design.txt contains obsolete but
easy-to-read design information.  The source code is the final word,

To run the tests, you need Mercurial's own test scripts. The easiest way
to do this is to clone hg-crew-stable as a sibling of hg-bfiles::

  hg clone http://hg.intevation.org/mercurial/crew-stable/ ../hg-crew-stable

(bfiles' test suite required Mercurial 1.7 or later, although bfiles
itself only requires Mercurial 1.4 or later.)

Then you can run the bfiles tests::

  cd tests

Everything you know about running Mercurial's tests applies here.  For
example, you can test bfiles with different Mercurial versions easily::

  cd tests
  ./run-tests.py --with-hg /usr/local/mercurial-1.5/hg

assuming /usr/local/mercurial-1.5 contains a working copy of Mercurial's
source tree updated to Mercurial 1.5ish.