summaryrefslogtreecommitdiffstats
path: root/git-fast-export.html
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2014-09-19 15:32:51 -0700
committerJunio C Hamano <gitster@pobox.com>2014-09-19 15:32:51 -0700
commitac12f0ed6289c50e645af6dfb6e063776bc0f428 (patch)
tree9033ab4b78ce9c9122fbe9b5abcf23d596ea24fd /git-fast-export.html
parentc3f8d8ffe5fd51ed0a3dae59dd8b78f61d7b43d2 (diff)
downloadgit-htmldocs-ac12f0ed6289c50e645af6dfb6e063776bc0f428.tar.gz
Autogenerated HTML docs for v2.1.1-273-g97b886
Diffstat (limited to 'git-fast-export.html')
-rw-r--r--git-fast-export.html109
1 files changed, 84 insertions, 25 deletions
diff --git a/git-fast-export.html b/git-fast-export.html
index de3a1089a..27c1cc278 100644
--- a/git-fast-export.html
+++ b/git-fast-export.html
@@ -3,7 +3,7 @@
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<meta http-equiv="Content-Type" content="application/xhtml+xml; charset=UTF-8" />
-<meta name="generator" content="AsciiDoc 8.6.6" />
+<meta name="generator" content="AsciiDoc 8.6.9" />
<title>git-fast-export(1)</title>
<style type="text/css">
/* Shared CSS for AsciiDoc xhtml11 and html5 backends */
@@ -87,10 +87,16 @@ ul, ol, li > p {
ul > li { color: #aaa; }
ul > li > * { color: black; }
-pre {
+.monospaced, code, pre {
+ font-family: "Courier New", Courier, monospace;
+ font-size: inherit;
+ color: navy;
padding: 0;
margin: 0;
}
+pre {
+ white-space: pre-wrap;
+}
#author {
color: #527bbd;
@@ -219,7 +225,7 @@ div.exampleblock > div.content {
}
div.imageblock div.content { padding-left: 0; }
-span.image img { border-style: none; }
+span.image img { border-style: none; vertical-align: text-bottom; }
a.image:visited { color: white; }
dl {
@@ -349,7 +355,7 @@ div.colist td img {
margin-bottom: 0.1em;
}
-div.toclevel1, div.toclevel2, div.toclevel3, div.toclevel4 {
+div.toclevel0, div.toclevel1, div.toclevel2, div.toclevel3, div.toclevel4 {
margin-top: 0;
margin-bottom: 0;
}
@@ -407,18 +413,14 @@ span.underline { text-decoration: underline; }
span.overline { text-decoration: overline; }
span.line-through { text-decoration: line-through; }
+div.unbreakable { page-break-inside: avoid; }
+
/*
* xhtml11 specific
*
* */
-tt {
- font-family: monospace;
- font-size: inherit;
- color: navy;
-}
-
div.tableblock {
margin-top: 1.0em;
margin-bottom: 1.5em;
@@ -452,12 +454,6 @@ div.tableblock > table[frame="vsides"] {
*
* */
-.monospaced {
- font-family: monospace;
- font-size: inherit;
- color: navy;
-}
-
table.tableblock {
margin-top: 1.0em;
margin-bottom: 1.5em;
@@ -537,6 +533,8 @@ body.manpage div.sectionbody {
@media print {
body.manpage div#toc { display: none; }
}
+
+
</style>
<script type="text/javascript">
/*<![CDATA[*/
@@ -581,7 +579,7 @@ toc: function (toclevels) {
function tocEntries(el, toclevels) {
var result = new Array;
- var re = new RegExp('[hH]([2-'+(toclevels+1)+'])');
+ var re = new RegExp('[hH]([1-'+(toclevels+1)+'])');
// Function that scans the DOM tree for header elements (the DOM2
// nodeIterator API would be a better technique but not supported by all
// browsers).
@@ -610,7 +608,7 @@ toc: function (toclevels) {
var i;
for (i = 0; i < toc.childNodes.length; i++) {
var entry = toc.childNodes[i];
- if (entry.nodeName == 'div'
+ if (entry.nodeName.toLowerCase() == 'div'
&& entry.getAttribute("class")
&& entry.getAttribute("class").match(/^toclevel/))
tocEntriesToRemove.push(entry);
@@ -656,7 +654,7 @@ footnotes: function () {
var entriesToRemove = [];
for (i = 0; i < noteholder.childNodes.length; i++) {
var entry = noteholder.childNodes[i];
- if (entry.nodeName == 'div' && entry.getAttribute("class") == "footnote")
+ if (entry.nodeName.toLowerCase() == 'div' && entry.getAttribute("class") == "footnote")
entriesToRemove.push(entry);
}
for (i = 0; i < entriesToRemove.length; i++) {
@@ -830,7 +828,7 @@ produced incorrect results if you gave these options.</p></div>
<dd>
<p>
Dumps the internal marks table to &lt;file&gt; when complete.
- Marks are written one per line as <tt>:markid SHA-1</tt>. Only marks
+ Marks are written one per line as <code>:markid SHA-1</code>. Only marks
for revisions are dumped; marks for blobs are ignored.
Backends can use this file to validate imports after they
have been completed, or to save the marks table across
@@ -900,6 +898,16 @@ marks the same across runs.</p></div>
</p>
</dd>
<dt class="hdlist1">
+--anonymize
+</dt>
+<dd>
+<p>
+ Anonymize the contents of the repository while still retaining
+ the shape of the history and stored tree. See the section on
+ <code>ANONYMIZING</code> below.
+</p>
+</dd>
+<dt class="hdlist1">
--refspec
</dt>
<dd>
@@ -915,7 +923,7 @@ marks the same across runs.</p></div>
<p>
A list of arguments, acceptable to <em>git rev-parse</em> and
<em>git rev-list</em>, that specifies the specific objects and references
- to export. For example, <tt>master~10..master</tt> causes the
+ to export. For example, <code>master~10..master</code> causes the
current master reference to be exported along with all objects
added since its 10th ancestor commit.
</p>
@@ -928,16 +936,16 @@ marks the same across runs.</p></div>
<div class="sectionbody">
<div class="listingblock">
<div class="content">
-<pre><tt>$ git fast-export --all | (cd /empty/repository &amp;&amp; git fast-import)</tt></pre>
+<pre><code>$ git fast-export --all | (cd /empty/repository &amp;&amp; git fast-import)</code></pre>
</div></div>
<div class="paragraph"><p>This will export the whole repository and import it into the existing
empty repository. Except for reencoding commits that are not in
UTF-8, it would be a one-to-one mirror.</p></div>
<div class="listingblock">
<div class="content">
-<pre><tt>$ git fast-export master~5..master |
+<pre><code>$ git fast-export master~5..master |
sed "s|refs/heads/master|refs/heads/other|" |
- git fast-import</tt></pre>
+ git fast-import</code></pre>
</div></div>
<div class="paragraph"><p>This makes a new branch called <em>other</em> from <em>master~5..master</em>
(i.e. if <em>master</em> has linear history, it will take the last 5 commits).</p></div>
@@ -947,6 +955,57 @@ referenced by that revision range contains the string
</div>
</div>
<div class="sect1">
+<h2 id="_anonymizing">ANONYMIZING</h2>
+<div class="sectionbody">
+<div class="paragraph"><p>If the <code>--anonymize</code> option is given, git will attempt to remove all
+identifying information from the repository while still retaining enough
+of the original tree and history patterns to reproduce some bugs. The
+goal is that a git bug which is found on a private repository will
+persist in the anonymized repository, and the latter can be shared with
+git developers to help solve the bug.</p></div>
+<div class="paragraph"><p>With this option, git will replace all refnames, paths, blob contents,
+commit and tag messages, names, and email addresses in the output with
+anonymized data. Two instances of the same string will be replaced
+equivalently (e.g., two commits with the same author will have the same
+anonymized author in the output, but bear no resemblance to the original
+author string). The relationship between commits, branches, and tags is
+retained, as well as the commit timestamps (but the commit messages and
+refnames bear no resemblance to the originals). The relative makeup of
+the tree is retained (e.g., if you have a root tree with 10 files and 3
+trees, so will the output), but their names and the contents of the
+files will be replaced.</p></div>
+<div class="paragraph"><p>If you think you have found a git bug, you can start by exporting an
+anonymized stream of the whole repository:</p></div>
+<div class="listingblock">
+<div class="content">
+<pre><code>$ git fast-export --anonymize --all &gt;anon-stream</code></pre>
+</div></div>
+<div class="paragraph"><p>Then confirm that the bug persists in a repository created from that
+stream (many bugs will not, as they really do depend on the exact
+repository contents):</p></div>
+<div class="listingblock">
+<div class="content">
+<pre><code>$ git init anon-repo
+$ cd anon-repo
+$ git fast-import &lt;../anon-stream
+$ ... test your bug ...</code></pre>
+</div></div>
+<div class="paragraph"><p>If the anonymized repository shows the bug, it may be worth sharing
+<code>anon-stream</code> along with a regular bug report. Note that the anonymized
+stream compresses very well, so gzipping it is encouraged. If you want
+to examine the stream to see that it does not contain any private data,
+you can peruse it directly before sending. You may also want to try:</p></div>
+<div class="listingblock">
+<div class="content">
+<pre><code>$ perl -pe 's/\d+/X/g' &lt;anon-stream | sort -u | less</code></pre>
+</div></div>
+<div class="paragraph"><p>which shows all of the unique lines (with numbers converted to "X", to
+collapse "User 0", "User 1", etc into "User X"). This produces a much
+smaller output, and it is usually easy to quickly confirm that there is
+no private data in the stream.</p></div>
+</div>
+</div>
+<div class="sect1">
<h2 id="_limitations">Limitations</h2>
<div class="sectionbody">
<div class="paragraph"><p>Since <em>git fast-import</em> cannot tag trees, you will not be
@@ -964,7 +1023,7 @@ a tag referencing a tree instead of a commit.</p></div>
<div id="footnotes"><hr /></div>
<div id="footer">
<div id="footer-text">
-Last updated 2014-06-16 14:13:22 PDT
+Last updated 2014-09-19 15:32:09 PDT
</div>
</div>
</body>