bzr
Installation
Fedora
- It seem to be in yum extras
yum install bzr bzrtools
OpenBSD
make fake libpthread.so.6.3 - ln -s libpthread.so.6.2 libpthread.so.6.3
update any outdated packages - pkg_add -uvi
install python - pkg_add -vi python
install cElementTree - pkg_add -vi py-cElementTree
make sure your python libs are readable - chmod -R a+rX /usr/local/lib/python* ; chmod -R a+rX /usr/local/lib/libpython*
download bzr - ftp http://bazaar-vcs.org/releases/src/bzr-0.18.tar.gz
Find more recent versions at http://bazaar-vcs.org/Download.
install bzr - sudo python setup.py install
Using
- initialize a dir
# cd /etc # bzr init
- ignore files you don't want to deal with
# cd /etc # vi .bzrignore
Specific files in the root of the bzr'ed dir should look like./passwd.lock. Files with a specific name that should be ignored anywhere in the file tree are just that name spelled out ala passwd.lock. Globs should look like *.rpmnew.
Here's an example .bzrignore.*.jpg *.jpeg *.gif *.ps *.pdf *.zip *.tar.gz *.tgz *.rpmnew .*.swp .bzr.log .viminfo .mysql_history .bash_history .lesshst ./localtime ./prelink_cache ./prelink.cache ./ld.so.cache ./selinux ./avahi/etc/localtime
- Test the .bzrignore file
# cd /etc # bzr ignored
This will print out a bunch of files that would be ignored. Because you havn't added any subdirs yet, this only checks the contents of/etc and not any subdirs of /etc
- Add everything
# cd /etc # bzr add
- Remove anything you didn't mean to version
# cd /etc # bzr rm ./blort.lock # bzr ignore ./blort.lock
Runningbzr ignore ./blort.lock is the same as adding ./blort.lock to .bzrignore.
- Do a check in
# cd /etc # bzr ci
- Come up with a way to regularly add and check in files
I use a perl script I wrote called bzrbatch and I call it from cron.hourly. The bzrbatch script should be distributed everywhere via cfrun. The an example cron.hourly script can be found in the perl cvs module in scripts/bzr.
