summaryrefslogtreecommitdiff
path: root/devdocs/git/git-http-fetch.html
blob: 16aad9e6b665ed7b01be6164a79be5a3d5617f12 (plain)
1
2
3
4
5
6
<h1>git-http-fetch</h1>  <h2 id="_name">Name</h2> <div class="sectionbody">  <p>git-http-fetch - Download from a remote Git repository via HTTP</p>  </div>   <h2 id="_synopsis">Synopsis</h2> <div class="sectionbody"> <div class="verseblock"> <pre class="content" data-language="shell">git http-fetch [-c] [-t] [-a] [-d] [-v] [-w &lt;filename&gt;] [--recover] [--stdin | --packfile=&lt;hash&gt; | &lt;commit&gt;] &lt;URL&gt;</pre> </div> </div>   <h2 id="_description">Description</h2> <div class="sectionbody">  <p>Downloads a remote Git repository via HTTP.</p>   <p>This command always gets all objects. Historically, there were three options <code>-a</code>, <code>-c</code> and <code>-t</code> for choosing which objects to download. They are now silently ignored.</p>  </div>   <h2 id="_options">Options</h2> <div class="sectionbody"> <div class="dlist"> <dl> <dt class="hdlist1" id="Documentation/git-http-fetch.txt-commit-id"> commit-id </dt> <dd> <p>Either the hash or the filename under [URL]/refs/ to pull.</p> </dd> <dt class="hdlist1" id="Documentation/git-http-fetch.txt--a-c-t"> -a, -c, -t </dt> <dd> <p>These options are ignored for historical reasons.</p> </dd> <dt class="hdlist1" id="Documentation/git-http-fetch.txt--v"> -v </dt> <dd> <p>Report what is downloaded.</p> </dd> <dt class="hdlist1" id="Documentation/git-http-fetch.txt--wltfilenamegt"> -w &lt;filename&gt; </dt> <dd> <p>Writes the commit-id into the specified filename under $GIT_DIR/refs/&lt;filename&gt; on the local end after the transfer is complete.</p> </dd> <dt class="hdlist1" id="Documentation/git-http-fetch.txt---stdin"> --stdin </dt> <dd> <p>Instead of a commit id on the command line (which is not expected in this case), <code>git http-fetch</code> expects lines on stdin in the format</p> <div class="literalblock"> <div class="content"> <pre>&lt;commit-id&gt;['\t'&lt;filename-as-in--w&gt;]</pre> </div> </div> </dd> <dt class="hdlist1" id="Documentation/git-http-fetch.txt---packfilelthashgt"> --packfile=&lt;hash&gt; </dt> <dd> <p>For internal use only. Instead of a commit id on the command line (which is not expected in this case), <code>git http-fetch</code> fetches the packfile directly at the given URL and uses index-pack to generate corresponding .idx and .keep files. The hash is used to determine the name of the temporary file and is arbitrary. The output of index-pack is printed to stdout. Requires --index-pack-args.</p> </dd> <dt class="hdlist1" id="Documentation/git-http-fetch.txt---index-pack-argsltargsgt"> --index-pack-args=&lt;args&gt; </dt> <dd> <p>For internal use only. The command to run on the contents of the downloaded pack. Arguments are URL-encoded separated by spaces.</p> </dd> <dt class="hdlist1" id="Documentation/git-http-fetch.txt---recover"> --recover </dt> <dd> <p>Verify that everything reachable from target is fetched. Used after an earlier fetch is interrupted.</p> </dd> </dl> </div> </div><div class="_attribution">
  <p class="_attribution-p">
    &copy; 2012&ndash;2024 Scott Chacon and others<br>Licensed under the MIT License.<br>
    <a href="https://git-scm.com/docs/git-http-fetch" class="_attribution-link">https://git-scm.com/docs/git-http-fetch</a>
  </p>
</div>