import¶
vb import [SUBCOMMAND] [OPTIONS] NEW-REPOSITORY [INPUT-FILE]
Description¶
Read interchange format generated by another VCS and use it to construct a new VisionByte repository named by the NEW-REPOSITORY argument. If no input file is supplied the interchange format data is read from standard input.
The –incremental option allows an existing repository to be extended with new content. The –rename-* options may be useful to avoid name conflicts when using the –incremental option. The –admin-user option is ignored if –incremental is specified.
The argument to –rename-* contains one % character to be replaced
with the original name. For example, --rename-tag svn-%-tag renames
the tag called release to svn-release-tag.
–ignore-tree is useful for importing Subversion repositories which
move branches to subdirectories of branches/deleted instead of
deleting them. It can be supplied multiple times if necessary.
The –attribute option takes a quoted string argument comprised of a
Git committer email and the username to be attributed to corresponding
check-ins in the VisionByte repository. This option can be repeated. For
example, –attribute drh@sqlite.org drh –attribute xyz@abc.net X.
Attributions are persisted to the repository so that subsequent
vb git export operations attribute VisionByte commits to corresponding
Git Committer <git@committer.com> users, and incremental imports with
vb import --git --incremental use previous –attribute records.
Options¶
- -i, --incremental¶
Allow importing into an existing repository
- -f, --force¶
Overwrite repository if already exists
- -q, --quiet¶
Omit progress output
- --no-rebuild¶
Skip the
rebuilding metadatastep
- --no-vacuum¶
Skip the final VACUUM of the database file
- --rename-trunk NAME¶
Use NAME as name of imported trunk branch
- --rename-branch PAT¶
Rename all branch names using PAT pattern
- --rename-tag PAT¶
Rename all tag names using PAT pattern
- -A, --admin-user NAME¶
Use NAME for the admin user
Subcommands¶
vb import –git¶
vb import --git [OPTIONS] NEW-REPOSITORY [INPUT-FILE]
Description¶
Import from the git-fast-export file format (default)
Options¶
- --import-marks¶
FILE Restore marks table from FILE
- --export-marks¶
FILE Save marks table to FILE
- --rename-master¶
NAME Renames the master branch to NAME
- --use-author¶
Uses author as the committer
- --attribute¶
EMAIL USERAttribute commits to USER instead of Git committer EMAIL address
vb import –svn¶
vb import --svn [OPTIONS] NEW-REPOSITORY [INPUT-FILE]
Description¶
Import from the svnadmin-dump file format behaviour (unless overridden by –flat) is to treat 3 folders in the SVN root as special, following the common layout of SVN repositories. These are (by default) trunk/, branches/ and tags/. The SVN –deltas format is supported but not required.
Options¶
- --trunk FOLDER¶
Name of trunk folder
- --branches FOLDER¶
Name of branches folder
- --tags FOLDER¶
Name of tags folder
- --base PATH¶
Path to project root in repository
- --flat¶
The whole dump is a single branch
- --rev-tags¶
Tag each revision, implied by -i
- --no-rev-tags¶
Disables tagging effect of -i
- --rename-rev PAT¶
Rev tag names, default
svn-rev-%
- --ignore-tree DIR¶
Ignores subtree rooted at DIR
See Also¶
See also
Examples¶
Import from a git-fast-export stream
git fast-export --all > repo.export
vb import --git demo.vbyte repo.export
Import incrementally and preserve Git authors
git fast-export --all > repo.export
vb import --git --incremental --use-author demo.vbyte repo.export
Import from an svnadmin dump with custom layout
svnadmin dump /path/to/repo > repo.svndump
vb import --svn --trunk trunk --branches branches --tags tags demo.vbyte repo.svndump