1git-svnimport(1) 2================ 3v0.1, July 2005 4 5NAME 6---- 7git-svnimport - Import a SVN repository into git 8 9 10SYNOPSIS 11-------- 12'git-svnimport' [ -o <branch-for-HEAD> ] [ -h ] [ -v ] 13 [ -C <GIT_repository> ] [ -i ] [ -u ] 14 [ -b branch_subdir ] [ -t trunk_subdir ] [ -T tag_subdir ] 15 [ -m ] [ -M regex ] [ <SVN_repository_URL> ] 16 17 18DESCRIPTION 19----------- 20Imports a SVN repository into git. It will either create a new 21repository, or incrementally import into an existing one. 22 23SVN access is done by the SVN:: Perl module. 24 25git-svnimport assumes that SVN repositories are organized into one 26"trunk" directory where the main development happens, "branch/FOO" 27directories for branches, and "/tags/FOO" directories for tags. 28Other subdirectories are ignored. 29 30git-svnimport creates a file ".git/svn2git", which is required for 31incremental SVN imports. 32 33OPTIONS 34------- 35-C <target-dir>:: 36 The GIT repository to import to. If the directory doesn't 37 exist, it will be created. Default is the current directory. 38 39-i:: 40 Import-only: don't perform a checkout after importing. This option 41 ensures the working directory and cache remain untouched and will 42 not create them if they do not exist. 43 44-t <trunk_subdir>:: 45 Name the SVN trunk. Default "trunk". 46 47-T <tag_subdir>:: 48 Name the SVN subdirectory for tags. Default "tags". 49 50-b <branch_subdir>:: 51 Name the SVN subdirectory for branches. Default "branches". 52 53-o <branch-for-HEAD>:: 54 The 'trunk' branch from SVN is imported to the 'origin' branch within 55 the git repository. Use this option if you want to import into a 56 different branch. 57 58-m:: 59 Attempt to detect merges based on the commit message. This option 60 will enable default regexes that try to capture the name source 61 branch name from the commit message. 62 63-M <regex>:: 64 Attempt to detect merges based on the commit message with a custom 65 regex. It can be used with -m to also see the default regexes. 66 You must escape forward slashes. 67 68-v:: 69 Verbosity: let 'svnimport' report what it is doing. 70 71<SVN_repository_URL>:: 72 The URL of the SVN module you want to import. For local 73 repositories, use "file:///absolute/path". 74 75-h:: 76 Print a short usage message and exit. 77 78OUTPUT 79------ 80If '-v' is specified, the script reports what it is doing. 81 82Otherwise, success is indicated the Unix way, i.e. by simply exiting with 83a zero exit status. 84 85Author 86------ 87Written by Matthias Urlichs <smurf@smurf.noris.de>, with help from 88various participants of the git-list <git@vger.kernel.org>. 89 90Based on a cvs2git script by the same author. 91 92Documentation 93-------------- 94Documentation by Matthias Urlichs <smurf@smurf.noris.de>. 95 96GIT 97--- 98Part of the gitlink:git[7] suite 99