Debian Codegraph @

doc/html/hg-archive.html

raw
1 <?xml version="1.0" encoding="utf-8"?>
2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4 <head>
5 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6 <meta name="generator" content="Docutils 0.21.2: https://docutils.sourceforge.io/" />
7 <title>hg archive</title>
8 <link rel="stylesheet" href="../style.css" type="text/css" />
9 </head>
10 <body>
11 <div class="document" id="hg-archive">
12 <span id="hg-archive-1"></span>
13 <h1 class="title">hg archive</h1>
14 <h2 class="subtitle" id="create-an-unversioned-archive-of-a-repository-revision">create an unversioned archive of a repository revision</h2>
15
16 <div class="contents htmlonly topic" id="contents">
17 <p class="topic-title"><a class="reference internal" href="#top">Contents</a></p>
18 <ul class="simple">
19 <li><a class="reference internal" href="#synopsis" id="toc-entry-1">Synopsis</a></li>
20 <li><a class="reference internal" href="#description" id="toc-entry-2">Description</a></li>
21 <li><a class="reference internal" href="#options" id="toc-entry-3">Options</a></li>
22 </ul>
23 </div>
24 <div class="section" id="synopsis">
25 <h1><a class="toc-backref" href="#contents">Synopsis</a></h1>
26 <pre class="literal-block">
27 hg archive [OPTION]... DEST
28 </pre>
29 </div>
30 <div class="section" id="description">
31 <h1><a class="toc-backref" href="#contents">Description</a></h1>
32 <p>By default, the revision used is the parent of the working
33 directory; use -r/--rev to specify a different revision.</p>
34 <p>The archive type is automatically detected based on file
35 extension (to override, use -t/--type).</p>
36 <div class="verbose docutils container">
37 <p>Examples:</p>
38 <ul>
39 <li><p class="first">create a zip file containing the 1.0 release:</p>
40 <pre class="literal-block">
41 hg archive -r 1.0 project-1.0.zip
42 </pre>
43 </li>
44 <li><p class="first">create a tarball excluding .hg files:</p>
45 <pre class="literal-block">
46 hg archive project.tar.gz -X &quot;.hg*&quot;
47 </pre>
48 </li>
49 </ul>
50 </div>
51 <p>Valid types are:</p>
52 <table class="docutils field-list" frame="void" rules="none">
53 <col class="field-name" />
54 <col class="field-body" />
55 <tbody valign="top">
56 <tr class="field"><th class="field-name"><tt class="docutils literal">files</tt>:</th><td class="field-body">a directory full of files (default)</td>
57 </tr>
58 <tr class="field"><th class="field-name"><tt class="docutils literal">tar</tt>:</th><td class="field-body">tar archive, uncompressed</td>
59 </tr>
60 <tr class="field"><th class="field-name"><tt class="docutils literal">tbz2</tt>:</th><td class="field-body">tar archive, compressed using bzip2</td>
61 </tr>
62 <tr class="field"><th class="field-name"><tt class="docutils literal">tgz</tt>:</th><td class="field-body">tar archive, compressed using gzip</td>
63 </tr>
64 <tr class="field"><th class="field-name"><tt class="docutils literal">txz</tt>:</th><td class="field-body">tar archive, compressed using lzma (only in Python 3)</td>
65 </tr>
66 <tr class="field"><th class="field-name"><tt class="docutils literal">uzip</tt>:</th><td class="field-body">zip archive, uncompressed</td>
67 </tr>
68 <tr class="field"><th class="field-name"><tt class="docutils literal">zip</tt>:</th><td class="field-body">zip archive, compressed using deflate</td>
69 </tr>
70 </tbody>
71 </table>
72 <p>The exact name of the destination archive or directory is given
73 using a format string; see <a class="reference external" href="hg-export.html"><tt class="docutils literal">hg help export</tt></a> for details.</p>
74 <p>Each member added to an archive file has a directory prefix
75 prepended. Use -p/--prefix to specify a format string for the
76 prefix. The default is the basename of the archive, with suffixes
77 removed.</p>
78 <p>Returns 0 on success.</p>
79 </div>
80 <div class="section" id="options">
81 <h1><a class="toc-backref" href="#contents">Options</a></h1>
82 <table class="docutils option-list" frame="void" rules="none">
83 <col class="option" />
84 <col class="description" />
85 <tbody valign="top">
86 <tr><td class="option-group">
87 <kbd><span class="option">--no-decode</span></kbd></td>
88 <td>do not pass files through decoders</td></tr>
89 <tr><td class="option-group" colspan="2">
90 <kbd><span class="option">-p</span>, <span class="option">--prefix <var>&lt;PREFIX&gt;</var></span></kbd></td>
91 </tr>
92 <tr><td>&nbsp;</td><td>directory prefix for files in archive</td></tr>
93 <tr><td class="option-group" colspan="2">
94 <kbd><span class="option">-r</span>, <span class="option">--rev <var>&lt;REV&gt;</var></span></kbd></td>
95 </tr>
96 <tr><td>&nbsp;</td><td>revision to distribute</td></tr>
97 <tr><td class="option-group" colspan="2">
98 <kbd><span class="option">-t</span>, <span class="option">--type <var>&lt;TYPE&gt;</var></span></kbd></td>
99 </tr>
100 <tr><td>&nbsp;</td><td>type of distribution to create</td></tr>
101 <tr><td class="option-group">
102 <kbd><span class="option">-S</span>, <span class="option">--subrepos</span></kbd></td>
103 <td>recurse into subrepositories</td></tr>
104 <tr><td class="option-group" colspan="2">
105 <kbd><span class="option">-I</span>, <span class="option">--include <var>&lt;PATTERN[+]&gt;</var></span></kbd></td>
106 </tr>
107 <tr><td>&nbsp;</td><td>include names matching the given patterns</td></tr>
108 <tr><td class="option-group" colspan="2">
109 <kbd><span class="option">-X</span>, <span class="option">--exclude <var>&lt;PATTERN[+]&gt;</var></span></kbd></td>
110 </tr>
111 <tr><td>&nbsp;</td><td>exclude names matching the given patterns</td></tr>
112 </tbody>
113 </table>
114 <p>[+] marked option can be specified multiple times</p>
115 </div>
116 </div>
117 </body>
118 </html>