fast-export: support done feature
[git/dscho.git] / Documentation / git-fast-export.txt
blobe3f845371a9f4385cc36590023b18a5aba97a6ad
1 git-fast-export(1)
2 ==================
4 NAME
5 ----
6 git-fast-export - Git data exporter
9 SYNOPSIS
10 --------
11 'git fast-export [options]' | 'git fast-import'
13 DESCRIPTION
14 -----------
15 This program dumps the given revisions in a form suitable to be piped
16 into 'git fast-import'.
18 You can use it as a human-readable bundle replacement (see
19 linkgit:git-bundle[1]), or as a kind of an interactive
20 'git filter-branch'.
23 OPTIONS
24 -------
25 --progress=<n>::
26         Insert 'progress' statements every <n> objects, to be shown by
27         'git fast-import' during import.
29 --signed-tags=(verbatim|warn|strip|abort)::
30         Specify how to handle signed tags.  Since any transformation
31         after the export can change the tag names (which can also happen
32         when excluding revisions) the signatures will not match.
34 When asking to 'abort' (which is the default), this program will die
35 when encountering a signed tag.  With 'strip', the tags will be made
36 unsigned, with 'verbatim', they will be silently exported
37 and with 'warn', they will be exported, but you will see a warning.
39 --tag-of-filtered-object=(abort|drop|rewrite)::
40         Specify how to handle tags whose tagged object is filtered out.
41         Since revisions and files to export can be limited by path,
42         tagged objects may be filtered completely.
44 When asking to 'abort' (which is the default), this program will die
45 when encountering such a tag.  With 'drop' it will omit such tags from
46 the output.  With 'rewrite', if the tagged object is a commit, it will
47 rewrite the tag to tag an ancestor commit (via parent rewriting; see
48 linkgit:git-rev-list[1])
50 -M::
51 -C::
52         Perform move and/or copy detection, as described in the
53         linkgit:git-diff[1] manual page, and use it to generate
54         rename and copy commands in the output dump.
56 Note that earlier versions of this command did not complain and
57 produced incorrect results if you gave these options.
59 --export-marks=<file>::
60         Dumps the internal marks table to <file> when complete.
61         Marks are written one per line as `:markid SHA-1`. Only marks
62         for revisions are dumped; marks for blobs are ignored.
63         Backends can use this file to validate imports after they
64         have been completed, or to save the marks table across
65         incremental runs.  As <file> is only opened and truncated
66         at completion, the same path can also be safely given to
67         \--import-marks.
69 --import-marks=<file>::
70         Before processing any input, load the marks specified in
71         <file>.  The input file must exist, must be readable, and
72         must use the same format as produced by \--export-marks.
74 Any commits that have already been marked will not be exported again.
75 If the backend uses a similar \--import-marks file, this allows for
76 incremental bidirectional exporting of the repository by keeping the
77 marks the same across runs.
79 --fake-missing-tagger::
80         Some old repositories have tags without a tagger.  The
81         fast-import protocol was pretty strict about that, and did not
82         allow that.  So fake a tagger to be able to fast-import the
83         output.
85 --use-done-feature::
86         Start the stream with a 'feature done' stanza, and terminate
87         it with a 'done' command.
89 --no-data::
90         Skip output of blob objects and instead refer to blobs via
91         their original SHA-1 hash.  This is useful when rewriting the
92         directory structure or history of a repository without
93         touching the contents of individual files.  Note that the
94         resulting stream can only be used by a repository which
95         already contains the necessary objects.
97 --full-tree::
98         This option will cause fast-export to issue a "deleteall"
99         directive for each commit followed by a full list of all files
100         in the commit (as opposed to just listing the files which are
101         different from the commit's first parent).
103 [<git-rev-list-args>...]::
104        A list of arguments, acceptable to 'git rev-parse' and
105        'git rev-list', that specifies the specific objects and references
106        to export.  For example, `master{tilde}10..master` causes the
107        current master reference to be exported along with all objects
108        added since its 10th ancestor commit.
110 EXAMPLES
111 --------
113 -------------------------------------------------------------------
114 $ git fast-export --all | (cd /empty/repository && git fast-import)
115 -------------------------------------------------------------------
117 This will export the whole repository and import it into the existing
118 empty repository.  Except for reencoding commits that are not in
119 UTF-8, it would be a one-to-one mirror.
121 -----------------------------------------------------
122 $ git fast-export master~5..master |
123         sed "s|refs/heads/master|refs/heads/other|" |
124         git fast-import
125 -----------------------------------------------------
127 This makes a new branch called 'other' from 'master~5..master'
128 (i.e. if 'master' has linear history, it will take the last 5 commits).
130 Note that this assumes that none of the blobs and commit messages
131 referenced by that revision range contains the string
132 'refs/heads/master'.
135 Limitations
136 -----------
138 Since 'git fast-import' cannot tag trees, you will not be
139 able to export the linux-2.6.git repository completely, as it contains
140 a tag referencing a tree instead of a commit.
144 Part of the linkgit:git[1] suite