Skip to content

Commit 945b9c1

Browse files
kiniEric Wong
authored andcommitted
git-svn.txt: elaborate on rev_map files
The man page for `git svn` describes a situation in which "'git svn' will not be able to rebuild" your $GIT_DIR/svn/**/.rev_map* files, but no mention is made of in what circumstances `git svn` *will* be able to do so, how to get `git svn` to do so, or even what these files are. This patch adds a FILES section to the man page with a description of what $GIT_DIR/svn/**/.rev_map* files are and how they are (re)built, and links to this description from various other parts of the man page. Signed-off-by: Keshav Kini <[email protected]> Signed-off-by: Eric Wong <[email protected]>
1 parent 6fe7a30 commit 945b9c1

File tree

1 file changed

+24
-4
lines changed

1 file changed

+24
-4
lines changed

Documentation/git-svn.txt

Lines changed: 24 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,9 @@ COMMANDS
106106
tracking. The name of the [svn-remote "..."] section in the
107107
$GIT_DIR/config file may be specified as an optional
108108
command-line argument.
109+
+
110+
This automatically updates the rev_map if needed (see
111+
'$GIT_DIR/svn/\*\*/.rev_map.*' in the FILES section below for details).
109112

110113
--localtime;;
111114
Store Git commit times in the local timezone instead of UTC. This
@@ -201,6 +204,9 @@ accept. However, '--fetch-all' only fetches from the current
201204
+
202205
Like 'git rebase'; this requires that the working tree be clean
203206
and have no uncommitted changes.
207+
+
208+
This automatically updates the rev_map if needed (see
209+
'$GIT_DIR/svn/\*\*/.rev_map.*' in the FILES section below for details).
204210

205211
-l;;
206212
--local;;
@@ -449,9 +455,10 @@ Any other arguments are passed directly to 'git log'
449455
file cannot be ignored forever (with --ignore-paths) the only
450456
way to repair the repo is to use 'reset'.
451457
+
452-
Only the rev_map and refs/remotes/git-svn are changed. Follow 'reset'
453-
with a 'fetch' and then 'git reset' or 'git rebase' to move local
454-
branches onto the new tree.
458+
Only the rev_map and refs/remotes/git-svn are changed (see
459+
'$GIT_DIR/svn/\*\*/.rev_map.*' in the FILES section below for details).
460+
Follow 'reset' with a 'fetch' and then 'git reset' or 'git rebase' to
461+
move local branches onto the new tree.
455462

456463
-r <n>;;
457464
--revision=<n>;;
@@ -684,7 +691,7 @@ svn-remote.<name>.noMetadata::
684691
+
685692
This option can only be used for one-shot imports as 'git svn'
686693
will not be able to fetch again without metadata. Additionally,
687-
if you lose your $GIT_DIR/svn/\*\*/.rev_map.* files, 'git svn' will not
694+
if you lose your '$GIT_DIR/svn/\*\*/.rev_map.*' files, 'git svn' will not
688695
be able to rebuild them.
689696
+
690697
The 'git svn log' command will not work on repositories using
@@ -1063,6 +1070,19 @@ or tag has appeared. If the subset of branches or tags is changed after
10631070
fetching, then $GIT_DIR/svn/.metadata must be manually edited to remove
10641071
(or reset) branches-maxRev and/or tags-maxRev as appropriate.
10651072

1073+
FILES
1074+
-----
1075+
$GIT_DIR/svn/\*\*/.rev_map.*::
1076+
Mapping between Subversion revision numbers and Git commit
1077+
names. In a repository where the noMetadata option is not set,
1078+
this can be rebuilt from the git-svn-id: lines that are at the
1079+
end of every commit (see the 'svn.noMetadata' section above for
1080+
details).
1081+
+
1082+
'git svn fetch' and 'git svn rebase' automatically update the rev_map
1083+
if it is missing or not up to date. 'git svn reset' automatically
1084+
rewinds it.
1085+
10661086
SEE ALSO
10671087
--------
10681088
linkgit:git-rebase[1]

0 commit comments

Comments
 (0)