This section is for people familiar with CVS and is sort of a
translation of commonly used CVS commands and actions into
BitKeeper commands.
In CVS, the central/master repository is set as follows:
| setenv CVSROOT username@hostname:/path/name |
In BitKeeper, you would use:
| bk parent username@hostname:/path/name |
See bk help parent for all uses of the command.
In CVS, run all remote traffic is run over ssh with the following:
| setenv CVS_RSH /usr/bin/ssh |
BitKeeper defaults to using ssh, but it's possible to do the
following:
| setenv BK_RSH /usr/bin/rsh |
# csh |
| export BK_RSH=/usr/bin/rsh |
# sh |
In CVS, checking out a first-time clone for making changes is done
as follows:
In BitKeeper, the equivalent is:
| bk clone username@hostname:/path/name [destination] |
Note that BitKeeper currently allows you to get only the whole
tree.
In CVS, to add changes there is no file locking, you simply edit
your file copies and then commit.
The ``locking'' and conflict checking is done on write back.
To lock a file for editing in BitKeeper:
| setenv EDITOR /usr/bin/vi |
|
| alias vi 'bk editor' |
|
| vi foo.c |
# checks out and locks foo.c and then execs $EDITOR; works with multiple file args |
Alternatively:
| bk edit |
# locks everything |
| vi foo.c bar.c whatever.c |
|
Changes are committed to a central repository in CVS in one of the
following ways:
| cvs commit [file...] |
|
| cvs commit |
|
| cd some/dir; cvs commit |
# will only commit all changes from some/dir |
The equivalent in BitKeeper is:
Command line:
| bk delta [file ...] |
# autoexpands empty list to all edited files in $CWD only. |
| bk commit |
# commits to local repo |
| bk push |
# pushes to parent repo |
GUI (much preferred):
| bk citool |
# finds all modified files in the tree |
In CVS, to update your clone tree with the central repository's
contents:
| cvs update [-d] |
# -d will pull in directories as well |
In BitKeeper, the equivalent update is: