Show More
@@ -1,2158 +1,2166 b'' | |||||
1 | The Mercurial system uses a set of configuration files to control |
|
1 | The Mercurial system uses a set of configuration files to control | |
2 | aspects of its behavior. |
|
2 | aspects of its behavior. | |
3 |
|
3 | |||
4 | Troubleshooting |
|
4 | Troubleshooting | |
5 | =============== |
|
5 | =============== | |
6 |
|
6 | |||
7 | If you're having problems with your configuration, |
|
7 | If you're having problems with your configuration, | |
8 | :hg:`config --debug` can help you understand what is introducing |
|
8 | :hg:`config --debug` can help you understand what is introducing | |
9 | a setting into your environment. |
|
9 | a setting into your environment. | |
10 |
|
10 | |||
11 | See :hg:`help config.syntax` and :hg:`help config.files` |
|
11 | See :hg:`help config.syntax` and :hg:`help config.files` | |
12 | for information about how and where to override things. |
|
12 | for information about how and where to override things. | |
13 |
|
13 | |||
14 | Structure |
|
14 | Structure | |
15 | ========= |
|
15 | ========= | |
16 |
|
16 | |||
17 | The configuration files use a simple ini-file format. A configuration |
|
17 | The configuration files use a simple ini-file format. A configuration | |
18 | file consists of sections, led by a ``[section]`` header and followed |
|
18 | file consists of sections, led by a ``[section]`` header and followed | |
19 | by ``name = value`` entries:: |
|
19 | by ``name = value`` entries:: | |
20 |
|
20 | |||
21 | [ui] |
|
21 | [ui] | |
22 | username = Firstname Lastname <firstname.lastname@example.net> |
|
22 | username = Firstname Lastname <firstname.lastname@example.net> | |
23 | verbose = True |
|
23 | verbose = True | |
24 |
|
24 | |||
25 | The above entries will be referred to as ``ui.username`` and |
|
25 | The above entries will be referred to as ``ui.username`` and | |
26 | ``ui.verbose``, respectively. See :hg:`help config.syntax`. |
|
26 | ``ui.verbose``, respectively. See :hg:`help config.syntax`. | |
27 |
|
27 | |||
28 | Files |
|
28 | Files | |
29 | ===== |
|
29 | ===== | |
30 |
|
30 | |||
31 | Mercurial reads configuration data from several files, if they exist. |
|
31 | Mercurial reads configuration data from several files, if they exist. | |
32 | These files do not exist by default and you will have to create the |
|
32 | These files do not exist by default and you will have to create the | |
33 | appropriate configuration files yourself: |
|
33 | appropriate configuration files yourself: | |
34 |
|
34 | |||
35 | Local configuration is put into the per-repository ``<repo>/.hg/hgrc`` file. |
|
35 | Local configuration is put into the per-repository ``<repo>/.hg/hgrc`` file. | |
36 |
|
36 | |||
37 | Global configuration like the username setting is typically put into: |
|
37 | Global configuration like the username setting is typically put into: | |
38 |
|
38 | |||
39 | .. container:: windows |
|
39 | .. container:: windows | |
40 |
|
40 | |||
41 | - ``%USERPROFILE%\mercurial.ini`` (on Windows) |
|
41 | - ``%USERPROFILE%\mercurial.ini`` (on Windows) | |
42 |
|
42 | |||
43 | .. container:: unix.plan9 |
|
43 | .. container:: unix.plan9 | |
44 |
|
44 | |||
45 | - ``$HOME/.hgrc`` (on Unix, Plan9) |
|
45 | - ``$HOME/.hgrc`` (on Unix, Plan9) | |
46 |
|
46 | |||
47 | The names of these files depend on the system on which Mercurial is |
|
47 | The names of these files depend on the system on which Mercurial is | |
48 | installed. ``*.rc`` files from a single directory are read in |
|
48 | installed. ``*.rc`` files from a single directory are read in | |
49 | alphabetical order, later ones overriding earlier ones. Where multiple |
|
49 | alphabetical order, later ones overriding earlier ones. Where multiple | |
50 | paths are given below, settings from earlier paths override later |
|
50 | paths are given below, settings from earlier paths override later | |
51 | ones. |
|
51 | ones. | |
52 |
|
52 | |||
53 | .. container:: verbose.unix |
|
53 | .. container:: verbose.unix | |
54 |
|
54 | |||
55 | On Unix, the following files are consulted: |
|
55 | On Unix, the following files are consulted: | |
56 |
|
56 | |||
57 | - ``<repo>/.hg/hgrc`` (per-repository) |
|
57 | - ``<repo>/.hg/hgrc`` (per-repository) | |
58 | - ``$HOME/.hgrc`` (per-user) |
|
58 | - ``$HOME/.hgrc`` (per-user) | |
59 | - ``<install-root>/etc/mercurial/hgrc`` (per-installation) |
|
59 | - ``<install-root>/etc/mercurial/hgrc`` (per-installation) | |
60 | - ``<install-root>/etc/mercurial/hgrc.d/*.rc`` (per-installation) |
|
60 | - ``<install-root>/etc/mercurial/hgrc.d/*.rc`` (per-installation) | |
61 | - ``/etc/mercurial/hgrc`` (per-system) |
|
61 | - ``/etc/mercurial/hgrc`` (per-system) | |
62 | - ``/etc/mercurial/hgrc.d/*.rc`` (per-system) |
|
62 | - ``/etc/mercurial/hgrc.d/*.rc`` (per-system) | |
63 | - ``<internal>/default.d/*.rc`` (defaults) |
|
63 | - ``<internal>/default.d/*.rc`` (defaults) | |
64 |
|
64 | |||
65 | .. container:: verbose.windows |
|
65 | .. container:: verbose.windows | |
66 |
|
66 | |||
67 | On Windows, the following files are consulted: |
|
67 | On Windows, the following files are consulted: | |
68 |
|
68 | |||
69 | - ``<repo>/.hg/hgrc`` (per-repository) |
|
69 | - ``<repo>/.hg/hgrc`` (per-repository) | |
70 | - ``%USERPROFILE%\.hgrc`` (per-user) |
|
70 | - ``%USERPROFILE%\.hgrc`` (per-user) | |
71 | - ``%USERPROFILE%\Mercurial.ini`` (per-user) |
|
71 | - ``%USERPROFILE%\Mercurial.ini`` (per-user) | |
72 | - ``%HOME%\.hgrc`` (per-user) |
|
72 | - ``%HOME%\.hgrc`` (per-user) | |
73 | - ``%HOME%\Mercurial.ini`` (per-user) |
|
73 | - ``%HOME%\Mercurial.ini`` (per-user) | |
74 | - ``HKEY_LOCAL_MACHINE\SOFTWARE\Mercurial`` (per-installation) |
|
74 | - ``HKEY_LOCAL_MACHINE\SOFTWARE\Mercurial`` (per-installation) | |
75 | - ``<install-dir>\hgrc.d\*.rc`` (per-installation) |
|
75 | - ``<install-dir>\hgrc.d\*.rc`` (per-installation) | |
76 | - ``<install-dir>\Mercurial.ini`` (per-installation) |
|
76 | - ``<install-dir>\Mercurial.ini`` (per-installation) | |
77 | - ``<internal>/default.d/*.rc`` (defaults) |
|
77 | - ``<internal>/default.d/*.rc`` (defaults) | |
78 |
|
78 | |||
79 | .. note:: |
|
79 | .. note:: | |
80 |
|
80 | |||
81 | The registry key ``HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Mercurial`` |
|
81 | The registry key ``HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Mercurial`` | |
82 | is used when running 32-bit Python on 64-bit Windows. |
|
82 | is used when running 32-bit Python on 64-bit Windows. | |
83 |
|
83 | |||
84 | .. container:: windows |
|
84 | .. container:: windows | |
85 |
|
85 | |||
86 | On Windows 9x, ``%HOME%`` is replaced by ``%APPDATA%``. |
|
86 | On Windows 9x, ``%HOME%`` is replaced by ``%APPDATA%``. | |
87 |
|
87 | |||
88 | .. container:: verbose.plan9 |
|
88 | .. container:: verbose.plan9 | |
89 |
|
89 | |||
90 | On Plan9, the following files are consulted: |
|
90 | On Plan9, the following files are consulted: | |
91 |
|
91 | |||
92 | - ``<repo>/.hg/hgrc`` (per-repository) |
|
92 | - ``<repo>/.hg/hgrc`` (per-repository) | |
93 | - ``$home/lib/hgrc`` (per-user) |
|
93 | - ``$home/lib/hgrc`` (per-user) | |
94 | - ``<install-root>/lib/mercurial/hgrc`` (per-installation) |
|
94 | - ``<install-root>/lib/mercurial/hgrc`` (per-installation) | |
95 | - ``<install-root>/lib/mercurial/hgrc.d/*.rc`` (per-installation) |
|
95 | - ``<install-root>/lib/mercurial/hgrc.d/*.rc`` (per-installation) | |
96 | - ``/lib/mercurial/hgrc`` (per-system) |
|
96 | - ``/lib/mercurial/hgrc`` (per-system) | |
97 | - ``/lib/mercurial/hgrc.d/*.rc`` (per-system) |
|
97 | - ``/lib/mercurial/hgrc.d/*.rc`` (per-system) | |
98 | - ``<internal>/default.d/*.rc`` (defaults) |
|
98 | - ``<internal>/default.d/*.rc`` (defaults) | |
99 |
|
99 | |||
100 | Per-repository configuration options only apply in a |
|
100 | Per-repository configuration options only apply in a | |
101 | particular repository. This file is not version-controlled, and |
|
101 | particular repository. This file is not version-controlled, and | |
102 | will not get transferred during a "clone" operation. Options in |
|
102 | will not get transferred during a "clone" operation. Options in | |
103 | this file override options in all other configuration files. |
|
103 | this file override options in all other configuration files. | |
104 |
|
104 | |||
105 | .. container:: unix.plan9 |
|
105 | .. container:: unix.plan9 | |
106 |
|
106 | |||
107 | On Plan 9 and Unix, most of this file will be ignored if it doesn't |
|
107 | On Plan 9 and Unix, most of this file will be ignored if it doesn't | |
108 | belong to a trusted user or to a trusted group. See |
|
108 | belong to a trusted user or to a trusted group. See | |
109 | :hg:`help config.trusted` for more details. |
|
109 | :hg:`help config.trusted` for more details. | |
110 |
|
110 | |||
111 | Per-user configuration file(s) are for the user running Mercurial. Options |
|
111 | Per-user configuration file(s) are for the user running Mercurial. Options | |
112 | in these files apply to all Mercurial commands executed by this user in any |
|
112 | in these files apply to all Mercurial commands executed by this user in any | |
113 | directory. Options in these files override per-system and per-installation |
|
113 | directory. Options in these files override per-system and per-installation | |
114 | options. |
|
114 | options. | |
115 |
|
115 | |||
116 | Per-installation configuration files are searched for in the |
|
116 | Per-installation configuration files are searched for in the | |
117 | directory where Mercurial is installed. ``<install-root>`` is the |
|
117 | directory where Mercurial is installed. ``<install-root>`` is the | |
118 | parent directory of the **hg** executable (or symlink) being run. |
|
118 | parent directory of the **hg** executable (or symlink) being run. | |
119 |
|
119 | |||
120 | .. container:: unix.plan9 |
|
120 | .. container:: unix.plan9 | |
121 |
|
121 | |||
122 | For example, if installed in ``/shared/tools/bin/hg``, Mercurial |
|
122 | For example, if installed in ``/shared/tools/bin/hg``, Mercurial | |
123 | will look in ``/shared/tools/etc/mercurial/hgrc``. Options in these |
|
123 | will look in ``/shared/tools/etc/mercurial/hgrc``. Options in these | |
124 | files apply to all Mercurial commands executed by any user in any |
|
124 | files apply to all Mercurial commands executed by any user in any | |
125 | directory. |
|
125 | directory. | |
126 |
|
126 | |||
127 | Per-installation configuration files are for the system on |
|
127 | Per-installation configuration files are for the system on | |
128 | which Mercurial is running. Options in these files apply to all |
|
128 | which Mercurial is running. Options in these files apply to all | |
129 | Mercurial commands executed by any user in any directory. Registry |
|
129 | Mercurial commands executed by any user in any directory. Registry | |
130 | keys contain PATH-like strings, every part of which must reference |
|
130 | keys contain PATH-like strings, every part of which must reference | |
131 | a ``Mercurial.ini`` file or be a directory where ``*.rc`` files will |
|
131 | a ``Mercurial.ini`` file or be a directory where ``*.rc`` files will | |
132 | be read. Mercurial checks each of these locations in the specified |
|
132 | be read. Mercurial checks each of these locations in the specified | |
133 | order until one or more configuration files are detected. |
|
133 | order until one or more configuration files are detected. | |
134 |
|
134 | |||
135 | Per-system configuration files are for the system on which Mercurial |
|
135 | Per-system configuration files are for the system on which Mercurial | |
136 | is running. Options in these files apply to all Mercurial commands |
|
136 | is running. Options in these files apply to all Mercurial commands | |
137 | executed by any user in any directory. Options in these files |
|
137 | executed by any user in any directory. Options in these files | |
138 | override per-installation options. |
|
138 | override per-installation options. | |
139 |
|
139 | |||
140 | Mercurial comes with some default configuration. The default configuration |
|
140 | Mercurial comes with some default configuration. The default configuration | |
141 | files are installed with Mercurial and will be overwritten on upgrades. Default |
|
141 | files are installed with Mercurial and will be overwritten on upgrades. Default | |
142 | configuration files should never be edited by users or administrators but can |
|
142 | configuration files should never be edited by users or administrators but can | |
143 | be overridden in other configuration files. So far the directory only contains |
|
143 | be overridden in other configuration files. So far the directory only contains | |
144 | merge tool configuration but packagers can also put other default configuration |
|
144 | merge tool configuration but packagers can also put other default configuration | |
145 | there. |
|
145 | there. | |
146 |
|
146 | |||
147 | Syntax |
|
147 | Syntax | |
148 | ====== |
|
148 | ====== | |
149 |
|
149 | |||
150 | A configuration file consists of sections, led by a ``[section]`` header |
|
150 | A configuration file consists of sections, led by a ``[section]`` header | |
151 | and followed by ``name = value`` entries (sometimes called |
|
151 | and followed by ``name = value`` entries (sometimes called | |
152 | ``configuration keys``):: |
|
152 | ``configuration keys``):: | |
153 |
|
153 | |||
154 | [spam] |
|
154 | [spam] | |
155 | eggs=ham |
|
155 | eggs=ham | |
156 | green= |
|
156 | green= | |
157 | eggs |
|
157 | eggs | |
158 |
|
158 | |||
159 | Each line contains one entry. If the lines that follow are indented, |
|
159 | Each line contains one entry. If the lines that follow are indented, | |
160 | they are treated as continuations of that entry. Leading whitespace is |
|
160 | they are treated as continuations of that entry. Leading whitespace is | |
161 | removed from values. Empty lines are skipped. Lines beginning with |
|
161 | removed from values. Empty lines are skipped. Lines beginning with | |
162 | ``#`` or ``;`` are ignored and may be used to provide comments. |
|
162 | ``#`` or ``;`` are ignored and may be used to provide comments. | |
163 |
|
163 | |||
164 | Configuration keys can be set multiple times, in which case Mercurial |
|
164 | Configuration keys can be set multiple times, in which case Mercurial | |
165 | will use the value that was configured last. As an example:: |
|
165 | will use the value that was configured last. As an example:: | |
166 |
|
166 | |||
167 | [spam] |
|
167 | [spam] | |
168 | eggs=large |
|
168 | eggs=large | |
169 | ham=serrano |
|
169 | ham=serrano | |
170 | eggs=small |
|
170 | eggs=small | |
171 |
|
171 | |||
172 | This would set the configuration key named ``eggs`` to ``small``. |
|
172 | This would set the configuration key named ``eggs`` to ``small``. | |
173 |
|
173 | |||
174 | It is also possible to define a section multiple times. A section can |
|
174 | It is also possible to define a section multiple times. A section can | |
175 | be redefined on the same and/or on different configuration files. For |
|
175 | be redefined on the same and/or on different configuration files. For | |
176 | example:: |
|
176 | example:: | |
177 |
|
177 | |||
178 | [foo] |
|
178 | [foo] | |
179 | eggs=large |
|
179 | eggs=large | |
180 | ham=serrano |
|
180 | ham=serrano | |
181 | eggs=small |
|
181 | eggs=small | |
182 |
|
182 | |||
183 | [bar] |
|
183 | [bar] | |
184 | eggs=ham |
|
184 | eggs=ham | |
185 | green= |
|
185 | green= | |
186 | eggs |
|
186 | eggs | |
187 |
|
187 | |||
188 | [foo] |
|
188 | [foo] | |
189 | ham=prosciutto |
|
189 | ham=prosciutto | |
190 | eggs=medium |
|
190 | eggs=medium | |
191 | bread=toasted |
|
191 | bread=toasted | |
192 |
|
192 | |||
193 | This would set the ``eggs``, ``ham``, and ``bread`` configuration keys |
|
193 | This would set the ``eggs``, ``ham``, and ``bread`` configuration keys | |
194 | of the ``foo`` section to ``medium``, ``prosciutto``, and ``toasted``, |
|
194 | of the ``foo`` section to ``medium``, ``prosciutto``, and ``toasted``, | |
195 | respectively. As you can see there only thing that matters is the last |
|
195 | respectively. As you can see there only thing that matters is the last | |
196 | value that was set for each of the configuration keys. |
|
196 | value that was set for each of the configuration keys. | |
197 |
|
197 | |||
198 | If a configuration key is set multiple times in different |
|
198 | If a configuration key is set multiple times in different | |
199 | configuration files the final value will depend on the order in which |
|
199 | configuration files the final value will depend on the order in which | |
200 | the different configuration files are read, with settings from earlier |
|
200 | the different configuration files are read, with settings from earlier | |
201 | paths overriding later ones as described on the ``Files`` section |
|
201 | paths overriding later ones as described on the ``Files`` section | |
202 | above. |
|
202 | above. | |
203 |
|
203 | |||
204 | A line of the form ``%include file`` will include ``file`` into the |
|
204 | A line of the form ``%include file`` will include ``file`` into the | |
205 | current configuration file. The inclusion is recursive, which means |
|
205 | current configuration file. The inclusion is recursive, which means | |
206 | that included files can include other files. Filenames are relative to |
|
206 | that included files can include other files. Filenames are relative to | |
207 | the configuration file in which the ``%include`` directive is found. |
|
207 | the configuration file in which the ``%include`` directive is found. | |
208 | Environment variables and ``~user`` constructs are expanded in |
|
208 | Environment variables and ``~user`` constructs are expanded in | |
209 | ``file``. This lets you do something like:: |
|
209 | ``file``. This lets you do something like:: | |
210 |
|
210 | |||
211 | %include ~/.hgrc.d/$HOST.rc |
|
211 | %include ~/.hgrc.d/$HOST.rc | |
212 |
|
212 | |||
213 | to include a different configuration file on each computer you use. |
|
213 | to include a different configuration file on each computer you use. | |
214 |
|
214 | |||
215 | A line with ``%unset name`` will remove ``name`` from the current |
|
215 | A line with ``%unset name`` will remove ``name`` from the current | |
216 | section, if it has been set previously. |
|
216 | section, if it has been set previously. | |
217 |
|
217 | |||
218 | The values are either free-form text strings, lists of text strings, |
|
218 | The values are either free-form text strings, lists of text strings, | |
219 | or Boolean values. Boolean values can be set to true using any of "1", |
|
219 | or Boolean values. Boolean values can be set to true using any of "1", | |
220 | "yes", "true", or "on" and to false using "0", "no", "false", or "off" |
|
220 | "yes", "true", or "on" and to false using "0", "no", "false", or "off" | |
221 | (all case insensitive). |
|
221 | (all case insensitive). | |
222 |
|
222 | |||
223 | List values are separated by whitespace or comma, except when values are |
|
223 | List values are separated by whitespace or comma, except when values are | |
224 | placed in double quotation marks:: |
|
224 | placed in double quotation marks:: | |
225 |
|
225 | |||
226 | allow_read = "John Doe, PhD", brian, betty |
|
226 | allow_read = "John Doe, PhD", brian, betty | |
227 |
|
227 | |||
228 | Quotation marks can be escaped by prefixing them with a backslash. Only |
|
228 | Quotation marks can be escaped by prefixing them with a backslash. Only | |
229 | quotation marks at the beginning of a word is counted as a quotation |
|
229 | quotation marks at the beginning of a word is counted as a quotation | |
230 | (e.g., ``foo"bar baz`` is the list of ``foo"bar`` and ``baz``). |
|
230 | (e.g., ``foo"bar baz`` is the list of ``foo"bar`` and ``baz``). | |
231 |
|
231 | |||
232 | Sections |
|
232 | Sections | |
233 | ======== |
|
233 | ======== | |
234 |
|
234 | |||
235 | This section describes the different sections that may appear in a |
|
235 | This section describes the different sections that may appear in a | |
236 | Mercurial configuration file, the purpose of each section, its possible |
|
236 | Mercurial configuration file, the purpose of each section, its possible | |
237 | keys, and their possible values. |
|
237 | keys, and their possible values. | |
238 |
|
238 | |||
239 | ``alias`` |
|
239 | ``alias`` | |
240 | --------- |
|
240 | --------- | |
241 |
|
241 | |||
242 | Defines command aliases. |
|
242 | Defines command aliases. | |
243 |
|
243 | |||
244 | Aliases allow you to define your own commands in terms of other |
|
244 | Aliases allow you to define your own commands in terms of other | |
245 | commands (or aliases), optionally including arguments. Positional |
|
245 | commands (or aliases), optionally including arguments. Positional | |
246 | arguments in the form of ``$1``, ``$2``, etc. in the alias definition |
|
246 | arguments in the form of ``$1``, ``$2``, etc. in the alias definition | |
247 | are expanded by Mercurial before execution. Positional arguments not |
|
247 | are expanded by Mercurial before execution. Positional arguments not | |
248 | already used by ``$N`` in the definition are put at the end of the |
|
248 | already used by ``$N`` in the definition are put at the end of the | |
249 | command to be executed. |
|
249 | command to be executed. | |
250 |
|
250 | |||
251 | Alias definitions consist of lines of the form:: |
|
251 | Alias definitions consist of lines of the form:: | |
252 |
|
252 | |||
253 | <alias> = <command> [<argument>]... |
|
253 | <alias> = <command> [<argument>]... | |
254 |
|
254 | |||
255 | For example, this definition:: |
|
255 | For example, this definition:: | |
256 |
|
256 | |||
257 | latest = log --limit 5 |
|
257 | latest = log --limit 5 | |
258 |
|
258 | |||
259 | creates a new command ``latest`` that shows only the five most recent |
|
259 | creates a new command ``latest`` that shows only the five most recent | |
260 | changesets. You can define subsequent aliases using earlier ones:: |
|
260 | changesets. You can define subsequent aliases using earlier ones:: | |
261 |
|
261 | |||
262 | stable5 = latest -b stable |
|
262 | stable5 = latest -b stable | |
263 |
|
263 | |||
264 | .. note:: |
|
264 | .. note:: | |
265 |
|
265 | |||
266 | It is possible to create aliases with the same names as |
|
266 | It is possible to create aliases with the same names as | |
267 | existing commands, which will then override the original |
|
267 | existing commands, which will then override the original | |
268 | definitions. This is almost always a bad idea! |
|
268 | definitions. This is almost always a bad idea! | |
269 |
|
269 | |||
270 | An alias can start with an exclamation point (``!``) to make it a |
|
270 | An alias can start with an exclamation point (``!``) to make it a | |
271 | shell alias. A shell alias is executed with the shell and will let you |
|
271 | shell alias. A shell alias is executed with the shell and will let you | |
272 | run arbitrary commands. As an example, :: |
|
272 | run arbitrary commands. As an example, :: | |
273 |
|
273 | |||
274 | echo = !echo $@ |
|
274 | echo = !echo $@ | |
275 |
|
275 | |||
276 | will let you do ``hg echo foo`` to have ``foo`` printed in your |
|
276 | will let you do ``hg echo foo`` to have ``foo`` printed in your | |
277 | terminal. A better example might be:: |
|
277 | terminal. A better example might be:: | |
278 |
|
278 | |||
279 | purge = !$HG status --no-status --unknown -0 re: | xargs -0 rm |
|
279 | purge = !$HG status --no-status --unknown -0 re: | xargs -0 rm | |
280 |
|
280 | |||
281 | which will make ``hg purge`` delete all unknown files in the |
|
281 | which will make ``hg purge`` delete all unknown files in the | |
282 | repository in the same manner as the purge extension. |
|
282 | repository in the same manner as the purge extension. | |
283 |
|
283 | |||
284 | Positional arguments like ``$1``, ``$2``, etc. in the alias definition |
|
284 | Positional arguments like ``$1``, ``$2``, etc. in the alias definition | |
285 | expand to the command arguments. Unmatched arguments are |
|
285 | expand to the command arguments. Unmatched arguments are | |
286 | removed. ``$0`` expands to the alias name and ``$@`` expands to all |
|
286 | removed. ``$0`` expands to the alias name and ``$@`` expands to all | |
287 | arguments separated by a space. ``"$@"`` (with quotes) expands to all |
|
287 | arguments separated by a space. ``"$@"`` (with quotes) expands to all | |
288 | arguments quoted individually and separated by a space. These expansions |
|
288 | arguments quoted individually and separated by a space. These expansions | |
289 | happen before the command is passed to the shell. |
|
289 | happen before the command is passed to the shell. | |
290 |
|
290 | |||
291 | Shell aliases are executed in an environment where ``$HG`` expands to |
|
291 | Shell aliases are executed in an environment where ``$HG`` expands to | |
292 | the path of the Mercurial that was used to execute the alias. This is |
|
292 | the path of the Mercurial that was used to execute the alias. This is | |
293 | useful when you want to call further Mercurial commands in a shell |
|
293 | useful when you want to call further Mercurial commands in a shell | |
294 | alias, as was done above for the purge alias. In addition, |
|
294 | alias, as was done above for the purge alias. In addition, | |
295 | ``$HG_ARGS`` expands to the arguments given to Mercurial. In the ``hg |
|
295 | ``$HG_ARGS`` expands to the arguments given to Mercurial. In the ``hg | |
296 | echo foo`` call above, ``$HG_ARGS`` would expand to ``echo foo``. |
|
296 | echo foo`` call above, ``$HG_ARGS`` would expand to ``echo foo``. | |
297 |
|
297 | |||
298 | .. note:: |
|
298 | .. note:: | |
299 |
|
299 | |||
300 | Some global configuration options such as ``-R`` are |
|
300 | Some global configuration options such as ``-R`` are | |
301 | processed before shell aliases and will thus not be passed to |
|
301 | processed before shell aliases and will thus not be passed to | |
302 | aliases. |
|
302 | aliases. | |
303 |
|
303 | |||
304 |
|
304 | |||
305 | ``annotate`` |
|
305 | ``annotate`` | |
306 | ------------ |
|
306 | ------------ | |
307 |
|
307 | |||
308 | Settings used when displaying file annotations. All values are |
|
308 | Settings used when displaying file annotations. All values are | |
309 | Booleans and default to False. See :hg:`help config.diff` for |
|
309 | Booleans and default to False. See :hg:`help config.diff` for | |
310 | related options for the diff command. |
|
310 | related options for the diff command. | |
311 |
|
311 | |||
312 | ``ignorews`` |
|
312 | ``ignorews`` | |
313 | Ignore white space when comparing lines. |
|
313 | Ignore white space when comparing lines. | |
314 |
|
314 | |||
315 | ``ignorewsamount`` |
|
315 | ``ignorewsamount`` | |
316 | Ignore changes in the amount of white space. |
|
316 | Ignore changes in the amount of white space. | |
317 |
|
317 | |||
318 | ``ignoreblanklines`` |
|
318 | ``ignoreblanklines`` | |
319 | Ignore changes whose lines are all blank. |
|
319 | Ignore changes whose lines are all blank. | |
320 |
|
320 | |||
321 |
|
321 | |||
322 | ``auth`` |
|
322 | ``auth`` | |
323 | -------- |
|
323 | -------- | |
324 |
|
324 | |||
325 | Authentication credentials for HTTP authentication. This section |
|
325 | Authentication credentials for HTTP authentication. This section | |
326 | allows you to store usernames and passwords for use when logging |
|
326 | allows you to store usernames and passwords for use when logging | |
327 | *into* HTTP servers. See :hg:`help config.web` if |
|
327 | *into* HTTP servers. See :hg:`help config.web` if | |
328 | you want to configure *who* can login to your HTTP server. |
|
328 | you want to configure *who* can login to your HTTP server. | |
329 |
|
329 | |||
330 | Each line has the following format:: |
|
330 | Each line has the following format:: | |
331 |
|
331 | |||
332 | <name>.<argument> = <value> |
|
332 | <name>.<argument> = <value> | |
333 |
|
333 | |||
334 | where ``<name>`` is used to group arguments into authentication |
|
334 | where ``<name>`` is used to group arguments into authentication | |
335 | entries. Example:: |
|
335 | entries. Example:: | |
336 |
|
336 | |||
337 | foo.prefix = hg.intevation.de/mercurial |
|
337 | foo.prefix = hg.intevation.de/mercurial | |
338 | foo.username = foo |
|
338 | foo.username = foo | |
339 | foo.password = bar |
|
339 | foo.password = bar | |
340 | foo.schemes = http https |
|
340 | foo.schemes = http https | |
341 |
|
341 | |||
342 | bar.prefix = secure.example.org |
|
342 | bar.prefix = secure.example.org | |
343 | bar.key = path/to/file.key |
|
343 | bar.key = path/to/file.key | |
344 | bar.cert = path/to/file.cert |
|
344 | bar.cert = path/to/file.cert | |
345 | bar.schemes = https |
|
345 | bar.schemes = https | |
346 |
|
346 | |||
347 | Supported arguments: |
|
347 | Supported arguments: | |
348 |
|
348 | |||
349 | ``prefix`` |
|
349 | ``prefix`` | |
350 | Either ``*`` or a URI prefix with or without the scheme part. |
|
350 | Either ``*`` or a URI prefix with or without the scheme part. | |
351 | The authentication entry with the longest matching prefix is used |
|
351 | The authentication entry with the longest matching prefix is used | |
352 | (where ``*`` matches everything and counts as a match of length |
|
352 | (where ``*`` matches everything and counts as a match of length | |
353 | 1). If the prefix doesn't include a scheme, the match is performed |
|
353 | 1). If the prefix doesn't include a scheme, the match is performed | |
354 | against the URI with its scheme stripped as well, and the schemes |
|
354 | against the URI with its scheme stripped as well, and the schemes | |
355 | argument, q.v., is then subsequently consulted. |
|
355 | argument, q.v., is then subsequently consulted. | |
356 |
|
356 | |||
357 | ``username`` |
|
357 | ``username`` | |
358 | Optional. Username to authenticate with. If not given, and the |
|
358 | Optional. Username to authenticate with. If not given, and the | |
359 | remote site requires basic or digest authentication, the user will |
|
359 | remote site requires basic or digest authentication, the user will | |
360 | be prompted for it. Environment variables are expanded in the |
|
360 | be prompted for it. Environment variables are expanded in the | |
361 | username letting you do ``foo.username = $USER``. If the URI |
|
361 | username letting you do ``foo.username = $USER``. If the URI | |
362 | includes a username, only ``[auth]`` entries with a matching |
|
362 | includes a username, only ``[auth]`` entries with a matching | |
363 | username or without a username will be considered. |
|
363 | username or without a username will be considered. | |
364 |
|
364 | |||
365 | ``password`` |
|
365 | ``password`` | |
366 | Optional. Password to authenticate with. If not given, and the |
|
366 | Optional. Password to authenticate with. If not given, and the | |
367 | remote site requires basic or digest authentication, the user |
|
367 | remote site requires basic or digest authentication, the user | |
368 | will be prompted for it. |
|
368 | will be prompted for it. | |
369 |
|
369 | |||
370 | ``key`` |
|
370 | ``key`` | |
371 | Optional. PEM encoded client certificate key file. Environment |
|
371 | Optional. PEM encoded client certificate key file. Environment | |
372 | variables are expanded in the filename. |
|
372 | variables are expanded in the filename. | |
373 |
|
373 | |||
374 | ``cert`` |
|
374 | ``cert`` | |
375 | Optional. PEM encoded client certificate chain file. Environment |
|
375 | Optional. PEM encoded client certificate chain file. Environment | |
376 | variables are expanded in the filename. |
|
376 | variables are expanded in the filename. | |
377 |
|
377 | |||
378 | ``schemes`` |
|
378 | ``schemes`` | |
379 | Optional. Space separated list of URI schemes to use this |
|
379 | Optional. Space separated list of URI schemes to use this | |
380 | authentication entry with. Only used if the prefix doesn't include |
|
380 | authentication entry with. Only used if the prefix doesn't include | |
381 | a scheme. Supported schemes are http and https. They will match |
|
381 | a scheme. Supported schemes are http and https. They will match | |
382 | static-http and static-https respectively, as well. |
|
382 | static-http and static-https respectively, as well. | |
383 | (default: https) |
|
383 | (default: https) | |
384 |
|
384 | |||
385 | If no suitable authentication entry is found, the user is prompted |
|
385 | If no suitable authentication entry is found, the user is prompted | |
386 | for credentials as usual if required by the remote. |
|
386 | for credentials as usual if required by the remote. | |
387 |
|
387 | |||
388 |
|
388 | |||
389 | ``committemplate`` |
|
389 | ``committemplate`` | |
390 | ------------------ |
|
390 | ------------------ | |
391 |
|
391 | |||
392 | ``changeset`` |
|
392 | ``changeset`` | |
393 | String: configuration in this section is used as the template to |
|
393 | String: configuration in this section is used as the template to | |
394 | customize the text shown in the editor when committing. |
|
394 | customize the text shown in the editor when committing. | |
395 |
|
395 | |||
396 | In addition to pre-defined template keywords, commit log specific one |
|
396 | In addition to pre-defined template keywords, commit log specific one | |
397 | below can be used for customization: |
|
397 | below can be used for customization: | |
398 |
|
398 | |||
399 | ``extramsg`` |
|
399 | ``extramsg`` | |
400 | String: Extra message (typically 'Leave message empty to abort |
|
400 | String: Extra message (typically 'Leave message empty to abort | |
401 | commit.'). This may be changed by some commands or extensions. |
|
401 | commit.'). This may be changed by some commands or extensions. | |
402 |
|
402 | |||
403 | For example, the template configuration below shows as same text as |
|
403 | For example, the template configuration below shows as same text as | |
404 | one shown by default:: |
|
404 | one shown by default:: | |
405 |
|
405 | |||
406 | [committemplate] |
|
406 | [committemplate] | |
407 | changeset = {desc}\n\n |
|
407 | changeset = {desc}\n\n | |
408 | HG: Enter commit message. Lines beginning with 'HG:' are removed. |
|
408 | HG: Enter commit message. Lines beginning with 'HG:' are removed. | |
409 | HG: {extramsg} |
|
409 | HG: {extramsg} | |
410 | HG: -- |
|
410 | HG: -- | |
411 | HG: user: {author}\n{ifeq(p2rev, "-1", "", |
|
411 | HG: user: {author}\n{ifeq(p2rev, "-1", "", | |
412 | "HG: branch merge\n") |
|
412 | "HG: branch merge\n") | |
413 | }HG: branch '{branch}'\n{if(activebookmark, |
|
413 | }HG: branch '{branch}'\n{if(activebookmark, | |
414 | "HG: bookmark '{activebookmark}'\n") }{subrepos % |
|
414 | "HG: bookmark '{activebookmark}'\n") }{subrepos % | |
415 | "HG: subrepo {subrepo}\n" }{file_adds % |
|
415 | "HG: subrepo {subrepo}\n" }{file_adds % | |
416 | "HG: added {file}\n" }{file_mods % |
|
416 | "HG: added {file}\n" }{file_mods % | |
417 | "HG: changed {file}\n" }{file_dels % |
|
417 | "HG: changed {file}\n" }{file_dels % | |
418 | "HG: removed {file}\n" }{if(files, "", |
|
418 | "HG: removed {file}\n" }{if(files, "", | |
419 | "HG: no files changed\n")} |
|
419 | "HG: no files changed\n")} | |
420 |
|
420 | |||
421 | .. note:: |
|
421 | .. note:: | |
422 |
|
422 | |||
423 | For some problematic encodings (see :hg:`help win32mbcs` for |
|
423 | For some problematic encodings (see :hg:`help win32mbcs` for | |
424 | detail), this customization should be configured carefully, to |
|
424 | detail), this customization should be configured carefully, to | |
425 | avoid showing broken characters. |
|
425 | avoid showing broken characters. | |
426 |
|
426 | |||
427 | For example, if a multibyte character ending with backslash (0x5c) is |
|
427 | For example, if a multibyte character ending with backslash (0x5c) is | |
428 | followed by the ASCII character 'n' in the customized template, |
|
428 | followed by the ASCII character 'n' in the customized template, | |
429 | the sequence of backslash and 'n' is treated as line-feed unexpectedly |
|
429 | the sequence of backslash and 'n' is treated as line-feed unexpectedly | |
430 | (and the multibyte character is broken, too). |
|
430 | (and the multibyte character is broken, too). | |
431 |
|
431 | |||
432 | Customized template is used for commands below (``--edit`` may be |
|
432 | Customized template is used for commands below (``--edit`` may be | |
433 | required): |
|
433 | required): | |
434 |
|
434 | |||
435 | - :hg:`backout` |
|
435 | - :hg:`backout` | |
436 | - :hg:`commit` |
|
436 | - :hg:`commit` | |
437 | - :hg:`fetch` (for merge commit only) |
|
437 | - :hg:`fetch` (for merge commit only) | |
438 | - :hg:`graft` |
|
438 | - :hg:`graft` | |
439 | - :hg:`histedit` |
|
439 | - :hg:`histedit` | |
440 | - :hg:`import` |
|
440 | - :hg:`import` | |
441 | - :hg:`qfold`, :hg:`qnew` and :hg:`qrefresh` |
|
441 | - :hg:`qfold`, :hg:`qnew` and :hg:`qrefresh` | |
442 | - :hg:`rebase` |
|
442 | - :hg:`rebase` | |
443 | - :hg:`shelve` |
|
443 | - :hg:`shelve` | |
444 | - :hg:`sign` |
|
444 | - :hg:`sign` | |
445 | - :hg:`tag` |
|
445 | - :hg:`tag` | |
446 | - :hg:`transplant` |
|
446 | - :hg:`transplant` | |
447 |
|
447 | |||
448 | Configuring items below instead of ``changeset`` allows showing |
|
448 | Configuring items below instead of ``changeset`` allows showing | |
449 | customized message only for specific actions, or showing different |
|
449 | customized message only for specific actions, or showing different | |
450 | messages for each action. |
|
450 | messages for each action. | |
451 |
|
451 | |||
452 | - ``changeset.backout`` for :hg:`backout` |
|
452 | - ``changeset.backout`` for :hg:`backout` | |
453 | - ``changeset.commit.amend.merge`` for :hg:`commit --amend` on merges |
|
453 | - ``changeset.commit.amend.merge`` for :hg:`commit --amend` on merges | |
454 | - ``changeset.commit.amend.normal`` for :hg:`commit --amend` on other |
|
454 | - ``changeset.commit.amend.normal`` for :hg:`commit --amend` on other | |
455 | - ``changeset.commit.normal.merge`` for :hg:`commit` on merges |
|
455 | - ``changeset.commit.normal.merge`` for :hg:`commit` on merges | |
456 | - ``changeset.commit.normal.normal`` for :hg:`commit` on other |
|
456 | - ``changeset.commit.normal.normal`` for :hg:`commit` on other | |
457 | - ``changeset.fetch`` for :hg:`fetch` (impling merge commit) |
|
457 | - ``changeset.fetch`` for :hg:`fetch` (impling merge commit) | |
458 | - ``changeset.gpg.sign`` for :hg:`sign` |
|
458 | - ``changeset.gpg.sign`` for :hg:`sign` | |
459 | - ``changeset.graft`` for :hg:`graft` |
|
459 | - ``changeset.graft`` for :hg:`graft` | |
460 | - ``changeset.histedit.edit`` for ``edit`` of :hg:`histedit` |
|
460 | - ``changeset.histedit.edit`` for ``edit`` of :hg:`histedit` | |
461 | - ``changeset.histedit.fold`` for ``fold`` of :hg:`histedit` |
|
461 | - ``changeset.histedit.fold`` for ``fold`` of :hg:`histedit` | |
462 | - ``changeset.histedit.mess`` for ``mess`` of :hg:`histedit` |
|
462 | - ``changeset.histedit.mess`` for ``mess`` of :hg:`histedit` | |
463 | - ``changeset.histedit.pick`` for ``pick`` of :hg:`histedit` |
|
463 | - ``changeset.histedit.pick`` for ``pick`` of :hg:`histedit` | |
464 | - ``changeset.import.bypass`` for :hg:`import --bypass` |
|
464 | - ``changeset.import.bypass`` for :hg:`import --bypass` | |
465 | - ``changeset.import.normal.merge`` for :hg:`import` on merges |
|
465 | - ``changeset.import.normal.merge`` for :hg:`import` on merges | |
466 | - ``changeset.import.normal.normal`` for :hg:`import` on other |
|
466 | - ``changeset.import.normal.normal`` for :hg:`import` on other | |
467 | - ``changeset.mq.qnew`` for :hg:`qnew` |
|
467 | - ``changeset.mq.qnew`` for :hg:`qnew` | |
468 | - ``changeset.mq.qfold`` for :hg:`qfold` |
|
468 | - ``changeset.mq.qfold`` for :hg:`qfold` | |
469 | - ``changeset.mq.qrefresh`` for :hg:`qrefresh` |
|
469 | - ``changeset.mq.qrefresh`` for :hg:`qrefresh` | |
470 | - ``changeset.rebase.collapse`` for :hg:`rebase --collapse` |
|
470 | - ``changeset.rebase.collapse`` for :hg:`rebase --collapse` | |
471 | - ``changeset.rebase.merge`` for :hg:`rebase` on merges |
|
471 | - ``changeset.rebase.merge`` for :hg:`rebase` on merges | |
472 | - ``changeset.rebase.normal`` for :hg:`rebase` on other |
|
472 | - ``changeset.rebase.normal`` for :hg:`rebase` on other | |
473 | - ``changeset.shelve.shelve`` for :hg:`shelve` |
|
473 | - ``changeset.shelve.shelve`` for :hg:`shelve` | |
474 | - ``changeset.tag.add`` for :hg:`tag` without ``--remove`` |
|
474 | - ``changeset.tag.add`` for :hg:`tag` without ``--remove`` | |
475 | - ``changeset.tag.remove`` for :hg:`tag --remove` |
|
475 | - ``changeset.tag.remove`` for :hg:`tag --remove` | |
476 | - ``changeset.transplant.merge`` for :hg:`transplant` on merges |
|
476 | - ``changeset.transplant.merge`` for :hg:`transplant` on merges | |
477 | - ``changeset.transplant.normal`` for :hg:`transplant` on other |
|
477 | - ``changeset.transplant.normal`` for :hg:`transplant` on other | |
478 |
|
478 | |||
479 | These dot-separated lists of names are treated as hierarchical ones. |
|
479 | These dot-separated lists of names are treated as hierarchical ones. | |
480 | For example, ``changeset.tag.remove`` customizes the commit message |
|
480 | For example, ``changeset.tag.remove`` customizes the commit message | |
481 | only for :hg:`tag --remove`, but ``changeset.tag`` customizes the |
|
481 | only for :hg:`tag --remove`, but ``changeset.tag`` customizes the | |
482 | commit message for :hg:`tag` regardless of ``--remove`` option. |
|
482 | commit message for :hg:`tag` regardless of ``--remove`` option. | |
483 |
|
483 | |||
484 | When the external editor is invoked for a commit, the corresponding |
|
484 | When the external editor is invoked for a commit, the corresponding | |
485 | dot-separated list of names without the ``changeset.`` prefix |
|
485 | dot-separated list of names without the ``changeset.`` prefix | |
486 | (e.g. ``commit.normal.normal``) is in the ``HGEDITFORM`` environment |
|
486 | (e.g. ``commit.normal.normal``) is in the ``HGEDITFORM`` environment | |
487 | variable. |
|
487 | variable. | |
488 |
|
488 | |||
489 | In this section, items other than ``changeset`` can be referred from |
|
489 | In this section, items other than ``changeset`` can be referred from | |
490 | others. For example, the configuration to list committed files up |
|
490 | others. For example, the configuration to list committed files up | |
491 | below can be referred as ``{listupfiles}``:: |
|
491 | below can be referred as ``{listupfiles}``:: | |
492 |
|
492 | |||
493 | [committemplate] |
|
493 | [committemplate] | |
494 | listupfiles = {file_adds % |
|
494 | listupfiles = {file_adds % | |
495 | "HG: added {file}\n" }{file_mods % |
|
495 | "HG: added {file}\n" }{file_mods % | |
496 | "HG: changed {file}\n" }{file_dels % |
|
496 | "HG: changed {file}\n" }{file_dels % | |
497 | "HG: removed {file}\n" }{if(files, "", |
|
497 | "HG: removed {file}\n" }{if(files, "", | |
498 | "HG: no files changed\n")} |
|
498 | "HG: no files changed\n")} | |
499 |
|
499 | |||
500 | ``decode/encode`` |
|
500 | ``decode/encode`` | |
501 | ----------------- |
|
501 | ----------------- | |
502 |
|
502 | |||
503 | Filters for transforming files on checkout/checkin. This would |
|
503 | Filters for transforming files on checkout/checkin. This would | |
504 | typically be used for newline processing or other |
|
504 | typically be used for newline processing or other | |
505 | localization/canonicalization of files. |
|
505 | localization/canonicalization of files. | |
506 |
|
506 | |||
507 | Filters consist of a filter pattern followed by a filter command. |
|
507 | Filters consist of a filter pattern followed by a filter command. | |
508 | Filter patterns are globs by default, rooted at the repository root. |
|
508 | Filter patterns are globs by default, rooted at the repository root. | |
509 | For example, to match any file ending in ``.txt`` in the root |
|
509 | For example, to match any file ending in ``.txt`` in the root | |
510 | directory only, use the pattern ``*.txt``. To match any file ending |
|
510 | directory only, use the pattern ``*.txt``. To match any file ending | |
511 | in ``.c`` anywhere in the repository, use the pattern ``**.c``. |
|
511 | in ``.c`` anywhere in the repository, use the pattern ``**.c``. | |
512 | For each file only the first matching filter applies. |
|
512 | For each file only the first matching filter applies. | |
513 |
|
513 | |||
514 | The filter command can start with a specifier, either ``pipe:`` or |
|
514 | The filter command can start with a specifier, either ``pipe:`` or | |
515 | ``tempfile:``. If no specifier is given, ``pipe:`` is used by default. |
|
515 | ``tempfile:``. If no specifier is given, ``pipe:`` is used by default. | |
516 |
|
516 | |||
517 | A ``pipe:`` command must accept data on stdin and return the transformed |
|
517 | A ``pipe:`` command must accept data on stdin and return the transformed | |
518 | data on stdout. |
|
518 | data on stdout. | |
519 |
|
519 | |||
520 | Pipe example:: |
|
520 | Pipe example:: | |
521 |
|
521 | |||
522 | [encode] |
|
522 | [encode] | |
523 | # uncompress gzip files on checkin to improve delta compression |
|
523 | # uncompress gzip files on checkin to improve delta compression | |
524 | # note: not necessarily a good idea, just an example |
|
524 | # note: not necessarily a good idea, just an example | |
525 | *.gz = pipe: gunzip |
|
525 | *.gz = pipe: gunzip | |
526 |
|
526 | |||
527 | [decode] |
|
527 | [decode] | |
528 | # recompress gzip files when writing them to the working dir (we |
|
528 | # recompress gzip files when writing them to the working dir (we | |
529 | # can safely omit "pipe:", because it's the default) |
|
529 | # can safely omit "pipe:", because it's the default) | |
530 | *.gz = gzip |
|
530 | *.gz = gzip | |
531 |
|
531 | |||
532 | A ``tempfile:`` command is a template. The string ``INFILE`` is replaced |
|
532 | A ``tempfile:`` command is a template. The string ``INFILE`` is replaced | |
533 | with the name of a temporary file that contains the data to be |
|
533 | with the name of a temporary file that contains the data to be | |
534 | filtered by the command. The string ``OUTFILE`` is replaced with the name |
|
534 | filtered by the command. The string ``OUTFILE`` is replaced with the name | |
535 | of an empty temporary file, where the filtered data must be written by |
|
535 | of an empty temporary file, where the filtered data must be written by | |
536 | the command. |
|
536 | the command. | |
537 |
|
537 | |||
538 | .. container:: windows |
|
538 | .. container:: windows | |
539 |
|
539 | |||
540 | .. note:: |
|
540 | .. note:: | |
541 |
|
541 | |||
542 | The tempfile mechanism is recommended for Windows systems, |
|
542 | The tempfile mechanism is recommended for Windows systems, | |
543 | where the standard shell I/O redirection operators often have |
|
543 | where the standard shell I/O redirection operators often have | |
544 | strange effects and may corrupt the contents of your files. |
|
544 | strange effects and may corrupt the contents of your files. | |
545 |
|
545 | |||
546 | This filter mechanism is used internally by the ``eol`` extension to |
|
546 | This filter mechanism is used internally by the ``eol`` extension to | |
547 | translate line ending characters between Windows (CRLF) and Unix (LF) |
|
547 | translate line ending characters between Windows (CRLF) and Unix (LF) | |
548 | format. We suggest you use the ``eol`` extension for convenience. |
|
548 | format. We suggest you use the ``eol`` extension for convenience. | |
549 |
|
549 | |||
550 |
|
550 | |||
551 | ``defaults`` |
|
551 | ``defaults`` | |
552 | ------------ |
|
552 | ------------ | |
553 |
|
553 | |||
554 | (defaults are deprecated. Don't use them. Use aliases instead.) |
|
554 | (defaults are deprecated. Don't use them. Use aliases instead.) | |
555 |
|
555 | |||
556 | Use the ``[defaults]`` section to define command defaults, i.e. the |
|
556 | Use the ``[defaults]`` section to define command defaults, i.e. the | |
557 | default options/arguments to pass to the specified commands. |
|
557 | default options/arguments to pass to the specified commands. | |
558 |
|
558 | |||
559 | The following example makes :hg:`log` run in verbose mode, and |
|
559 | The following example makes :hg:`log` run in verbose mode, and | |
560 | :hg:`status` show only the modified files, by default:: |
|
560 | :hg:`status` show only the modified files, by default:: | |
561 |
|
561 | |||
562 | [defaults] |
|
562 | [defaults] | |
563 | log = -v |
|
563 | log = -v | |
564 | status = -m |
|
564 | status = -m | |
565 |
|
565 | |||
566 | The actual commands, instead of their aliases, must be used when |
|
566 | The actual commands, instead of their aliases, must be used when | |
567 | defining command defaults. The command defaults will also be applied |
|
567 | defining command defaults. The command defaults will also be applied | |
568 | to the aliases of the commands defined. |
|
568 | to the aliases of the commands defined. | |
569 |
|
569 | |||
570 |
|
570 | |||
571 | ``diff`` |
|
571 | ``diff`` | |
572 | -------- |
|
572 | -------- | |
573 |
|
573 | |||
574 | Settings used when displaying diffs. Everything except for ``unified`` |
|
574 | Settings used when displaying diffs. Everything except for ``unified`` | |
575 | is a Boolean and defaults to False. See :hg:`help config.annotate` |
|
575 | is a Boolean and defaults to False. See :hg:`help config.annotate` | |
576 | for related options for the annotate command. |
|
576 | for related options for the annotate command. | |
577 |
|
577 | |||
578 | ``git`` |
|
578 | ``git`` | |
579 | Use git extended diff format. |
|
579 | Use git extended diff format. | |
580 |
|
580 | |||
581 | ``nobinary`` |
|
581 | ``nobinary`` | |
582 | Omit git binary patches. |
|
582 | Omit git binary patches. | |
583 |
|
583 | |||
584 | ``nodates`` |
|
584 | ``nodates`` | |
585 | Don't include dates in diff headers. |
|
585 | Don't include dates in diff headers. | |
586 |
|
586 | |||
587 | ``noprefix`` |
|
587 | ``noprefix`` | |
588 | Omit 'a/' and 'b/' prefixes from filenames. Ignored in plain mode. |
|
588 | Omit 'a/' and 'b/' prefixes from filenames. Ignored in plain mode. | |
589 |
|
589 | |||
590 | ``showfunc`` |
|
590 | ``showfunc`` | |
591 | Show which function each change is in. |
|
591 | Show which function each change is in. | |
592 |
|
592 | |||
593 | ``ignorews`` |
|
593 | ``ignorews`` | |
594 | Ignore white space when comparing lines. |
|
594 | Ignore white space when comparing lines. | |
595 |
|
595 | |||
596 | ``ignorewsamount`` |
|
596 | ``ignorewsamount`` | |
597 | Ignore changes in the amount of white space. |
|
597 | Ignore changes in the amount of white space. | |
598 |
|
598 | |||
599 | ``ignoreblanklines`` |
|
599 | ``ignoreblanklines`` | |
600 | Ignore changes whose lines are all blank. |
|
600 | Ignore changes whose lines are all blank. | |
601 |
|
601 | |||
602 | ``unified`` |
|
602 | ``unified`` | |
603 | Number of lines of context to show. |
|
603 | Number of lines of context to show. | |
604 |
|
604 | |||
605 | ``email`` |
|
605 | ``email`` | |
606 | --------- |
|
606 | --------- | |
607 |
|
607 | |||
608 | Settings for extensions that send email messages. |
|
608 | Settings for extensions that send email messages. | |
609 |
|
609 | |||
610 | ``from`` |
|
610 | ``from`` | |
611 | Optional. Email address to use in "From" header and SMTP envelope |
|
611 | Optional. Email address to use in "From" header and SMTP envelope | |
612 | of outgoing messages. |
|
612 | of outgoing messages. | |
613 |
|
613 | |||
614 | ``to`` |
|
614 | ``to`` | |
615 | Optional. Comma-separated list of recipients' email addresses. |
|
615 | Optional. Comma-separated list of recipients' email addresses. | |
616 |
|
616 | |||
617 | ``cc`` |
|
617 | ``cc`` | |
618 | Optional. Comma-separated list of carbon copy recipients' |
|
618 | Optional. Comma-separated list of carbon copy recipients' | |
619 | email addresses. |
|
619 | email addresses. | |
620 |
|
620 | |||
621 | ``bcc`` |
|
621 | ``bcc`` | |
622 | Optional. Comma-separated list of blind carbon copy recipients' |
|
622 | Optional. Comma-separated list of blind carbon copy recipients' | |
623 | email addresses. |
|
623 | email addresses. | |
624 |
|
624 | |||
625 | ``method`` |
|
625 | ``method`` | |
626 | Optional. Method to use to send email messages. If value is ``smtp`` |
|
626 | Optional. Method to use to send email messages. If value is ``smtp`` | |
627 | (default), use SMTP (see the ``[smtp]`` section for configuration). |
|
627 | (default), use SMTP (see the ``[smtp]`` section for configuration). | |
628 | Otherwise, use as name of program to run that acts like sendmail |
|
628 | Otherwise, use as name of program to run that acts like sendmail | |
629 | (takes ``-f`` option for sender, list of recipients on command line, |
|
629 | (takes ``-f`` option for sender, list of recipients on command line, | |
630 | message on stdin). Normally, setting this to ``sendmail`` or |
|
630 | message on stdin). Normally, setting this to ``sendmail`` or | |
631 | ``/usr/sbin/sendmail`` is enough to use sendmail to send messages. |
|
631 | ``/usr/sbin/sendmail`` is enough to use sendmail to send messages. | |
632 |
|
632 | |||
633 | ``charsets`` |
|
633 | ``charsets`` | |
634 | Optional. Comma-separated list of character sets considered |
|
634 | Optional. Comma-separated list of character sets considered | |
635 | convenient for recipients. Addresses, headers, and parts not |
|
635 | convenient for recipients. Addresses, headers, and parts not | |
636 | containing patches of outgoing messages will be encoded in the |
|
636 | containing patches of outgoing messages will be encoded in the | |
637 | first character set to which conversion from local encoding |
|
637 | first character set to which conversion from local encoding | |
638 | (``$HGENCODING``, ``ui.fallbackencoding``) succeeds. If correct |
|
638 | (``$HGENCODING``, ``ui.fallbackencoding``) succeeds. If correct | |
639 | conversion fails, the text in question is sent as is. |
|
639 | conversion fails, the text in question is sent as is. | |
640 | (default: '') |
|
640 | (default: '') | |
641 |
|
641 | |||
642 | Order of outgoing email character sets: |
|
642 | Order of outgoing email character sets: | |
643 |
|
643 | |||
644 | 1. ``us-ascii``: always first, regardless of settings |
|
644 | 1. ``us-ascii``: always first, regardless of settings | |
645 | 2. ``email.charsets``: in order given by user |
|
645 | 2. ``email.charsets``: in order given by user | |
646 | 3. ``ui.fallbackencoding``: if not in email.charsets |
|
646 | 3. ``ui.fallbackencoding``: if not in email.charsets | |
647 | 4. ``$HGENCODING``: if not in email.charsets |
|
647 | 4. ``$HGENCODING``: if not in email.charsets | |
648 | 5. ``utf-8``: always last, regardless of settings |
|
648 | 5. ``utf-8``: always last, regardless of settings | |
649 |
|
649 | |||
650 | Email example:: |
|
650 | Email example:: | |
651 |
|
651 | |||
652 | [email] |
|
652 | [email] | |
653 | from = Joseph User <joe.user@example.com> |
|
653 | from = Joseph User <joe.user@example.com> | |
654 | method = /usr/sbin/sendmail |
|
654 | method = /usr/sbin/sendmail | |
655 | # charsets for western Europeans |
|
655 | # charsets for western Europeans | |
656 | # us-ascii, utf-8 omitted, as they are tried first and last |
|
656 | # us-ascii, utf-8 omitted, as they are tried first and last | |
657 | charsets = iso-8859-1, iso-8859-15, windows-1252 |
|
657 | charsets = iso-8859-1, iso-8859-15, windows-1252 | |
658 |
|
658 | |||
659 |
|
659 | |||
660 | ``extensions`` |
|
660 | ``extensions`` | |
661 | -------------- |
|
661 | -------------- | |
662 |
|
662 | |||
663 | Mercurial has an extension mechanism for adding new features. To |
|
663 | Mercurial has an extension mechanism for adding new features. To | |
664 | enable an extension, create an entry for it in this section. |
|
664 | enable an extension, create an entry for it in this section. | |
665 |
|
665 | |||
666 | If you know that the extension is already in Python's search path, |
|
666 | If you know that the extension is already in Python's search path, | |
667 | you can give the name of the module, followed by ``=``, with nothing |
|
667 | you can give the name of the module, followed by ``=``, with nothing | |
668 | after the ``=``. |
|
668 | after the ``=``. | |
669 |
|
669 | |||
670 | Otherwise, give a name that you choose, followed by ``=``, followed by |
|
670 | Otherwise, give a name that you choose, followed by ``=``, followed by | |
671 | the path to the ``.py`` file (including the file name extension) that |
|
671 | the path to the ``.py`` file (including the file name extension) that | |
672 | defines the extension. |
|
672 | defines the extension. | |
673 |
|
673 | |||
674 | To explicitly disable an extension that is enabled in an hgrc of |
|
674 | To explicitly disable an extension that is enabled in an hgrc of | |
675 | broader scope, prepend its path with ``!``, as in ``foo = !/ext/path`` |
|
675 | broader scope, prepend its path with ``!``, as in ``foo = !/ext/path`` | |
676 | or ``foo = !`` when path is not supplied. |
|
676 | or ``foo = !`` when path is not supplied. | |
677 |
|
677 | |||
678 | Example for ``~/.hgrc``:: |
|
678 | Example for ``~/.hgrc``:: | |
679 |
|
679 | |||
680 | [extensions] |
|
680 | [extensions] | |
681 | # (the color extension will get loaded from Mercurial's path) |
|
681 | # (the color extension will get loaded from Mercurial's path) | |
682 | color = |
|
682 | color = | |
683 | # (this extension will get loaded from the file specified) |
|
683 | # (this extension will get loaded from the file specified) | |
684 | myfeature = ~/.hgext/myfeature.py |
|
684 | myfeature = ~/.hgext/myfeature.py | |
685 |
|
685 | |||
686 |
|
686 | |||
687 | ``format`` |
|
687 | ``format`` | |
688 | ---------- |
|
688 | ---------- | |
689 |
|
689 | |||
690 | ``usegeneraldelta`` |
|
690 | ``usegeneraldelta`` | |
691 | Enable or disable the "generaldelta" repository format which improves |
|
691 | Enable or disable the "generaldelta" repository format which improves | |
692 | repository compression by allowing "revlog" to store delta against arbitrary |
|
692 | repository compression by allowing "revlog" to store delta against arbitrary | |
693 | revision instead of the previous stored one. This provides significant |
|
693 | revision instead of the previous stored one. This provides significant | |
694 | improvement for repositories with branches. |
|
694 | improvement for repositories with branches. | |
695 |
|
695 | |||
696 | Repositories with this on-disk format require Mercurial version 1.9. |
|
696 | Repositories with this on-disk format require Mercurial version 1.9. | |
697 |
|
697 | |||
698 | Enabled by default. |
|
698 | Enabled by default. | |
699 |
|
699 | |||
700 | ``dotencode`` |
|
700 | ``dotencode`` | |
701 | Enable or disable the "dotencode" repository format which enhances |
|
701 | Enable or disable the "dotencode" repository format which enhances | |
702 | the "fncache" repository format (which has to be enabled to use |
|
702 | the "fncache" repository format (which has to be enabled to use | |
703 | dotencode) to avoid issues with filenames starting with ._ on |
|
703 | dotencode) to avoid issues with filenames starting with ._ on | |
704 | Mac OS X and spaces on Windows. |
|
704 | Mac OS X and spaces on Windows. | |
705 |
|
705 | |||
706 | Repositories with this on-disk format require Mercurial version 1.7. |
|
706 | Repositories with this on-disk format require Mercurial version 1.7. | |
707 |
|
707 | |||
708 | Enabled by default. |
|
708 | Enabled by default. | |
709 |
|
709 | |||
710 | ``usefncache`` |
|
710 | ``usefncache`` | |
711 | Enable or disable the "fncache" repository format which enhances |
|
711 | Enable or disable the "fncache" repository format which enhances | |
712 | the "store" repository format (which has to be enabled to use |
|
712 | the "store" repository format (which has to be enabled to use | |
713 | fncache) to allow longer filenames and avoids using Windows |
|
713 | fncache) to allow longer filenames and avoids using Windows | |
714 | reserved names, e.g. "nul". |
|
714 | reserved names, e.g. "nul". | |
715 |
|
715 | |||
716 | Repositories with this on-disk format require Mercurial version 1.1. |
|
716 | Repositories with this on-disk format require Mercurial version 1.1. | |
717 |
|
717 | |||
718 | Enabled by default. |
|
718 | Enabled by default. | |
719 |
|
719 | |||
720 | ``usestore`` |
|
720 | ``usestore`` | |
721 | Enable or disable the "store" repository format which improves |
|
721 | Enable or disable the "store" repository format which improves | |
722 | compatibility with systems that fold case or otherwise mangle |
|
722 | compatibility with systems that fold case or otherwise mangle | |
723 | filenames. Disabling this option will allow you to store longer filenames |
|
723 | filenames. Disabling this option will allow you to store longer filenames | |
724 | in some situations at the expense of compatibility. |
|
724 | in some situations at the expense of compatibility. | |
725 |
|
725 | |||
726 | Repositories with this on-disk format require Mercurial version 0.9.4. |
|
726 | Repositories with this on-disk format require Mercurial version 0.9.4. | |
727 |
|
727 | |||
728 | Enabled by default. |
|
728 | Enabled by default. | |
729 |
|
729 | |||
730 | ``graph`` |
|
730 | ``graph`` | |
731 | --------- |
|
731 | --------- | |
732 |
|
732 | |||
733 | Web graph view configuration. This section let you change graph |
|
733 | Web graph view configuration. This section let you change graph | |
734 | elements display properties by branches, for instance to make the |
|
734 | elements display properties by branches, for instance to make the | |
735 | ``default`` branch stand out. |
|
735 | ``default`` branch stand out. | |
736 |
|
736 | |||
737 | Each line has the following format:: |
|
737 | Each line has the following format:: | |
738 |
|
738 | |||
739 | <branch>.<argument> = <value> |
|
739 | <branch>.<argument> = <value> | |
740 |
|
740 | |||
741 | where ``<branch>`` is the name of the branch being |
|
741 | where ``<branch>`` is the name of the branch being | |
742 | customized. Example:: |
|
742 | customized. Example:: | |
743 |
|
743 | |||
744 | [graph] |
|
744 | [graph] | |
745 | # 2px width |
|
745 | # 2px width | |
746 | default.width = 2 |
|
746 | default.width = 2 | |
747 | # red color |
|
747 | # red color | |
748 | default.color = FF0000 |
|
748 | default.color = FF0000 | |
749 |
|
749 | |||
750 | Supported arguments: |
|
750 | Supported arguments: | |
751 |
|
751 | |||
752 | ``width`` |
|
752 | ``width`` | |
753 | Set branch edges width in pixels. |
|
753 | Set branch edges width in pixels. | |
754 |
|
754 | |||
755 | ``color`` |
|
755 | ``color`` | |
756 | Set branch edges color in hexadecimal RGB notation. |
|
756 | Set branch edges color in hexadecimal RGB notation. | |
757 |
|
757 | |||
758 | ``hooks`` |
|
758 | ``hooks`` | |
759 | --------- |
|
759 | --------- | |
760 |
|
760 | |||
761 | Commands or Python functions that get automatically executed by |
|
761 | Commands or Python functions that get automatically executed by | |
762 | various actions such as starting or finishing a commit. Multiple |
|
762 | various actions such as starting or finishing a commit. Multiple | |
763 | hooks can be run for the same action by appending a suffix to the |
|
763 | hooks can be run for the same action by appending a suffix to the | |
764 | action. Overriding a site-wide hook can be done by changing its |
|
764 | action. Overriding a site-wide hook can be done by changing its | |
765 | value or setting it to an empty string. Hooks can be prioritized |
|
765 | value or setting it to an empty string. Hooks can be prioritized | |
766 | by adding a prefix of ``priority.`` to the hook name on a new line |
|
766 | by adding a prefix of ``priority.`` to the hook name on a new line | |
767 | and setting the priority. The default priority is 0. |
|
767 | and setting the priority. The default priority is 0. | |
768 |
|
768 | |||
769 | Example ``.hg/hgrc``:: |
|
769 | Example ``.hg/hgrc``:: | |
770 |
|
770 | |||
771 | [hooks] |
|
771 | [hooks] | |
772 | # update working directory after adding changesets |
|
772 | # update working directory after adding changesets | |
773 | changegroup.update = hg update |
|
773 | changegroup.update = hg update | |
774 | # do not use the site-wide hook |
|
774 | # do not use the site-wide hook | |
775 | incoming = |
|
775 | incoming = | |
776 | incoming.email = /my/email/hook |
|
776 | incoming.email = /my/email/hook | |
777 | incoming.autobuild = /my/build/hook |
|
777 | incoming.autobuild = /my/build/hook | |
778 | # force autobuild hook to run before other incoming hooks |
|
778 | # force autobuild hook to run before other incoming hooks | |
779 | priority.incoming.autobuild = 1 |
|
779 | priority.incoming.autobuild = 1 | |
780 |
|
780 | |||
781 | Most hooks are run with environment variables set that give useful |
|
781 | Most hooks are run with environment variables set that give useful | |
782 | additional information. For each hook below, the environment |
|
782 | additional information. For each hook below, the environment | |
783 | variables it is passed are listed with names of the form ``$HG_foo``. |
|
783 | variables it is passed are listed with names of the form ``$HG_foo``. | |
784 |
|
784 | |||
785 | ``changegroup`` |
|
785 | ``changegroup`` | |
786 | Run after a changegroup has been added via push, pull or unbundle. ID of the |
|
786 | Run after a changegroup has been added via push, pull or unbundle. ID of the | |
787 | first new changeset is in ``$HG_NODE`` and last in ``$HG_NODE_LAST``. URL |
|
787 | first new changeset is in ``$HG_NODE`` and last in ``$HG_NODE_LAST``. URL | |
788 | from which changes came is in ``$HG_URL``. |
|
788 | from which changes came is in ``$HG_URL``. | |
789 |
|
789 | |||
790 | ``commit`` |
|
790 | ``commit`` | |
791 | Run after a changeset has been created in the local repository. ID |
|
791 | Run after a changeset has been created in the local repository. ID | |
792 | of the newly created changeset is in ``$HG_NODE``. Parent changeset |
|
792 | of the newly created changeset is in ``$HG_NODE``. Parent changeset | |
793 | IDs are in ``$HG_PARENT1`` and ``$HG_PARENT2``. |
|
793 | IDs are in ``$HG_PARENT1`` and ``$HG_PARENT2``. | |
794 |
|
794 | |||
795 | ``incoming`` |
|
795 | ``incoming`` | |
796 | Run after a changeset has been pulled, pushed, or unbundled into |
|
796 | Run after a changeset has been pulled, pushed, or unbundled into | |
797 | the local repository. The ID of the newly arrived changeset is in |
|
797 | the local repository. The ID of the newly arrived changeset is in | |
798 | ``$HG_NODE``. URL that was source of changes came is in ``$HG_URL``. |
|
798 | ``$HG_NODE``. URL that was source of changes came is in ``$HG_URL``. | |
799 |
|
799 | |||
800 | ``outgoing`` |
|
800 | ``outgoing`` | |
801 | Run after sending changes from local repository to another. ID of |
|
801 | Run after sending changes from local repository to another. ID of | |
802 | first changeset sent is in ``$HG_NODE``. Source of operation is in |
|
802 | first changeset sent is in ``$HG_NODE``. Source of operation is in | |
803 | ``$HG_SOURCE``; Also see :hg:`help config.hooks.preoutgoing` hook. |
|
803 | ``$HG_SOURCE``; Also see :hg:`help config.hooks.preoutgoing` hook. | |
804 |
|
804 | |||
805 | ``post-<command>`` |
|
805 | ``post-<command>`` | |
806 | Run after successful invocations of the associated command. The |
|
806 | Run after successful invocations of the associated command. The | |
807 | contents of the command line are passed as ``$HG_ARGS`` and the result |
|
807 | contents of the command line are passed as ``$HG_ARGS`` and the result | |
808 | code in ``$HG_RESULT``. Parsed command line arguments are passed as |
|
808 | code in ``$HG_RESULT``. Parsed command line arguments are passed as | |
809 | ``$HG_PATS`` and ``$HG_OPTS``. These contain string representations of |
|
809 | ``$HG_PATS`` and ``$HG_OPTS``. These contain string representations of | |
810 | the python data internally passed to <command>. ``$HG_OPTS`` is a |
|
810 | the python data internally passed to <command>. ``$HG_OPTS`` is a | |
811 | dictionary of options (with unspecified options set to their defaults). |
|
811 | dictionary of options (with unspecified options set to their defaults). | |
812 | ``$HG_PATS`` is a list of arguments. Hook failure is ignored. |
|
812 | ``$HG_PATS`` is a list of arguments. Hook failure is ignored. | |
813 |
|
813 | |||
814 | ``fail-<command>`` |
|
814 | ``fail-<command>`` | |
815 | Run after a failed invocation of an associated command. The contents |
|
815 | Run after a failed invocation of an associated command. The contents | |
816 | of the command line are passed as ``$HG_ARGS``. Parsed command line |
|
816 | of the command line are passed as ``$HG_ARGS``. Parsed command line | |
817 | arguments are passed as ``$HG_PATS`` and ``$HG_OPTS``. These contain |
|
817 | arguments are passed as ``$HG_PATS`` and ``$HG_OPTS``. These contain | |
818 | string representations of the python data internally passed to |
|
818 | string representations of the python data internally passed to | |
819 | <command>. ``$HG_OPTS`` is a dictionary of options (with unspecified |
|
819 | <command>. ``$HG_OPTS`` is a dictionary of options (with unspecified | |
820 | options set to their defaults). ``$HG_PATS`` is a list of arguments. |
|
820 | options set to their defaults). ``$HG_PATS`` is a list of arguments. | |
821 | Hook failure is ignored. |
|
821 | Hook failure is ignored. | |
822 |
|
822 | |||
823 | ``pre-<command>`` |
|
823 | ``pre-<command>`` | |
824 | Run before executing the associated command. The contents of the |
|
824 | Run before executing the associated command. The contents of the | |
825 | command line are passed as ``$HG_ARGS``. Parsed command line arguments |
|
825 | command line are passed as ``$HG_ARGS``. Parsed command line arguments | |
826 | are passed as ``$HG_PATS`` and ``$HG_OPTS``. These contain string |
|
826 | are passed as ``$HG_PATS`` and ``$HG_OPTS``. These contain string | |
827 | representations of the data internally passed to <command>. ``$HG_OPTS`` |
|
827 | representations of the data internally passed to <command>. ``$HG_OPTS`` | |
828 | is a dictionary of options (with unspecified options set to their |
|
828 | is a dictionary of options (with unspecified options set to their | |
829 | defaults). ``$HG_PATS`` is a list of arguments. If the hook returns |
|
829 | defaults). ``$HG_PATS`` is a list of arguments. If the hook returns | |
830 | failure, the command doesn't execute and Mercurial returns the failure |
|
830 | failure, the command doesn't execute and Mercurial returns the failure | |
831 | code. |
|
831 | code. | |
832 |
|
832 | |||
833 | ``prechangegroup`` |
|
833 | ``prechangegroup`` | |
834 | Run before a changegroup is added via push, pull or unbundle. Exit |
|
834 | Run before a changegroup is added via push, pull or unbundle. Exit | |
835 | status 0 allows the changegroup to proceed. Non-zero status will |
|
835 | status 0 allows the changegroup to proceed. Non-zero status will | |
836 | cause the push, pull or unbundle to fail. URL from which changes |
|
836 | cause the push, pull or unbundle to fail. URL from which changes | |
837 | will come is in ``$HG_URL``. |
|
837 | will come is in ``$HG_URL``. | |
838 |
|
838 | |||
839 | ``precommit`` |
|
839 | ``precommit`` | |
840 | Run before starting a local commit. Exit status 0 allows the |
|
840 | Run before starting a local commit. Exit status 0 allows the | |
841 | commit to proceed. Non-zero status will cause the commit to fail. |
|
841 | commit to proceed. Non-zero status will cause the commit to fail. | |
842 | Parent changeset IDs are in ``$HG_PARENT1`` and ``$HG_PARENT2``. |
|
842 | Parent changeset IDs are in ``$HG_PARENT1`` and ``$HG_PARENT2``. | |
843 |
|
843 | |||
844 | ``prelistkeys`` |
|
844 | ``prelistkeys`` | |
845 | Run before listing pushkeys (like bookmarks) in the |
|
845 | Run before listing pushkeys (like bookmarks) in the | |
846 | repository. Non-zero status will cause failure. The key namespace is |
|
846 | repository. Non-zero status will cause failure. The key namespace is | |
847 | in ``$HG_NAMESPACE``. |
|
847 | in ``$HG_NAMESPACE``. | |
848 |
|
848 | |||
849 | ``preoutgoing`` |
|
849 | ``preoutgoing`` | |
850 | Run before collecting changes to send from the local repository to |
|
850 | Run before collecting changes to send from the local repository to | |
851 | another. Non-zero status will cause failure. This lets you prevent |
|
851 | another. Non-zero status will cause failure. This lets you prevent | |
852 | pull over HTTP or SSH. Also prevents against local pull, push |
|
852 | pull over HTTP or SSH. Also prevents against local pull, push | |
853 | (outbound) or bundle commands, but not effective, since you can |
|
853 | (outbound) or bundle commands, but not effective, since you can | |
854 | just copy files instead then. Source of operation is in |
|
854 | just copy files instead then. Source of operation is in | |
855 | ``$HG_SOURCE``. If "serve", operation is happening on behalf of remote |
|
855 | ``$HG_SOURCE``. If "serve", operation is happening on behalf of remote | |
856 | SSH or HTTP repository. If "push", "pull" or "bundle", operation |
|
856 | SSH or HTTP repository. If "push", "pull" or "bundle", operation | |
857 | is happening on behalf of repository on same system. |
|
857 | is happening on behalf of repository on same system. | |
858 |
|
858 | |||
859 | ``prepushkey`` |
|
859 | ``prepushkey`` | |
860 | Run before a pushkey (like a bookmark) is added to the |
|
860 | Run before a pushkey (like a bookmark) is added to the | |
861 | repository. Non-zero status will cause the key to be rejected. The |
|
861 | repository. Non-zero status will cause the key to be rejected. The | |
862 | key namespace is in ``$HG_NAMESPACE``, the key is in ``$HG_KEY``, |
|
862 | key namespace is in ``$HG_NAMESPACE``, the key is in ``$HG_KEY``, | |
863 | the old value (if any) is in ``$HG_OLD``, and the new value is in |
|
863 | the old value (if any) is in ``$HG_OLD``, and the new value is in | |
864 | ``$HG_NEW``. |
|
864 | ``$HG_NEW``. | |
865 |
|
865 | |||
866 | ``pretag`` |
|
866 | ``pretag`` | |
867 | Run before creating a tag. Exit status 0 allows the tag to be |
|
867 | Run before creating a tag. Exit status 0 allows the tag to be | |
868 | created. Non-zero status will cause the tag to fail. ID of |
|
868 | created. Non-zero status will cause the tag to fail. ID of | |
869 | changeset to tag is in ``$HG_NODE``. Name of tag is in ``$HG_TAG``. Tag is |
|
869 | changeset to tag is in ``$HG_NODE``. Name of tag is in ``$HG_TAG``. Tag is | |
870 | local if ``$HG_LOCAL=1``, in repository if ``$HG_LOCAL=0``. |
|
870 | local if ``$HG_LOCAL=1``, in repository if ``$HG_LOCAL=0``. | |
871 |
|
871 | |||
872 | ``pretxnopen`` |
|
872 | ``pretxnopen`` | |
873 | Run before any new repository transaction is open. The reason for the |
|
873 | Run before any new repository transaction is open. The reason for the | |
874 | transaction will be in ``$HG_TXNNAME`` and a unique identifier for the |
|
874 | transaction will be in ``$HG_TXNNAME`` and a unique identifier for the | |
875 | transaction will be in ``HG_TXNID``. A non-zero status will prevent the |
|
875 | transaction will be in ``HG_TXNID``. A non-zero status will prevent the | |
876 | transaction from being opened. |
|
876 | transaction from being opened. | |
877 |
|
877 | |||
878 | ``pretxnclose`` |
|
878 | ``pretxnclose`` | |
879 | Run right before the transaction is actually finalized. Any repository change |
|
879 | Run right before the transaction is actually finalized. Any repository change | |
880 | will be visible to the hook program. This lets you validate the transaction |
|
880 | will be visible to the hook program. This lets you validate the transaction | |
881 | content or change it. Exit status 0 allows the commit to proceed. Non-zero |
|
881 | content or change it. Exit status 0 allows the commit to proceed. Non-zero | |
882 | status will cause the transaction to be rolled back. The reason for the |
|
882 | status will cause the transaction to be rolled back. The reason for the | |
883 | transaction opening will be in ``$HG_TXNNAME`` and a unique identifier for |
|
883 | transaction opening will be in ``$HG_TXNNAME`` and a unique identifier for | |
884 | the transaction will be in ``HG_TXNID``. The rest of the available data will |
|
884 | the transaction will be in ``HG_TXNID``. The rest of the available data will | |
885 | vary according the transaction type. New changesets will add ``$HG_NODE`` (id |
|
885 | vary according the transaction type. New changesets will add ``$HG_NODE`` (id | |
886 | of the first added changeset), ``$HG_NODE_LAST`` (id of the last added |
|
886 | of the first added changeset), ``$HG_NODE_LAST`` (id of the last added | |
887 | changeset), ``$HG_URL`` and ``$HG_SOURCE`` variables, bookmarks and phases |
|
887 | changeset), ``$HG_URL`` and ``$HG_SOURCE`` variables, bookmarks and phases | |
888 | changes will set ``HG_BOOKMARK_MOVED`` and ``HG_PHASES_MOVED`` to ``1``, etc. |
|
888 | changes will set ``HG_BOOKMARK_MOVED`` and ``HG_PHASES_MOVED`` to ``1``, etc. | |
889 |
|
889 | |||
890 | ``txnclose`` |
|
890 | ``txnclose`` | |
891 | Run after any repository transaction has been committed. At this |
|
891 | Run after any repository transaction has been committed. At this | |
892 | point, the transaction can no longer be rolled back. The hook will run |
|
892 | point, the transaction can no longer be rolled back. The hook will run | |
893 | after the lock is released. See :hg:`help config.hooks.pretxnclose` docs for |
|
893 | after the lock is released. See :hg:`help config.hooks.pretxnclose` docs for | |
894 | details about available variables. |
|
894 | details about available variables. | |
895 |
|
895 | |||
896 | ``txnabort`` |
|
896 | ``txnabort`` | |
897 | Run when a transaction is aborted. See :hg:`help config.hooks.pretxnclose` |
|
897 | Run when a transaction is aborted. See :hg:`help config.hooks.pretxnclose` | |
898 | docs for details about available variables. |
|
898 | docs for details about available variables. | |
899 |
|
899 | |||
900 | ``pretxnchangegroup`` |
|
900 | ``pretxnchangegroup`` | |
901 | Run after a changegroup has been added via push, pull or unbundle, but before |
|
901 | Run after a changegroup has been added via push, pull or unbundle, but before | |
902 | the transaction has been committed. Changegroup is visible to hook program. |
|
902 | the transaction has been committed. Changegroup is visible to hook program. | |
903 | This lets you validate incoming changes before accepting them. Passed the ID |
|
903 | This lets you validate incoming changes before accepting them. Passed the ID | |
904 | of the first new changeset in ``$HG_NODE`` and last in ``$HG_NODE_LAST``. |
|
904 | of the first new changeset in ``$HG_NODE`` and last in ``$HG_NODE_LAST``. | |
905 | Exit status 0 allows the transaction to commit. Non-zero status will cause |
|
905 | Exit status 0 allows the transaction to commit. Non-zero status will cause | |
906 | the transaction to be rolled back and the push, pull or unbundle will fail. |
|
906 | the transaction to be rolled back and the push, pull or unbundle will fail. | |
907 | URL that was source of changes is in ``$HG_URL``. |
|
907 | URL that was source of changes is in ``$HG_URL``. | |
908 |
|
908 | |||
909 | ``pretxncommit`` |
|
909 | ``pretxncommit`` | |
910 | Run after a changeset has been created but the transaction not yet |
|
910 | Run after a changeset has been created but the transaction not yet | |
911 | committed. Changeset is visible to hook program. This lets you |
|
911 | committed. Changeset is visible to hook program. This lets you | |
912 | validate commit message and changes. Exit status 0 allows the |
|
912 | validate commit message and changes. Exit status 0 allows the | |
913 | commit to proceed. Non-zero status will cause the transaction to |
|
913 | commit to proceed. Non-zero status will cause the transaction to | |
914 | be rolled back. ID of changeset is in ``$HG_NODE``. Parent changeset |
|
914 | be rolled back. ID of changeset is in ``$HG_NODE``. Parent changeset | |
915 | IDs are in ``$HG_PARENT1`` and ``$HG_PARENT2``. |
|
915 | IDs are in ``$HG_PARENT1`` and ``$HG_PARENT2``. | |
916 |
|
916 | |||
917 | ``preupdate`` |
|
917 | ``preupdate`` | |
918 | Run before updating the working directory. Exit status 0 allows |
|
918 | Run before updating the working directory. Exit status 0 allows | |
919 | the update to proceed. Non-zero status will prevent the update. |
|
919 | the update to proceed. Non-zero status will prevent the update. | |
920 | Changeset ID of first new parent is in ``$HG_PARENT1``. If merge, ID |
|
920 | Changeset ID of first new parent is in ``$HG_PARENT1``. If merge, ID | |
921 | of second new parent is in ``$HG_PARENT2``. |
|
921 | of second new parent is in ``$HG_PARENT2``. | |
922 |
|
922 | |||
923 | ``listkeys`` |
|
923 | ``listkeys`` | |
924 | Run after listing pushkeys (like bookmarks) in the repository. The |
|
924 | Run after listing pushkeys (like bookmarks) in the repository. The | |
925 | key namespace is in ``$HG_NAMESPACE``. ``$HG_VALUES`` is a |
|
925 | key namespace is in ``$HG_NAMESPACE``. ``$HG_VALUES`` is a | |
926 | dictionary containing the keys and values. |
|
926 | dictionary containing the keys and values. | |
927 |
|
927 | |||
928 | ``pushkey`` |
|
928 | ``pushkey`` | |
929 | Run after a pushkey (like a bookmark) is added to the |
|
929 | Run after a pushkey (like a bookmark) is added to the | |
930 | repository. The key namespace is in ``$HG_NAMESPACE``, the key is in |
|
930 | repository. The key namespace is in ``$HG_NAMESPACE``, the key is in | |
931 | ``$HG_KEY``, the old value (if any) is in ``$HG_OLD``, and the new |
|
931 | ``$HG_KEY``, the old value (if any) is in ``$HG_OLD``, and the new | |
932 | value is in ``$HG_NEW``. |
|
932 | value is in ``$HG_NEW``. | |
933 |
|
933 | |||
934 | ``tag`` |
|
934 | ``tag`` | |
935 | Run after a tag is created. ID of tagged changeset is in ``$HG_NODE``. |
|
935 | Run after a tag is created. ID of tagged changeset is in ``$HG_NODE``. | |
936 | Name of tag is in ``$HG_TAG``. Tag is local if ``$HG_LOCAL=1``, in |
|
936 | Name of tag is in ``$HG_TAG``. Tag is local if ``$HG_LOCAL=1``, in | |
937 | repository if ``$HG_LOCAL=0``. |
|
937 | repository if ``$HG_LOCAL=0``. | |
938 |
|
938 | |||
939 | ``update`` |
|
939 | ``update`` | |
940 | Run after updating the working directory. Changeset ID of first |
|
940 | Run after updating the working directory. Changeset ID of first | |
941 | new parent is in ``$HG_PARENT1``. If merge, ID of second new parent is |
|
941 | new parent is in ``$HG_PARENT1``. If merge, ID of second new parent is | |
942 | in ``$HG_PARENT2``. If the update succeeded, ``$HG_ERROR=0``. If the |
|
942 | in ``$HG_PARENT2``. If the update succeeded, ``$HG_ERROR=0``. If the | |
943 | update failed (e.g. because conflicts not resolved), ``$HG_ERROR=1``. |
|
943 | update failed (e.g. because conflicts not resolved), ``$HG_ERROR=1``. | |
944 |
|
944 | |||
945 | .. note:: |
|
945 | .. note:: | |
946 |
|
946 | |||
947 | It is generally better to use standard hooks rather than the |
|
947 | It is generally better to use standard hooks rather than the | |
948 | generic pre- and post- command hooks as they are guaranteed to be |
|
948 | generic pre- and post- command hooks as they are guaranteed to be | |
949 | called in the appropriate contexts for influencing transactions. |
|
949 | called in the appropriate contexts for influencing transactions. | |
950 | Also, hooks like "commit" will be called in all contexts that |
|
950 | Also, hooks like "commit" will be called in all contexts that | |
951 | generate a commit (e.g. tag) and not just the commit command. |
|
951 | generate a commit (e.g. tag) and not just the commit command. | |
952 |
|
952 | |||
953 | .. note:: |
|
953 | .. note:: | |
954 |
|
954 | |||
955 | Environment variables with empty values may not be passed to |
|
955 | Environment variables with empty values may not be passed to | |
956 | hooks on platforms such as Windows. As an example, ``$HG_PARENT2`` |
|
956 | hooks on platforms such as Windows. As an example, ``$HG_PARENT2`` | |
957 | will have an empty value under Unix-like platforms for non-merge |
|
957 | will have an empty value under Unix-like platforms for non-merge | |
958 | changesets, while it will not be available at all under Windows. |
|
958 | changesets, while it will not be available at all under Windows. | |
959 |
|
959 | |||
960 | The syntax for Python hooks is as follows:: |
|
960 | The syntax for Python hooks is as follows:: | |
961 |
|
961 | |||
962 | hookname = python:modulename.submodule.callable |
|
962 | hookname = python:modulename.submodule.callable | |
963 | hookname = python:/path/to/python/module.py:callable |
|
963 | hookname = python:/path/to/python/module.py:callable | |
964 |
|
964 | |||
965 | Python hooks are run within the Mercurial process. Each hook is |
|
965 | Python hooks are run within the Mercurial process. Each hook is | |
966 | called with at least three keyword arguments: a ui object (keyword |
|
966 | called with at least three keyword arguments: a ui object (keyword | |
967 | ``ui``), a repository object (keyword ``repo``), and a ``hooktype`` |
|
967 | ``ui``), a repository object (keyword ``repo``), and a ``hooktype`` | |
968 | keyword that tells what kind of hook is used. Arguments listed as |
|
968 | keyword that tells what kind of hook is used. Arguments listed as | |
969 | environment variables above are passed as keyword arguments, with no |
|
969 | environment variables above are passed as keyword arguments, with no | |
970 | ``HG_`` prefix, and names in lower case. |
|
970 | ``HG_`` prefix, and names in lower case. | |
971 |
|
971 | |||
972 | If a Python hook returns a "true" value or raises an exception, this |
|
972 | If a Python hook returns a "true" value or raises an exception, this | |
973 | is treated as a failure. |
|
973 | is treated as a failure. | |
974 |
|
974 | |||
975 |
|
975 | |||
976 | ``hostfingerprints`` |
|
976 | ``hostfingerprints`` | |
977 | -------------------- |
|
977 | -------------------- | |
978 |
|
978 | |||
979 | (Deprecated. Use ``[hostsecurity]``'s ``fingerprints`` options instead.) |
|
979 | (Deprecated. Use ``[hostsecurity]``'s ``fingerprints`` options instead.) | |
980 |
|
980 | |||
981 | Fingerprints of the certificates of known HTTPS servers. |
|
981 | Fingerprints of the certificates of known HTTPS servers. | |
982 |
|
982 | |||
983 | A HTTPS connection to a server with a fingerprint configured here will |
|
983 | A HTTPS connection to a server with a fingerprint configured here will | |
984 | only succeed if the servers certificate matches the fingerprint. |
|
984 | only succeed if the servers certificate matches the fingerprint. | |
985 | This is very similar to how ssh known hosts works. |
|
985 | This is very similar to how ssh known hosts works. | |
986 |
|
986 | |||
987 | The fingerprint is the SHA-1 hash value of the DER encoded certificate. |
|
987 | The fingerprint is the SHA-1 hash value of the DER encoded certificate. | |
988 | Multiple values can be specified (separated by spaces or commas). This can |
|
988 | Multiple values can be specified (separated by spaces or commas). This can | |
989 | be used to define both old and new fingerprints while a host transitions |
|
989 | be used to define both old and new fingerprints while a host transitions | |
990 | to a new certificate. |
|
990 | to a new certificate. | |
991 |
|
991 | |||
992 | The CA chain and web.cacerts is not used for servers with a fingerprint. |
|
992 | The CA chain and web.cacerts is not used for servers with a fingerprint. | |
993 |
|
993 | |||
994 | For example:: |
|
994 | For example:: | |
995 |
|
995 | |||
996 | [hostfingerprints] |
|
996 | [hostfingerprints] | |
997 | hg.intevation.de = fc:e2:8d:d9:51:cd:cb:c1:4d:18:6b:b7:44:8d:49:72:57:e6:cd:33 |
|
997 | hg.intevation.de = fc:e2:8d:d9:51:cd:cb:c1:4d:18:6b:b7:44:8d:49:72:57:e6:cd:33 | |
998 | hg.intevation.org = fc:e2:8d:d9:51:cd:cb:c1:4d:18:6b:b7:44:8d:49:72:57:e6:cd:33 |
|
998 | hg.intevation.org = fc:e2:8d:d9:51:cd:cb:c1:4d:18:6b:b7:44:8d:49:72:57:e6:cd:33 | |
999 |
|
999 | |||
1000 | ``hostsecurity`` |
|
1000 | ``hostsecurity`` | |
1001 | ---------------- |
|
1001 | ---------------- | |
1002 |
|
1002 | |||
1003 | Used to specify per-host security settings. |
|
1003 | Used to specify per-host security settings. | |
1004 |
|
1004 | |||
1005 | Options in this section have the form ``hostname``:``setting``. This allows |
|
1005 | Options in this section have the form ``hostname``:``setting``. This allows | |
1006 | multiple settings to be defined on a per-host basis. |
|
1006 | multiple settings to be defined on a per-host basis. | |
1007 |
|
1007 | |||
1008 | The following per-host settings can be defined. |
|
1008 | The following per-host settings can be defined. | |
1009 |
|
1009 | |||
1010 | ``fingerprints`` |
|
1010 | ``fingerprints`` | |
1011 | A list of hashes of the DER encoded peer/remote certificate. Values have |
|
1011 | A list of hashes of the DER encoded peer/remote certificate. Values have | |
1012 | the form ``algorithm``:``fingerprint``. e.g. |
|
1012 | the form ``algorithm``:``fingerprint``. e.g. | |
1013 | ``sha256:c3ab8ff13720e8ad9047dd39466b3c8974e592c2fa383d4a3960714caef0c4f2``. |
|
1013 | ``sha256:c3ab8ff13720e8ad9047dd39466b3c8974e592c2fa383d4a3960714caef0c4f2``. | |
1014 |
|
1014 | |||
1015 | The following algorithms/prefixes are supported: ``sha1``, ``sha256``, |
|
1015 | The following algorithms/prefixes are supported: ``sha1``, ``sha256``, | |
1016 | ``sha512``. |
|
1016 | ``sha512``. | |
1017 |
|
1017 | |||
1018 | Use of ``sha256`` or ``sha512`` is preferred. |
|
1018 | Use of ``sha256`` or ``sha512`` is preferred. | |
1019 |
|
1019 | |||
1020 | If a fingerprint is specified, the CA chain is not validated for this |
|
1020 | If a fingerprint is specified, the CA chain is not validated for this | |
1021 | host and Mercurial will require the remote certificate to match one |
|
1021 | host and Mercurial will require the remote certificate to match one | |
1022 | of the fingerprints specified. This means if the server updates its |
|
1022 | of the fingerprints specified. This means if the server updates its | |
1023 | certificate, Mercurial will abort until a new fingerprint is defined. |
|
1023 | certificate, Mercurial will abort until a new fingerprint is defined. | |
1024 | This can provide stronger security than traditional CA-based validation |
|
1024 | This can provide stronger security than traditional CA-based validation | |
1025 | at the expense of convenience. |
|
1025 | at the expense of convenience. | |
1026 |
|
1026 | |||
1027 | This option takes precedence over ``verifycertsfile``. |
|
1027 | This option takes precedence over ``verifycertsfile``. | |
1028 |
|
1028 | |||
1029 | ``verifycertsfile`` |
|
1029 | ``verifycertsfile`` | |
1030 | Path to file a containing a list of PEM encoded certificates used to |
|
1030 | Path to file a containing a list of PEM encoded certificates used to | |
1031 | verify the server certificate. Environment variables and ``~user`` |
|
1031 | verify the server certificate. Environment variables and ``~user`` | |
1032 | constructs are expanded in the filename. |
|
1032 | constructs are expanded in the filename. | |
1033 |
|
1033 | |||
1034 | The server certificate or the certificate's certificate authority (CA) |
|
1034 | The server certificate or the certificate's certificate authority (CA) | |
1035 | must match a certificate from this file or certificate verification |
|
1035 | must match a certificate from this file or certificate verification | |
1036 | will fail and connections to the server will be refused. |
|
1036 | will fail and connections to the server will be refused. | |
1037 |
|
1037 | |||
1038 | If defined, only certificates provided by this file will be used: |
|
1038 | If defined, only certificates provided by this file will be used: | |
1039 | ``web.cacerts`` and any system/default certificates will not be |
|
1039 | ``web.cacerts`` and any system/default certificates will not be | |
1040 | used. |
|
1040 | used. | |
1041 |
|
1041 | |||
1042 | This option has no effect if the per-host ``fingerprints`` option |
|
1042 | This option has no effect if the per-host ``fingerprints`` option | |
1043 | is set. |
|
1043 | is set. | |
1044 |
|
1044 | |||
1045 | The format of the file is as follows: |
|
1045 | The format of the file is as follows: | |
1046 |
|
1046 | |||
1047 | -----BEGIN CERTIFICATE----- |
|
1047 | -----BEGIN CERTIFICATE----- | |
1048 | ... (certificate in base64 PEM encoding) ... |
|
1048 | ... (certificate in base64 PEM encoding) ... | |
1049 | -----END CERTIFICATE----- |
|
1049 | -----END CERTIFICATE----- | |
1050 | -----BEGIN CERTIFICATE----- |
|
1050 | -----BEGIN CERTIFICATE----- | |
1051 | ... (certificate in base64 PEM encoding) ... |
|
1051 | ... (certificate in base64 PEM encoding) ... | |
1052 | -----END CERTIFICATE----- |
|
1052 | -----END CERTIFICATE----- | |
1053 |
|
1053 | |||
1054 | For example:: |
|
1054 | For example:: | |
1055 |
|
1055 | |||
1056 | [hostsecurity] |
|
1056 | [hostsecurity] | |
1057 | hg.example.com:fingerprints = sha256:c3ab8ff13720e8ad9047dd39466b3c8974e592c2fa383d4a3960714caef0c4f2 |
|
1057 | hg.example.com:fingerprints = sha256:c3ab8ff13720e8ad9047dd39466b3c8974e592c2fa383d4a3960714caef0c4f2 | |
1058 | hg2.example.com:fingerprints = sha1:914f1aff87249c09b6859b88b1906d30756491ca, sha1:fc:e2:8d:d9:51:cd:cb:c1:4d:18:6b:b7:44:8d:49:72:57:e6:cd:33 |
|
1058 | hg2.example.com:fingerprints = sha1:914f1aff87249c09b6859b88b1906d30756491ca, sha1:fc:e2:8d:d9:51:cd:cb:c1:4d:18:6b:b7:44:8d:49:72:57:e6:cd:33 | |
1059 | foo.example.com:verifycertsfile = /etc/ssl/trusted-ca-certs.pem |
|
1059 | foo.example.com:verifycertsfile = /etc/ssl/trusted-ca-certs.pem | |
1060 |
|
1060 | |||
1061 | ``http_proxy`` |
|
1061 | ``http_proxy`` | |
1062 | -------------- |
|
1062 | -------------- | |
1063 |
|
1063 | |||
1064 | Used to access web-based Mercurial repositories through a HTTP |
|
1064 | Used to access web-based Mercurial repositories through a HTTP | |
1065 | proxy. |
|
1065 | proxy. | |
1066 |
|
1066 | |||
1067 | ``host`` |
|
1067 | ``host`` | |
1068 | Host name and (optional) port of the proxy server, for example |
|
1068 | Host name and (optional) port of the proxy server, for example | |
1069 | "myproxy:8000". |
|
1069 | "myproxy:8000". | |
1070 |
|
1070 | |||
1071 | ``no`` |
|
1071 | ``no`` | |
1072 | Optional. Comma-separated list of host names that should bypass |
|
1072 | Optional. Comma-separated list of host names that should bypass | |
1073 | the proxy. |
|
1073 | the proxy. | |
1074 |
|
1074 | |||
1075 | ``passwd`` |
|
1075 | ``passwd`` | |
1076 | Optional. Password to authenticate with at the proxy server. |
|
1076 | Optional. Password to authenticate with at the proxy server. | |
1077 |
|
1077 | |||
1078 | ``user`` |
|
1078 | ``user`` | |
1079 | Optional. User name to authenticate with at the proxy server. |
|
1079 | Optional. User name to authenticate with at the proxy server. | |
1080 |
|
1080 | |||
1081 | ``always`` |
|
1081 | ``always`` | |
1082 | Optional. Always use the proxy, even for localhost and any entries |
|
1082 | Optional. Always use the proxy, even for localhost and any entries | |
1083 | in ``http_proxy.no``. (default: False) |
|
1083 | in ``http_proxy.no``. (default: False) | |
1084 |
|
1084 | |||
1085 | ``merge`` |
|
1085 | ``merge`` | |
1086 | --------- |
|
1086 | --------- | |
1087 |
|
1087 | |||
1088 | This section specifies behavior during merges and updates. |
|
1088 | This section specifies behavior during merges and updates. | |
1089 |
|
1089 | |||
1090 | ``checkignored`` |
|
1090 | ``checkignored`` | |
1091 | Controls behavior when an ignored file on disk has the same name as a tracked |
|
1091 | Controls behavior when an ignored file on disk has the same name as a tracked | |
1092 | file in the changeset being merged or updated to, and has different |
|
1092 | file in the changeset being merged or updated to, and has different | |
1093 | contents. Options are ``abort``, ``warn`` and ``ignore``. With ``abort``, |
|
1093 | contents. Options are ``abort``, ``warn`` and ``ignore``. With ``abort``, | |
1094 | abort on such files. With ``warn``, warn on such files and back them up as |
|
1094 | abort on such files. With ``warn``, warn on such files and back them up as | |
1095 | ``.orig``. With ``ignore``, don't print a warning and back them up as |
|
1095 | ``.orig``. With ``ignore``, don't print a warning and back them up as | |
1096 | ``.orig``. (default: ``abort``) |
|
1096 | ``.orig``. (default: ``abort``) | |
1097 |
|
1097 | |||
1098 | ``checkunknown`` |
|
1098 | ``checkunknown`` | |
1099 | Controls behavior when an unknown file that isn't ignored has the same name |
|
1099 | Controls behavior when an unknown file that isn't ignored has the same name | |
1100 | as a tracked file in the changeset being merged or updated to, and has |
|
1100 | as a tracked file in the changeset being merged or updated to, and has | |
1101 | different contents. Similar to ``merge.checkignored``, except for files that |
|
1101 | different contents. Similar to ``merge.checkignored``, except for files that | |
1102 | are not ignored. (default: ``abort``) |
|
1102 | are not ignored. (default: ``abort``) | |
1103 |
|
1103 | |||
1104 | ``merge-patterns`` |
|
1104 | ``merge-patterns`` | |
1105 | ------------------ |
|
1105 | ------------------ | |
1106 |
|
1106 | |||
1107 | This section specifies merge tools to associate with particular file |
|
1107 | This section specifies merge tools to associate with particular file | |
1108 | patterns. Tools matched here will take precedence over the default |
|
1108 | patterns. Tools matched here will take precedence over the default | |
1109 | merge tool. Patterns are globs by default, rooted at the repository |
|
1109 | merge tool. Patterns are globs by default, rooted at the repository | |
1110 | root. |
|
1110 | root. | |
1111 |
|
1111 | |||
1112 | Example:: |
|
1112 | Example:: | |
1113 |
|
1113 | |||
1114 | [merge-patterns] |
|
1114 | [merge-patterns] | |
1115 | **.c = kdiff3 |
|
1115 | **.c = kdiff3 | |
1116 | **.jpg = myimgmerge |
|
1116 | **.jpg = myimgmerge | |
1117 |
|
1117 | |||
1118 | ``merge-tools`` |
|
1118 | ``merge-tools`` | |
1119 | --------------- |
|
1119 | --------------- | |
1120 |
|
1120 | |||
1121 | This section configures external merge tools to use for file-level |
|
1121 | This section configures external merge tools to use for file-level | |
1122 | merges. This section has likely been preconfigured at install time. |
|
1122 | merges. This section has likely been preconfigured at install time. | |
1123 | Use :hg:`config merge-tools` to check the existing configuration. |
|
1123 | Use :hg:`config merge-tools` to check the existing configuration. | |
1124 | Also see :hg:`help merge-tools` for more details. |
|
1124 | Also see :hg:`help merge-tools` for more details. | |
1125 |
|
1125 | |||
1126 | Example ``~/.hgrc``:: |
|
1126 | Example ``~/.hgrc``:: | |
1127 |
|
1127 | |||
1128 | [merge-tools] |
|
1128 | [merge-tools] | |
1129 | # Override stock tool location |
|
1129 | # Override stock tool location | |
1130 | kdiff3.executable = ~/bin/kdiff3 |
|
1130 | kdiff3.executable = ~/bin/kdiff3 | |
1131 | # Specify command line |
|
1131 | # Specify command line | |
1132 | kdiff3.args = $base $local $other -o $output |
|
1132 | kdiff3.args = $base $local $other -o $output | |
1133 | # Give higher priority |
|
1133 | # Give higher priority | |
1134 | kdiff3.priority = 1 |
|
1134 | kdiff3.priority = 1 | |
1135 |
|
1135 | |||
1136 | # Changing the priority of preconfigured tool |
|
1136 | # Changing the priority of preconfigured tool | |
1137 | meld.priority = 0 |
|
1137 | meld.priority = 0 | |
1138 |
|
1138 | |||
1139 | # Disable a preconfigured tool |
|
1139 | # Disable a preconfigured tool | |
1140 | vimdiff.disabled = yes |
|
1140 | vimdiff.disabled = yes | |
1141 |
|
1141 | |||
1142 | # Define new tool |
|
1142 | # Define new tool | |
1143 | myHtmlTool.args = -m $local $other $base $output |
|
1143 | myHtmlTool.args = -m $local $other $base $output | |
1144 | myHtmlTool.regkey = Software\FooSoftware\HtmlMerge |
|
1144 | myHtmlTool.regkey = Software\FooSoftware\HtmlMerge | |
1145 | myHtmlTool.priority = 1 |
|
1145 | myHtmlTool.priority = 1 | |
1146 |
|
1146 | |||
1147 | Supported arguments: |
|
1147 | Supported arguments: | |
1148 |
|
1148 | |||
1149 | ``priority`` |
|
1149 | ``priority`` | |
1150 | The priority in which to evaluate this tool. |
|
1150 | The priority in which to evaluate this tool. | |
1151 | (default: 0) |
|
1151 | (default: 0) | |
1152 |
|
1152 | |||
1153 | ``executable`` |
|
1153 | ``executable`` | |
1154 | Either just the name of the executable or its pathname. |
|
1154 | Either just the name of the executable or its pathname. | |
1155 |
|
1155 | |||
1156 | .. container:: windows |
|
1156 | .. container:: windows | |
1157 |
|
1157 | |||
1158 | On Windows, the path can use environment variables with ${ProgramFiles} |
|
1158 | On Windows, the path can use environment variables with ${ProgramFiles} | |
1159 | syntax. |
|
1159 | syntax. | |
1160 |
|
1160 | |||
1161 | (default: the tool name) |
|
1161 | (default: the tool name) | |
1162 |
|
1162 | |||
1163 | ``args`` |
|
1163 | ``args`` | |
1164 | The arguments to pass to the tool executable. You can refer to the |
|
1164 | The arguments to pass to the tool executable. You can refer to the | |
1165 | files being merged as well as the output file through these |
|
1165 | files being merged as well as the output file through these | |
1166 | variables: ``$base``, ``$local``, ``$other``, ``$output``. The meaning |
|
1166 | variables: ``$base``, ``$local``, ``$other``, ``$output``. The meaning | |
1167 | of ``$local`` and ``$other`` can vary depending on which action is being |
|
1167 | of ``$local`` and ``$other`` can vary depending on which action is being | |
1168 | performed. During and update or merge, ``$local`` represents the original |
|
1168 | performed. During and update or merge, ``$local`` represents the original | |
1169 | state of the file, while ``$other`` represents the commit you are updating |
|
1169 | state of the file, while ``$other`` represents the commit you are updating | |
1170 | to or the commit you are merging with. During a rebase ``$local`` |
|
1170 | to or the commit you are merging with. During a rebase ``$local`` | |
1171 | represents the destination of the rebase, and ``$other`` represents the |
|
1171 | represents the destination of the rebase, and ``$other`` represents the | |
1172 | commit being rebased. |
|
1172 | commit being rebased. | |
1173 | (default: ``$local $base $other``) |
|
1173 | (default: ``$local $base $other``) | |
1174 |
|
1174 | |||
1175 | ``premerge`` |
|
1175 | ``premerge`` | |
1176 | Attempt to run internal non-interactive 3-way merge tool before |
|
1176 | Attempt to run internal non-interactive 3-way merge tool before | |
1177 | launching external tool. Options are ``true``, ``false``, ``keep`` or |
|
1177 | launching external tool. Options are ``true``, ``false``, ``keep`` or | |
1178 | ``keep-merge3``. The ``keep`` option will leave markers in the file if the |
|
1178 | ``keep-merge3``. The ``keep`` option will leave markers in the file if the | |
1179 | premerge fails. The ``keep-merge3`` will do the same but include information |
|
1179 | premerge fails. The ``keep-merge3`` will do the same but include information | |
1180 | about the base of the merge in the marker (see internal :merge3 in |
|
1180 | about the base of the merge in the marker (see internal :merge3 in | |
1181 | :hg:`help merge-tools`). |
|
1181 | :hg:`help merge-tools`). | |
1182 | (default: True) |
|
1182 | (default: True) | |
1183 |
|
1183 | |||
1184 | ``binary`` |
|
1184 | ``binary`` | |
1185 | This tool can merge binary files. (default: False, unless tool |
|
1185 | This tool can merge binary files. (default: False, unless tool | |
1186 | was selected by file pattern match) |
|
1186 | was selected by file pattern match) | |
1187 |
|
1187 | |||
1188 | ``symlink`` |
|
1188 | ``symlink`` | |
1189 | This tool can merge symlinks. (default: False) |
|
1189 | This tool can merge symlinks. (default: False) | |
1190 |
|
1190 | |||
1191 | ``check`` |
|
1191 | ``check`` | |
1192 | A list of merge success-checking options: |
|
1192 | A list of merge success-checking options: | |
1193 |
|
1193 | |||
1194 | ``changed`` |
|
1194 | ``changed`` | |
1195 | Ask whether merge was successful when the merged file shows no changes. |
|
1195 | Ask whether merge was successful when the merged file shows no changes. | |
1196 | ``conflicts`` |
|
1196 | ``conflicts`` | |
1197 | Check whether there are conflicts even though the tool reported success. |
|
1197 | Check whether there are conflicts even though the tool reported success. | |
1198 | ``prompt`` |
|
1198 | ``prompt`` | |
1199 | Always prompt for merge success, regardless of success reported by tool. |
|
1199 | Always prompt for merge success, regardless of success reported by tool. | |
1200 |
|
1200 | |||
1201 | ``fixeol`` |
|
1201 | ``fixeol`` | |
1202 | Attempt to fix up EOL changes caused by the merge tool. |
|
1202 | Attempt to fix up EOL changes caused by the merge tool. | |
1203 | (default: False) |
|
1203 | (default: False) | |
1204 |
|
1204 | |||
1205 | ``gui`` |
|
1205 | ``gui`` | |
1206 | This tool requires a graphical interface to run. (default: False) |
|
1206 | This tool requires a graphical interface to run. (default: False) | |
1207 |
|
1207 | |||
1208 | .. container:: windows |
|
1208 | .. container:: windows | |
1209 |
|
1209 | |||
1210 | ``regkey`` |
|
1210 | ``regkey`` | |
1211 | Windows registry key which describes install location of this |
|
1211 | Windows registry key which describes install location of this | |
1212 | tool. Mercurial will search for this key first under |
|
1212 | tool. Mercurial will search for this key first under | |
1213 | ``HKEY_CURRENT_USER`` and then under ``HKEY_LOCAL_MACHINE``. |
|
1213 | ``HKEY_CURRENT_USER`` and then under ``HKEY_LOCAL_MACHINE``. | |
1214 | (default: None) |
|
1214 | (default: None) | |
1215 |
|
1215 | |||
1216 | ``regkeyalt`` |
|
1216 | ``regkeyalt`` | |
1217 | An alternate Windows registry key to try if the first key is not |
|
1217 | An alternate Windows registry key to try if the first key is not | |
1218 | found. The alternate key uses the same ``regname`` and ``regappend`` |
|
1218 | found. The alternate key uses the same ``regname`` and ``regappend`` | |
1219 | semantics of the primary key. The most common use for this key |
|
1219 | semantics of the primary key. The most common use for this key | |
1220 | is to search for 32bit applications on 64bit operating systems. |
|
1220 | is to search for 32bit applications on 64bit operating systems. | |
1221 | (default: None) |
|
1221 | (default: None) | |
1222 |
|
1222 | |||
1223 | ``regname`` |
|
1223 | ``regname`` | |
1224 | Name of value to read from specified registry key. |
|
1224 | Name of value to read from specified registry key. | |
1225 | (default: the unnamed (default) value) |
|
1225 | (default: the unnamed (default) value) | |
1226 |
|
1226 | |||
1227 | ``regappend`` |
|
1227 | ``regappend`` | |
1228 | String to append to the value read from the registry, typically |
|
1228 | String to append to the value read from the registry, typically | |
1229 | the executable name of the tool. |
|
1229 | the executable name of the tool. | |
1230 | (default: None) |
|
1230 | (default: None) | |
1231 |
|
1231 | |||
1232 |
|
1232 | |||
1233 | ``patch`` |
|
1233 | ``patch`` | |
1234 | --------- |
|
1234 | --------- | |
1235 |
|
1235 | |||
1236 | Settings used when applying patches, for instance through the 'import' |
|
1236 | Settings used when applying patches, for instance through the 'import' | |
1237 | command or with Mercurial Queues extension. |
|
1237 | command or with Mercurial Queues extension. | |
1238 |
|
1238 | |||
1239 | ``eol`` |
|
1239 | ``eol`` | |
1240 | When set to 'strict' patch content and patched files end of lines |
|
1240 | When set to 'strict' patch content and patched files end of lines | |
1241 | are preserved. When set to ``lf`` or ``crlf``, both files end of |
|
1241 | are preserved. When set to ``lf`` or ``crlf``, both files end of | |
1242 | lines are ignored when patching and the result line endings are |
|
1242 | lines are ignored when patching and the result line endings are | |
1243 | normalized to either LF (Unix) or CRLF (Windows). When set to |
|
1243 | normalized to either LF (Unix) or CRLF (Windows). When set to | |
1244 | ``auto``, end of lines are again ignored while patching but line |
|
1244 | ``auto``, end of lines are again ignored while patching but line | |
1245 | endings in patched files are normalized to their original setting |
|
1245 | endings in patched files are normalized to their original setting | |
1246 | on a per-file basis. If target file does not exist or has no end |
|
1246 | on a per-file basis. If target file does not exist or has no end | |
1247 | of line, patch line endings are preserved. |
|
1247 | of line, patch line endings are preserved. | |
1248 | (default: strict) |
|
1248 | (default: strict) | |
1249 |
|
1249 | |||
1250 | ``fuzz`` |
|
1250 | ``fuzz`` | |
1251 | The number of lines of 'fuzz' to allow when applying patches. This |
|
1251 | The number of lines of 'fuzz' to allow when applying patches. This | |
1252 | controls how much context the patcher is allowed to ignore when |
|
1252 | controls how much context the patcher is allowed to ignore when | |
1253 | trying to apply a patch. |
|
1253 | trying to apply a patch. | |
1254 | (default: 2) |
|
1254 | (default: 2) | |
1255 |
|
1255 | |||
1256 | ``paths`` |
|
1256 | ``paths`` | |
1257 | --------- |
|
1257 | --------- | |
1258 |
|
1258 | |||
1259 | Assigns symbolic names and behavior to repositories. |
|
1259 | Assigns symbolic names and behavior to repositories. | |
1260 |
|
1260 | |||
1261 | Options are symbolic names defining the URL or directory that is the |
|
1261 | Options are symbolic names defining the URL or directory that is the | |
1262 | location of the repository. Example:: |
|
1262 | location of the repository. Example:: | |
1263 |
|
1263 | |||
1264 | [paths] |
|
1264 | [paths] | |
1265 | my_server = https://example.com/my_repo |
|
1265 | my_server = https://example.com/my_repo | |
1266 | local_path = /home/me/repo |
|
1266 | local_path = /home/me/repo | |
1267 |
|
1267 | |||
1268 | These symbolic names can be used from the command line. To pull |
|
1268 | These symbolic names can be used from the command line. To pull | |
1269 | from ``my_server``: :hg:`pull my_server`. To push to ``local_path``: |
|
1269 | from ``my_server``: :hg:`pull my_server`. To push to ``local_path``: | |
1270 | :hg:`push local_path`. |
|
1270 | :hg:`push local_path`. | |
1271 |
|
1271 | |||
1272 | Options containing colons (``:``) denote sub-options that can influence |
|
1272 | Options containing colons (``:``) denote sub-options that can influence | |
1273 | behavior for that specific path. Example:: |
|
1273 | behavior for that specific path. Example:: | |
1274 |
|
1274 | |||
1275 | [paths] |
|
1275 | [paths] | |
1276 | my_server = https://example.com/my_path |
|
1276 | my_server = https://example.com/my_path | |
1277 | my_server:pushurl = ssh://example.com/my_path |
|
1277 | my_server:pushurl = ssh://example.com/my_path | |
1278 |
|
1278 | |||
1279 | The following sub-options can be defined: |
|
1279 | The following sub-options can be defined: | |
1280 |
|
1280 | |||
1281 | ``pushurl`` |
|
1281 | ``pushurl`` | |
1282 | The URL to use for push operations. If not defined, the location |
|
1282 | The URL to use for push operations. If not defined, the location | |
1283 | defined by the path's main entry is used. |
|
1283 | defined by the path's main entry is used. | |
1284 |
|
1284 | |||
1285 | ``pushrev`` |
|
1285 | ``pushrev`` | |
1286 | A revset defining which revisions to push by default. |
|
1286 | A revset defining which revisions to push by default. | |
1287 |
|
1287 | |||
1288 | When :hg:`push` is executed without a ``-r`` argument, the revset |
|
1288 | When :hg:`push` is executed without a ``-r`` argument, the revset | |
1289 | defined by this sub-option is evaluated to determine what to push. |
|
1289 | defined by this sub-option is evaluated to determine what to push. | |
1290 |
|
1290 | |||
1291 | For example, a value of ``.`` will push the working directory's |
|
1291 | For example, a value of ``.`` will push the working directory's | |
1292 | revision by default. |
|
1292 | revision by default. | |
1293 |
|
1293 | |||
1294 | Revsets specifying bookmarks will not result in the bookmark being |
|
1294 | Revsets specifying bookmarks will not result in the bookmark being | |
1295 | pushed. |
|
1295 | pushed. | |
1296 |
|
1296 | |||
1297 | The following special named paths exist: |
|
1297 | The following special named paths exist: | |
1298 |
|
1298 | |||
1299 | ``default`` |
|
1299 | ``default`` | |
1300 | The URL or directory to use when no source or remote is specified. |
|
1300 | The URL or directory to use when no source or remote is specified. | |
1301 |
|
1301 | |||
1302 | :hg:`clone` will automatically define this path to the location the |
|
1302 | :hg:`clone` will automatically define this path to the location the | |
1303 | repository was cloned from. |
|
1303 | repository was cloned from. | |
1304 |
|
1304 | |||
1305 | ``default-push`` |
|
1305 | ``default-push`` | |
1306 | (deprecated) The URL or directory for the default :hg:`push` location. |
|
1306 | (deprecated) The URL or directory for the default :hg:`push` location. | |
1307 | ``default:pushurl`` should be used instead. |
|
1307 | ``default:pushurl`` should be used instead. | |
1308 |
|
1308 | |||
1309 | ``phases`` |
|
1309 | ``phases`` | |
1310 | ---------- |
|
1310 | ---------- | |
1311 |
|
1311 | |||
1312 | Specifies default handling of phases. See :hg:`help phases` for more |
|
1312 | Specifies default handling of phases. See :hg:`help phases` for more | |
1313 | information about working with phases. |
|
1313 | information about working with phases. | |
1314 |
|
1314 | |||
1315 | ``publish`` |
|
1315 | ``publish`` | |
1316 | Controls draft phase behavior when working as a server. When true, |
|
1316 | Controls draft phase behavior when working as a server. When true, | |
1317 | pushed changesets are set to public in both client and server and |
|
1317 | pushed changesets are set to public in both client and server and | |
1318 | pulled or cloned changesets are set to public in the client. |
|
1318 | pulled or cloned changesets are set to public in the client. | |
1319 | (default: True) |
|
1319 | (default: True) | |
1320 |
|
1320 | |||
1321 | ``new-commit`` |
|
1321 | ``new-commit`` | |
1322 | Phase of newly-created commits. |
|
1322 | Phase of newly-created commits. | |
1323 | (default: draft) |
|
1323 | (default: draft) | |
1324 |
|
1324 | |||
1325 | ``checksubrepos`` |
|
1325 | ``checksubrepos`` | |
1326 | Check the phase of the current revision of each subrepository. Allowed |
|
1326 | Check the phase of the current revision of each subrepository. Allowed | |
1327 | values are "ignore", "follow" and "abort". For settings other than |
|
1327 | values are "ignore", "follow" and "abort". For settings other than | |
1328 | "ignore", the phase of the current revision of each subrepository is |
|
1328 | "ignore", the phase of the current revision of each subrepository is | |
1329 | checked before committing the parent repository. If any of those phases is |
|
1329 | checked before committing the parent repository. If any of those phases is | |
1330 | greater than the phase of the parent repository (e.g. if a subrepo is in a |
|
1330 | greater than the phase of the parent repository (e.g. if a subrepo is in a | |
1331 | "secret" phase while the parent repo is in "draft" phase), the commit is |
|
1331 | "secret" phase while the parent repo is in "draft" phase), the commit is | |
1332 | either aborted (if checksubrepos is set to "abort") or the higher phase is |
|
1332 | either aborted (if checksubrepos is set to "abort") or the higher phase is | |
1333 | used for the parent repository commit (if set to "follow"). |
|
1333 | used for the parent repository commit (if set to "follow"). | |
1334 | (default: follow) |
|
1334 | (default: follow) | |
1335 |
|
1335 | |||
1336 |
|
1336 | |||
1337 | ``profiling`` |
|
1337 | ``profiling`` | |
1338 | ------------- |
|
1338 | ------------- | |
1339 |
|
1339 | |||
1340 | Specifies profiling type, format, and file output. Two profilers are |
|
1340 | Specifies profiling type, format, and file output. Two profilers are | |
1341 | supported: an instrumenting profiler (named ``ls``), and a sampling |
|
1341 | supported: an instrumenting profiler (named ``ls``), and a sampling | |
1342 | profiler (named ``stat``). |
|
1342 | profiler (named ``stat``). | |
1343 |
|
1343 | |||
1344 | In this section description, 'profiling data' stands for the raw data |
|
1344 | In this section description, 'profiling data' stands for the raw data | |
1345 | collected during profiling, while 'profiling report' stands for a |
|
1345 | collected during profiling, while 'profiling report' stands for a | |
1346 | statistical text report generated from the profiling data. The |
|
1346 | statistical text report generated from the profiling data. The | |
1347 | profiling is done using lsprof. |
|
1347 | profiling is done using lsprof. | |
1348 |
|
1348 | |||
1349 | ``type`` |
|
1349 | ``type`` | |
1350 | The type of profiler to use. |
|
1350 | The type of profiler to use. | |
1351 | (default: ls) |
|
1351 | (default: ls) | |
1352 |
|
1352 | |||
1353 | ``ls`` |
|
1353 | ``ls`` | |
1354 | Use Python's built-in instrumenting profiler. This profiler |
|
1354 | Use Python's built-in instrumenting profiler. This profiler | |
1355 | works on all platforms, but each line number it reports is the |
|
1355 | works on all platforms, but each line number it reports is the | |
1356 | first line of a function. This restriction makes it difficult to |
|
1356 | first line of a function. This restriction makes it difficult to | |
1357 | identify the expensive parts of a non-trivial function. |
|
1357 | identify the expensive parts of a non-trivial function. | |
1358 | ``stat`` |
|
1358 | ``stat`` | |
1359 | Use a third-party statistical profiler, statprof. This profiler |
|
1359 | Use a third-party statistical profiler, statprof. This profiler | |
1360 | currently runs only on Unix systems, and is most useful for |
|
1360 | currently runs only on Unix systems, and is most useful for | |
1361 | profiling commands that run for longer than about 0.1 seconds. |
|
1361 | profiling commands that run for longer than about 0.1 seconds. | |
1362 |
|
1362 | |||
1363 | ``format`` |
|
1363 | ``format`` | |
1364 | Profiling format. Specific to the ``ls`` instrumenting profiler. |
|
1364 | Profiling format. Specific to the ``ls`` instrumenting profiler. | |
1365 | (default: text) |
|
1365 | (default: text) | |
1366 |
|
1366 | |||
1367 | ``text`` |
|
1367 | ``text`` | |
1368 | Generate a profiling report. When saving to a file, it should be |
|
1368 | Generate a profiling report. When saving to a file, it should be | |
1369 | noted that only the report is saved, and the profiling data is |
|
1369 | noted that only the report is saved, and the profiling data is | |
1370 | not kept. |
|
1370 | not kept. | |
1371 | ``kcachegrind`` |
|
1371 | ``kcachegrind`` | |
1372 | Format profiling data for kcachegrind use: when saving to a |
|
1372 | Format profiling data for kcachegrind use: when saving to a | |
1373 | file, the generated file can directly be loaded into |
|
1373 | file, the generated file can directly be loaded into | |
1374 | kcachegrind. |
|
1374 | kcachegrind. | |
1375 |
|
1375 | |||
1376 | ``frequency`` |
|
1376 | ``frequency`` | |
1377 | Sampling frequency. Specific to the ``stat`` sampling profiler. |
|
1377 | Sampling frequency. Specific to the ``stat`` sampling profiler. | |
1378 | (default: 1000) |
|
1378 | (default: 1000) | |
1379 |
|
1379 | |||
1380 | ``output`` |
|
1380 | ``output`` | |
1381 | File path where profiling data or report should be saved. If the |
|
1381 | File path where profiling data or report should be saved. If the | |
1382 | file exists, it is replaced. (default: None, data is printed on |
|
1382 | file exists, it is replaced. (default: None, data is printed on | |
1383 | stderr) |
|
1383 | stderr) | |
1384 |
|
1384 | |||
1385 | ``sort`` |
|
1385 | ``sort`` | |
1386 | Sort field. Specific to the ``ls`` instrumenting profiler. |
|
1386 | Sort field. Specific to the ``ls`` instrumenting profiler. | |
1387 | One of ``callcount``, ``reccallcount``, ``totaltime`` and |
|
1387 | One of ``callcount``, ``reccallcount``, ``totaltime`` and | |
1388 | ``inlinetime``. |
|
1388 | ``inlinetime``. | |
1389 | (default: inlinetime) |
|
1389 | (default: inlinetime) | |
1390 |
|
1390 | |||
1391 | ``limit`` |
|
1391 | ``limit`` | |
1392 | Number of lines to show. Specific to the ``ls`` instrumenting profiler. |
|
1392 | Number of lines to show. Specific to the ``ls`` instrumenting profiler. | |
1393 | (default: 30) |
|
1393 | (default: 30) | |
1394 |
|
1394 | |||
1395 | ``nested`` |
|
1395 | ``nested`` | |
1396 | Show at most this number of lines of drill-down info after each main entry. |
|
1396 | Show at most this number of lines of drill-down info after each main entry. | |
1397 | This can help explain the difference between Total and Inline. |
|
1397 | This can help explain the difference between Total and Inline. | |
1398 | Specific to the ``ls`` instrumenting profiler. |
|
1398 | Specific to the ``ls`` instrumenting profiler. | |
1399 | (default: 5) |
|
1399 | (default: 5) | |
1400 |
|
1400 | |||
1401 | ``progress`` |
|
1401 | ``progress`` | |
1402 | ------------ |
|
1402 | ------------ | |
1403 |
|
1403 | |||
1404 | Mercurial commands can draw progress bars that are as informative as |
|
1404 | Mercurial commands can draw progress bars that are as informative as | |
1405 | possible. Some progress bars only offer indeterminate information, while others |
|
1405 | possible. Some progress bars only offer indeterminate information, while others | |
1406 | have a definite end point. |
|
1406 | have a definite end point. | |
1407 |
|
1407 | |||
1408 | ``delay`` |
|
1408 | ``delay`` | |
1409 | Number of seconds (float) before showing the progress bar. (default: 3) |
|
1409 | Number of seconds (float) before showing the progress bar. (default: 3) | |
1410 |
|
1410 | |||
1411 | ``changedelay`` |
|
1411 | ``changedelay`` | |
1412 | Minimum delay before showing a new topic. When set to less than 3 * refresh, |
|
1412 | Minimum delay before showing a new topic. When set to less than 3 * refresh, | |
1413 | that value will be used instead. (default: 1) |
|
1413 | that value will be used instead. (default: 1) | |
1414 |
|
1414 | |||
1415 | ``refresh`` |
|
1415 | ``refresh`` | |
1416 | Time in seconds between refreshes of the progress bar. (default: 0.1) |
|
1416 | Time in seconds between refreshes of the progress bar. (default: 0.1) | |
1417 |
|
1417 | |||
1418 | ``format`` |
|
1418 | ``format`` | |
1419 | Format of the progress bar. |
|
1419 | Format of the progress bar. | |
1420 |
|
1420 | |||
1421 | Valid entries for the format field are ``topic``, ``bar``, ``number``, |
|
1421 | Valid entries for the format field are ``topic``, ``bar``, ``number``, | |
1422 | ``unit``, ``estimate``, ``speed``, and ``item``. ``item`` defaults to the |
|
1422 | ``unit``, ``estimate``, ``speed``, and ``item``. ``item`` defaults to the | |
1423 | last 20 characters of the item, but this can be changed by adding either |
|
1423 | last 20 characters of the item, but this can be changed by adding either | |
1424 | ``-<num>`` which would take the last num characters, or ``+<num>`` for the |
|
1424 | ``-<num>`` which would take the last num characters, or ``+<num>`` for the | |
1425 | first num characters. |
|
1425 | first num characters. | |
1426 |
|
1426 | |||
1427 | (default: topic bar number estimate) |
|
1427 | (default: topic bar number estimate) | |
1428 |
|
1428 | |||
1429 | ``width`` |
|
1429 | ``width`` | |
1430 | If set, the maximum width of the progress information (that is, min(width, |
|
1430 | If set, the maximum width of the progress information (that is, min(width, | |
1431 | term width) will be used). |
|
1431 | term width) will be used). | |
1432 |
|
1432 | |||
1433 | ``clear-complete`` |
|
1433 | ``clear-complete`` | |
1434 | Clear the progress bar after it's done. (default: True) |
|
1434 | Clear the progress bar after it's done. (default: True) | |
1435 |
|
1435 | |||
1436 | ``disable`` |
|
1436 | ``disable`` | |
1437 | If true, don't show a progress bar. |
|
1437 | If true, don't show a progress bar. | |
1438 |
|
1438 | |||
1439 | ``assume-tty`` |
|
1439 | ``assume-tty`` | |
1440 | If true, ALWAYS show a progress bar, unless disable is given. |
|
1440 | If true, ALWAYS show a progress bar, unless disable is given. | |
1441 |
|
1441 | |||
1442 | ``rebase`` |
|
1442 | ``rebase`` | |
1443 | ---------- |
|
1443 | ---------- | |
1444 |
|
1444 | |||
1445 | ``allowdivergence`` |
|
1445 | ``allowdivergence`` | |
1446 | Default to False, when True allow creating divergence when performing |
|
1446 | Default to False, when True allow creating divergence when performing | |
1447 | rebase of obsolete changesets. |
|
1447 | rebase of obsolete changesets. | |
1448 |
|
1448 | |||
1449 | ``revsetalias`` |
|
1449 | ``revsetalias`` | |
1450 | --------------- |
|
1450 | --------------- | |
1451 |
|
1451 | |||
1452 | Alias definitions for revsets. See :hg:`help revsets` for details. |
|
1452 | Alias definitions for revsets. See :hg:`help revsets` for details. | |
1453 |
|
1453 | |||
1454 | ``server`` |
|
1454 | ``server`` | |
1455 | ---------- |
|
1455 | ---------- | |
1456 |
|
1456 | |||
1457 | Controls generic server settings. |
|
1457 | Controls generic server settings. | |
1458 |
|
1458 | |||
1459 | ``uncompressed`` |
|
1459 | ``uncompressed`` | |
1460 | Whether to allow clients to clone a repository using the |
|
1460 | Whether to allow clients to clone a repository using the | |
1461 | uncompressed streaming protocol. This transfers about 40% more |
|
1461 | uncompressed streaming protocol. This transfers about 40% more | |
1462 | data than a regular clone, but uses less memory and CPU on both |
|
1462 | data than a regular clone, but uses less memory and CPU on both | |
1463 | server and client. Over a LAN (100 Mbps or better) or a very fast |
|
1463 | server and client. Over a LAN (100 Mbps or better) or a very fast | |
1464 | WAN, an uncompressed streaming clone is a lot faster (~10x) than a |
|
1464 | WAN, an uncompressed streaming clone is a lot faster (~10x) than a | |
1465 | regular clone. Over most WAN connections (anything slower than |
|
1465 | regular clone. Over most WAN connections (anything slower than | |
1466 | about 6 Mbps), uncompressed streaming is slower, because of the |
|
1466 | about 6 Mbps), uncompressed streaming is slower, because of the | |
1467 | extra data transfer overhead. This mode will also temporarily hold |
|
1467 | extra data transfer overhead. This mode will also temporarily hold | |
1468 | the write lock while determining what data to transfer. |
|
1468 | the write lock while determining what data to transfer. | |
1469 | (default: True) |
|
1469 | (default: True) | |
1470 |
|
1470 | |||
1471 | ``preferuncompressed`` |
|
1471 | ``preferuncompressed`` | |
1472 | When set, clients will try to use the uncompressed streaming |
|
1472 | When set, clients will try to use the uncompressed streaming | |
1473 | protocol. (default: False) |
|
1473 | protocol. (default: False) | |
1474 |
|
1474 | |||
1475 | ``validate`` |
|
1475 | ``validate`` | |
1476 | Whether to validate the completeness of pushed changesets by |
|
1476 | Whether to validate the completeness of pushed changesets by | |
1477 | checking that all new file revisions specified in manifests are |
|
1477 | checking that all new file revisions specified in manifests are | |
1478 | present. (default: False) |
|
1478 | present. (default: False) | |
1479 |
|
1479 | |||
1480 | ``maxhttpheaderlen`` |
|
1480 | ``maxhttpheaderlen`` | |
1481 | Instruct HTTP clients not to send request headers longer than this |
|
1481 | Instruct HTTP clients not to send request headers longer than this | |
1482 | many bytes. (default: 1024) |
|
1482 | many bytes. (default: 1024) | |
1483 |
|
1483 | |||
1484 | ``bundle1`` |
|
1484 | ``bundle1`` | |
1485 | Whether to allow clients to push and pull using the legacy bundle1 |
|
1485 | Whether to allow clients to push and pull using the legacy bundle1 | |
1486 | exchange format. (default: True) |
|
1486 | exchange format. (default: True) | |
1487 |
|
1487 | |||
1488 | ``bundle1gd`` |
|
1488 | ``bundle1gd`` | |
1489 | Like ``bundle1`` but only used if the repository is using the |
|
1489 | Like ``bundle1`` but only used if the repository is using the | |
1490 | *generaldelta* storage format. (default: True) |
|
1490 | *generaldelta* storage format. (default: True) | |
1491 |
|
1491 | |||
1492 | ``bundle1.push`` |
|
1492 | ``bundle1.push`` | |
1493 | Whether to allow clients to push using the legacy bundle1 exchange |
|
1493 | Whether to allow clients to push using the legacy bundle1 exchange | |
1494 | format. (default: True) |
|
1494 | format. (default: True) | |
1495 |
|
1495 | |||
1496 | ``bundle1gd.push`` |
|
1496 | ``bundle1gd.push`` | |
1497 | Like ``bundle1.push`` but only used if the repository is using the |
|
1497 | Like ``bundle1.push`` but only used if the repository is using the | |
1498 | *generaldelta* storage format. (default: True) |
|
1498 | *generaldelta* storage format. (default: True) | |
1499 |
|
1499 | |||
1500 | ``bundle1.pull`` |
|
1500 | ``bundle1.pull`` | |
1501 | Whether to allow clients to pull using the legacy bundle1 exchange |
|
1501 | Whether to allow clients to pull using the legacy bundle1 exchange | |
1502 | format. (default: True) |
|
1502 | format. (default: True) | |
1503 |
|
1503 | |||
1504 | ``bundle1gd.pull`` |
|
1504 | ``bundle1gd.pull`` | |
1505 | Like ``bundle1.pull`` but only used if the repository is using the |
|
1505 | Like ``bundle1.pull`` but only used if the repository is using the | |
1506 | *generaldelta* storage format. (default: True) |
|
1506 | *generaldelta* storage format. (default: True) | |
1507 |
|
1507 | |||
1508 | Large repositories using the *generaldelta* storage format should |
|
1508 | Large repositories using the *generaldelta* storage format should | |
1509 | consider setting this option because converting *generaldelta* |
|
1509 | consider setting this option because converting *generaldelta* | |
1510 | repositories to the exchange format required by the bundle1 data |
|
1510 | repositories to the exchange format required by the bundle1 data | |
1511 | format can consume a lot of CPU. |
|
1511 | format can consume a lot of CPU. | |
1512 |
|
1512 | |||
1513 | ``smtp`` |
|
1513 | ``smtp`` | |
1514 | -------- |
|
1514 | -------- | |
1515 |
|
1515 | |||
1516 | Configuration for extensions that need to send email messages. |
|
1516 | Configuration for extensions that need to send email messages. | |
1517 |
|
1517 | |||
1518 | ``host`` |
|
1518 | ``host`` | |
1519 | Host name of mail server, e.g. "mail.example.com". |
|
1519 | Host name of mail server, e.g. "mail.example.com". | |
1520 |
|
1520 | |||
1521 | ``port`` |
|
1521 | ``port`` | |
1522 | Optional. Port to connect to on mail server. (default: 465 if |
|
1522 | Optional. Port to connect to on mail server. (default: 465 if | |
1523 | ``tls`` is smtps; 25 otherwise) |
|
1523 | ``tls`` is smtps; 25 otherwise) | |
1524 |
|
1524 | |||
1525 | ``tls`` |
|
1525 | ``tls`` | |
1526 | Optional. Method to enable TLS when connecting to mail server: starttls, |
|
1526 | Optional. Method to enable TLS when connecting to mail server: starttls, | |
1527 | smtps or none. (default: none) |
|
1527 | smtps or none. (default: none) | |
1528 |
|
1528 | |||
1529 | ``username`` |
|
1529 | ``username`` | |
1530 | Optional. User name for authenticating with the SMTP server. |
|
1530 | Optional. User name for authenticating with the SMTP server. | |
1531 | (default: None) |
|
1531 | (default: None) | |
1532 |
|
1532 | |||
1533 | ``password`` |
|
1533 | ``password`` | |
1534 | Optional. Password for authenticating with the SMTP server. If not |
|
1534 | Optional. Password for authenticating with the SMTP server. If not | |
1535 | specified, interactive sessions will prompt the user for a |
|
1535 | specified, interactive sessions will prompt the user for a | |
1536 | password; non-interactive sessions will fail. (default: None) |
|
1536 | password; non-interactive sessions will fail. (default: None) | |
1537 |
|
1537 | |||
1538 | ``local_hostname`` |
|
1538 | ``local_hostname`` | |
1539 | Optional. The hostname that the sender can use to identify |
|
1539 | Optional. The hostname that the sender can use to identify | |
1540 | itself to the MTA. |
|
1540 | itself to the MTA. | |
1541 |
|
1541 | |||
1542 |
|
1542 | |||
1543 | ``subpaths`` |
|
1543 | ``subpaths`` | |
1544 | ------------ |
|
1544 | ------------ | |
1545 |
|
1545 | |||
1546 | Subrepository source URLs can go stale if a remote server changes name |
|
1546 | Subrepository source URLs can go stale if a remote server changes name | |
1547 | or becomes temporarily unavailable. This section lets you define |
|
1547 | or becomes temporarily unavailable. This section lets you define | |
1548 | rewrite rules of the form:: |
|
1548 | rewrite rules of the form:: | |
1549 |
|
1549 | |||
1550 | <pattern> = <replacement> |
|
1550 | <pattern> = <replacement> | |
1551 |
|
1551 | |||
1552 | where ``pattern`` is a regular expression matching a subrepository |
|
1552 | where ``pattern`` is a regular expression matching a subrepository | |
1553 | source URL and ``replacement`` is the replacement string used to |
|
1553 | source URL and ``replacement`` is the replacement string used to | |
1554 | rewrite it. Groups can be matched in ``pattern`` and referenced in |
|
1554 | rewrite it. Groups can be matched in ``pattern`` and referenced in | |
1555 | ``replacements``. For instance:: |
|
1555 | ``replacements``. For instance:: | |
1556 |
|
1556 | |||
1557 | http://server/(.*)-hg/ = http://hg.server/\1/ |
|
1557 | http://server/(.*)-hg/ = http://hg.server/\1/ | |
1558 |
|
1558 | |||
1559 | rewrites ``http://server/foo-hg/`` into ``http://hg.server/foo/``. |
|
1559 | rewrites ``http://server/foo-hg/`` into ``http://hg.server/foo/``. | |
1560 |
|
1560 | |||
1561 | Relative subrepository paths are first made absolute, and the |
|
1561 | Relative subrepository paths are first made absolute, and the | |
1562 | rewrite rules are then applied on the full (absolute) path. If ``pattern`` |
|
1562 | rewrite rules are then applied on the full (absolute) path. If ``pattern`` | |
1563 | doesn't match the full path, an attempt is made to apply it on the |
|
1563 | doesn't match the full path, an attempt is made to apply it on the | |
1564 | relative path alone. The rules are applied in definition order. |
|
1564 | relative path alone. The rules are applied in definition order. | |
1565 |
|
1565 | |||
1566 | ``templatealias`` |
|
1566 | ``templatealias`` | |
1567 | ----------------- |
|
1567 | ----------------- | |
1568 |
|
1568 | |||
1569 | Alias definitions for templates. See :hg:`help templates` for details. |
|
1569 | Alias definitions for templates. See :hg:`help templates` for details. | |
1570 |
|
1570 | |||
1571 | ``trusted`` |
|
1571 | ``trusted`` | |
1572 | ----------- |
|
1572 | ----------- | |
1573 |
|
1573 | |||
1574 | Mercurial will not use the settings in the |
|
1574 | Mercurial will not use the settings in the | |
1575 | ``.hg/hgrc`` file from a repository if it doesn't belong to a trusted |
|
1575 | ``.hg/hgrc`` file from a repository if it doesn't belong to a trusted | |
1576 | user or to a trusted group, as various hgrc features allow arbitrary |
|
1576 | user or to a trusted group, as various hgrc features allow arbitrary | |
1577 | commands to be run. This issue is often encountered when configuring |
|
1577 | commands to be run. This issue is often encountered when configuring | |
1578 | hooks or extensions for shared repositories or servers. However, |
|
1578 | hooks or extensions for shared repositories or servers. However, | |
1579 | the web interface will use some safe settings from the ``[web]`` |
|
1579 | the web interface will use some safe settings from the ``[web]`` | |
1580 | section. |
|
1580 | section. | |
1581 |
|
1581 | |||
1582 | This section specifies what users and groups are trusted. The |
|
1582 | This section specifies what users and groups are trusted. The | |
1583 | current user is always trusted. To trust everybody, list a user or a |
|
1583 | current user is always trusted. To trust everybody, list a user or a | |
1584 | group with name ``*``. These settings must be placed in an |
|
1584 | group with name ``*``. These settings must be placed in an | |
1585 | *already-trusted file* to take effect, such as ``$HOME/.hgrc`` of the |
|
1585 | *already-trusted file* to take effect, such as ``$HOME/.hgrc`` of the | |
1586 | user or service running Mercurial. |
|
1586 | user or service running Mercurial. | |
1587 |
|
1587 | |||
1588 | ``users`` |
|
1588 | ``users`` | |
1589 | Comma-separated list of trusted users. |
|
1589 | Comma-separated list of trusted users. | |
1590 |
|
1590 | |||
1591 | ``groups`` |
|
1591 | ``groups`` | |
1592 | Comma-separated list of trusted groups. |
|
1592 | Comma-separated list of trusted groups. | |
1593 |
|
1593 | |||
1594 |
|
1594 | |||
1595 | ``ui`` |
|
1595 | ``ui`` | |
1596 | ------ |
|
1596 | ------ | |
1597 |
|
1597 | |||
1598 | User interface controls. |
|
1598 | User interface controls. | |
1599 |
|
1599 | |||
1600 | ``archivemeta`` |
|
1600 | ``archivemeta`` | |
1601 | Whether to include the .hg_archival.txt file containing meta data |
|
1601 | Whether to include the .hg_archival.txt file containing meta data | |
1602 | (hashes for the repository base and for tip) in archives created |
|
1602 | (hashes for the repository base and for tip) in archives created | |
1603 | by the :hg:`archive` command or downloaded via hgweb. |
|
1603 | by the :hg:`archive` command or downloaded via hgweb. | |
1604 | (default: True) |
|
1604 | (default: True) | |
1605 |
|
1605 | |||
1606 | ``askusername`` |
|
1606 | ``askusername`` | |
1607 | Whether to prompt for a username when committing. If True, and |
|
1607 | Whether to prompt for a username when committing. If True, and | |
1608 | neither ``$HGUSER`` nor ``$EMAIL`` has been specified, then the user will |
|
1608 | neither ``$HGUSER`` nor ``$EMAIL`` has been specified, then the user will | |
1609 | be prompted to enter a username. If no username is entered, the |
|
1609 | be prompted to enter a username. If no username is entered, the | |
1610 | default ``USER@HOST`` is used instead. |
|
1610 | default ``USER@HOST`` is used instead. | |
1611 | (default: False) |
|
1611 | (default: False) | |
1612 |
|
1612 | |||
1613 | ``clonebundles`` |
|
1613 | ``clonebundles`` | |
1614 | Whether the "clone bundles" feature is enabled. |
|
1614 | Whether the "clone bundles" feature is enabled. | |
1615 |
|
1615 | |||
1616 | When enabled, :hg:`clone` may download and apply a server-advertised |
|
1616 | When enabled, :hg:`clone` may download and apply a server-advertised | |
1617 | bundle file from a URL instead of using the normal exchange mechanism. |
|
1617 | bundle file from a URL instead of using the normal exchange mechanism. | |
1618 |
|
1618 | |||
1619 | This can likely result in faster and more reliable clones. |
|
1619 | This can likely result in faster and more reliable clones. | |
1620 |
|
1620 | |||
1621 | (default: True) |
|
1621 | (default: True) | |
1622 |
|
1622 | |||
1623 | ``clonebundlefallback`` |
|
1623 | ``clonebundlefallback`` | |
1624 | Whether failure to apply an advertised "clone bundle" from a server |
|
1624 | Whether failure to apply an advertised "clone bundle" from a server | |
1625 | should result in fallback to a regular clone. |
|
1625 | should result in fallback to a regular clone. | |
1626 |
|
1626 | |||
1627 | This is disabled by default because servers advertising "clone |
|
1627 | This is disabled by default because servers advertising "clone | |
1628 | bundles" often do so to reduce server load. If advertised bundles |
|
1628 | bundles" often do so to reduce server load. If advertised bundles | |
1629 | start mass failing and clients automatically fall back to a regular |
|
1629 | start mass failing and clients automatically fall back to a regular | |
1630 | clone, this would add significant and unexpected load to the server |
|
1630 | clone, this would add significant and unexpected load to the server | |
1631 | since the server is expecting clone operations to be offloaded to |
|
1631 | since the server is expecting clone operations to be offloaded to | |
1632 | pre-generated bundles. Failing fast (the default behavior) ensures |
|
1632 | pre-generated bundles. Failing fast (the default behavior) ensures | |
1633 | clients don't overwhelm the server when "clone bundle" application |
|
1633 | clients don't overwhelm the server when "clone bundle" application | |
1634 | fails. |
|
1634 | fails. | |
1635 |
|
1635 | |||
1636 | (default: False) |
|
1636 | (default: False) | |
1637 |
|
1637 | |||
1638 | ``clonebundleprefers`` |
|
1638 | ``clonebundleprefers`` | |
1639 | Defines preferences for which "clone bundles" to use. |
|
1639 | Defines preferences for which "clone bundles" to use. | |
1640 |
|
1640 | |||
1641 | Servers advertising "clone bundles" may advertise multiple available |
|
1641 | Servers advertising "clone bundles" may advertise multiple available | |
1642 | bundles. Each bundle may have different attributes, such as the bundle |
|
1642 | bundles. Each bundle may have different attributes, such as the bundle | |
1643 | type and compression format. This option is used to prefer a particular |
|
1643 | type and compression format. This option is used to prefer a particular | |
1644 | bundle over another. |
|
1644 | bundle over another. | |
1645 |
|
1645 | |||
1646 | The following keys are defined by Mercurial: |
|
1646 | The following keys are defined by Mercurial: | |
1647 |
|
1647 | |||
1648 | BUNDLESPEC |
|
1648 | BUNDLESPEC | |
1649 | A bundle type specifier. These are strings passed to :hg:`bundle -t`. |
|
1649 | A bundle type specifier. These are strings passed to :hg:`bundle -t`. | |
1650 | e.g. ``gzip-v2`` or ``bzip2-v1``. |
|
1650 | e.g. ``gzip-v2`` or ``bzip2-v1``. | |
1651 |
|
1651 | |||
1652 | COMPRESSION |
|
1652 | COMPRESSION | |
1653 | The compression format of the bundle. e.g. ``gzip`` and ``bzip2``. |
|
1653 | The compression format of the bundle. e.g. ``gzip`` and ``bzip2``. | |
1654 |
|
1654 | |||
1655 | Server operators may define custom keys. |
|
1655 | Server operators may define custom keys. | |
1656 |
|
1656 | |||
1657 | Example values: ``COMPRESSION=bzip2``, |
|
1657 | Example values: ``COMPRESSION=bzip2``, | |
1658 | ``BUNDLESPEC=gzip-v2, COMPRESSION=gzip``. |
|
1658 | ``BUNDLESPEC=gzip-v2, COMPRESSION=gzip``. | |
1659 |
|
1659 | |||
1660 | By default, the first bundle advertised by the server is used. |
|
1660 | By default, the first bundle advertised by the server is used. | |
1661 |
|
1661 | |||
1662 | ``commitsubrepos`` |
|
1662 | ``commitsubrepos`` | |
1663 | Whether to commit modified subrepositories when committing the |
|
1663 | Whether to commit modified subrepositories when committing the | |
1664 | parent repository. If False and one subrepository has uncommitted |
|
1664 | parent repository. If False and one subrepository has uncommitted | |
1665 | changes, abort the commit. |
|
1665 | changes, abort the commit. | |
1666 | (default: False) |
|
1666 | (default: False) | |
1667 |
|
1667 | |||
1668 | ``debug`` |
|
1668 | ``debug`` | |
1669 | Print debugging information. (default: False) |
|
1669 | Print debugging information. (default: False) | |
1670 |
|
1670 | |||
1671 | ``editor`` |
|
1671 | ``editor`` | |
1672 | The editor to use during a commit. (default: ``$EDITOR`` or ``vi``) |
|
1672 | The editor to use during a commit. (default: ``$EDITOR`` or ``vi``) | |
1673 |
|
1673 | |||
1674 | ``fallbackencoding`` |
|
1674 | ``fallbackencoding`` | |
1675 | Encoding to try if it's not possible to decode the changelog using |
|
1675 | Encoding to try if it's not possible to decode the changelog using | |
1676 | UTF-8. (default: ISO-8859-1) |
|
1676 | UTF-8. (default: ISO-8859-1) | |
1677 |
|
1677 | |||
1678 | ``graphnodetemplate`` |
|
1678 | ``graphnodetemplate`` | |
1679 | The template used to print changeset nodes in an ASCII revision graph. |
|
1679 | The template used to print changeset nodes in an ASCII revision graph. | |
1680 | (default: ``{graphnode}``) |
|
1680 | (default: ``{graphnode}``) | |
1681 |
|
1681 | |||
1682 | ``ignore`` |
|
1682 | ``ignore`` | |
1683 | A file to read per-user ignore patterns from. This file should be |
|
1683 | A file to read per-user ignore patterns from. This file should be | |
1684 | in the same format as a repository-wide .hgignore file. Filenames |
|
1684 | in the same format as a repository-wide .hgignore file. Filenames | |
1685 | are relative to the repository root. This option supports hook syntax, |
|
1685 | are relative to the repository root. This option supports hook syntax, | |
1686 | so if you want to specify multiple ignore files, you can do so by |
|
1686 | so if you want to specify multiple ignore files, you can do so by | |
1687 | setting something like ``ignore.other = ~/.hgignore2``. For details |
|
1687 | setting something like ``ignore.other = ~/.hgignore2``. For details | |
1688 | of the ignore file format, see the ``hgignore(5)`` man page. |
|
1688 | of the ignore file format, see the ``hgignore(5)`` man page. | |
1689 |
|
1689 | |||
1690 | ``interactive`` |
|
1690 | ``interactive`` | |
1691 | Allow to prompt the user. (default: True) |
|
1691 | Allow to prompt the user. (default: True) | |
1692 |
|
1692 | |||
1693 | ``interface`` |
|
1693 | ``interface`` | |
1694 | Select the default interface for interactive features (default: text). |
|
1694 | Select the default interface for interactive features (default: text). | |
1695 | Possible values are 'text' and 'curses'. |
|
1695 | Possible values are 'text' and 'curses'. | |
1696 |
|
1696 | |||
1697 | ``interface.chunkselector`` |
|
1697 | ``interface.chunkselector`` | |
1698 | Select the interface for change recording (e.g. :hg:`commit` -i). |
|
1698 | Select the interface for change recording (e.g. :hg:`commit` -i). | |
1699 | Possible values are 'text' and 'curses'. |
|
1699 | Possible values are 'text' and 'curses'. | |
1700 | This config overrides the interface specified by ui.interface. |
|
1700 | This config overrides the interface specified by ui.interface. | |
1701 |
|
1701 | |||
1702 | ``logtemplate`` |
|
1702 | ``logtemplate`` | |
1703 | Template string for commands that print changesets. |
|
1703 | Template string for commands that print changesets. | |
1704 |
|
1704 | |||
1705 | ``merge`` |
|
1705 | ``merge`` | |
1706 | The conflict resolution program to use during a manual merge. |
|
1706 | The conflict resolution program to use during a manual merge. | |
1707 | For more information on merge tools see :hg:`help merge-tools`. |
|
1707 | For more information on merge tools see :hg:`help merge-tools`. | |
1708 | For configuring merge tools see the ``[merge-tools]`` section. |
|
1708 | For configuring merge tools see the ``[merge-tools]`` section. | |
1709 |
|
1709 | |||
1710 | ``mergemarkers`` |
|
1710 | ``mergemarkers`` | |
1711 | Sets the merge conflict marker label styling. The ``detailed`` |
|
1711 | Sets the merge conflict marker label styling. The ``detailed`` | |
1712 | style uses the ``mergemarkertemplate`` setting to style the labels. |
|
1712 | style uses the ``mergemarkertemplate`` setting to style the labels. | |
1713 | The ``basic`` style just uses 'local' and 'other' as the marker label. |
|
1713 | The ``basic`` style just uses 'local' and 'other' as the marker label. | |
1714 | One of ``basic`` or ``detailed``. |
|
1714 | One of ``basic`` or ``detailed``. | |
1715 | (default: ``basic``) |
|
1715 | (default: ``basic``) | |
1716 |
|
1716 | |||
1717 | ``mergemarkertemplate`` |
|
1717 | ``mergemarkertemplate`` | |
1718 | The template used to print the commit description next to each conflict |
|
1718 | The template used to print the commit description next to each conflict | |
1719 | marker during merge conflicts. See :hg:`help templates` for the template |
|
1719 | marker during merge conflicts. See :hg:`help templates` for the template | |
1720 | format. |
|
1720 | format. | |
1721 |
|
1721 | |||
1722 | Defaults to showing the hash, tags, branches, bookmarks, author, and |
|
1722 | Defaults to showing the hash, tags, branches, bookmarks, author, and | |
1723 | the first line of the commit description. |
|
1723 | the first line of the commit description. | |
1724 |
|
1724 | |||
1725 | If you use non-ASCII characters in names for tags, branches, bookmarks, |
|
1725 | If you use non-ASCII characters in names for tags, branches, bookmarks, | |
1726 | authors, and/or commit descriptions, you must pay attention to encodings of |
|
1726 | authors, and/or commit descriptions, you must pay attention to encodings of | |
1727 | managed files. At template expansion, non-ASCII characters use the encoding |
|
1727 | managed files. At template expansion, non-ASCII characters use the encoding | |
1728 | specified by the ``--encoding`` global option, ``HGENCODING`` or other |
|
1728 | specified by the ``--encoding`` global option, ``HGENCODING`` or other | |
1729 | environment variables that govern your locale. If the encoding of the merge |
|
1729 | environment variables that govern your locale. If the encoding of the merge | |
1730 | markers is different from the encoding of the merged files, |
|
1730 | markers is different from the encoding of the merged files, | |
1731 | serious problems may occur. |
|
1731 | serious problems may occur. | |
1732 |
|
1732 | |||
1733 | ``origbackuppath`` |
|
1733 | ``origbackuppath`` | |
1734 | The path to a directory used to store generated .orig files. If the path is |
|
1734 | The path to a directory used to store generated .orig files. If the path is | |
1735 | not a directory, one will be created. |
|
1735 | not a directory, one will be created. | |
1736 |
|
1736 | |||
1737 | ``patch`` |
|
1737 | ``patch`` | |
1738 | An optional external tool that ``hg import`` and some extensions |
|
1738 | An optional external tool that ``hg import`` and some extensions | |
1739 | will use for applying patches. By default Mercurial uses an |
|
1739 | will use for applying patches. By default Mercurial uses an | |
1740 | internal patch utility. The external tool must work as the common |
|
1740 | internal patch utility. The external tool must work as the common | |
1741 | Unix ``patch`` program. In particular, it must accept a ``-p`` |
|
1741 | Unix ``patch`` program. In particular, it must accept a ``-p`` | |
1742 | argument to strip patch headers, a ``-d`` argument to specify the |
|
1742 | argument to strip patch headers, a ``-d`` argument to specify the | |
1743 | current directory, a file name to patch, and a patch file to take |
|
1743 | current directory, a file name to patch, and a patch file to take | |
1744 | from stdin. |
|
1744 | from stdin. | |
1745 |
|
1745 | |||
1746 | It is possible to specify a patch tool together with extra |
|
1746 | It is possible to specify a patch tool together with extra | |
1747 | arguments. For example, setting this option to ``patch --merge`` |
|
1747 | arguments. For example, setting this option to ``patch --merge`` | |
1748 | will use the ``patch`` program with its 2-way merge option. |
|
1748 | will use the ``patch`` program with its 2-way merge option. | |
1749 |
|
1749 | |||
1750 | ``portablefilenames`` |
|
1750 | ``portablefilenames`` | |
1751 | Check for portable filenames. Can be ``warn``, ``ignore`` or ``abort``. |
|
1751 | Check for portable filenames. Can be ``warn``, ``ignore`` or ``abort``. | |
1752 | (default: ``warn``) |
|
1752 | (default: ``warn``) | |
1753 |
|
1753 | |||
1754 | ``warn`` |
|
1754 | ``warn`` | |
1755 | Print a warning message on POSIX platforms, if a file with a non-portable |
|
1755 | Print a warning message on POSIX platforms, if a file with a non-portable | |
1756 | filename is added (e.g. a file with a name that can't be created on |
|
1756 | filename is added (e.g. a file with a name that can't be created on | |
1757 | Windows because it contains reserved parts like ``AUX``, reserved |
|
1757 | Windows because it contains reserved parts like ``AUX``, reserved | |
1758 | characters like ``:``, or would cause a case collision with an existing |
|
1758 | characters like ``:``, or would cause a case collision with an existing | |
1759 | file). |
|
1759 | file). | |
1760 |
|
1760 | |||
1761 | ``ignore`` |
|
1761 | ``ignore`` | |
1762 | Don't print a warning. |
|
1762 | Don't print a warning. | |
1763 |
|
1763 | |||
1764 | ``abort`` |
|
1764 | ``abort`` | |
1765 | The command is aborted. |
|
1765 | The command is aborted. | |
1766 |
|
1766 | |||
1767 | ``true`` |
|
1767 | ``true`` | |
1768 | Alias for ``warn``. |
|
1768 | Alias for ``warn``. | |
1769 |
|
1769 | |||
1770 | ``false`` |
|
1770 | ``false`` | |
1771 | Alias for ``ignore``. |
|
1771 | Alias for ``ignore``. | |
1772 |
|
1772 | |||
1773 | .. container:: windows |
|
1773 | .. container:: windows | |
1774 |
|
1774 | |||
1775 | On Windows, this configuration option is ignored and the command aborted. |
|
1775 | On Windows, this configuration option is ignored and the command aborted. | |
1776 |
|
1776 | |||
1777 | ``quiet`` |
|
1777 | ``quiet`` | |
1778 | Reduce the amount of output printed. |
|
1778 | Reduce the amount of output printed. | |
1779 | (default: False) |
|
1779 | (default: False) | |
1780 |
|
1780 | |||
1781 | ``remotecmd`` |
|
1781 | ``remotecmd`` | |
1782 | Remote command to use for clone/push/pull operations. |
|
1782 | Remote command to use for clone/push/pull operations. | |
1783 | (default: ``hg``) |
|
1783 | (default: ``hg``) | |
1784 |
|
1784 | |||
1785 | ``report_untrusted`` |
|
1785 | ``report_untrusted`` | |
1786 | Warn if a ``.hg/hgrc`` file is ignored due to not being owned by a |
|
1786 | Warn if a ``.hg/hgrc`` file is ignored due to not being owned by a | |
1787 | trusted user or group. |
|
1787 | trusted user or group. | |
1788 | (default: True) |
|
1788 | (default: True) | |
1789 |
|
1789 | |||
1790 | ``slash`` |
|
1790 | ``slash`` | |
1791 | Display paths using a slash (``/``) as the path separator. This |
|
1791 | Display paths using a slash (``/``) as the path separator. This | |
1792 | only makes a difference on systems where the default path |
|
1792 | only makes a difference on systems where the default path | |
1793 | separator is not the slash character (e.g. Windows uses the |
|
1793 | separator is not the slash character (e.g. Windows uses the | |
1794 | backslash character (``\``)). |
|
1794 | backslash character (``\``)). | |
1795 | (default: False) |
|
1795 | (default: False) | |
1796 |
|
1796 | |||
1797 | ``statuscopies`` |
|
1797 | ``statuscopies`` | |
1798 | Display copies in the status command. |
|
1798 | Display copies in the status command. | |
1799 |
|
1799 | |||
1800 | ``ssh`` |
|
1800 | ``ssh`` | |
1801 | Command to use for SSH connections. (default: ``ssh``) |
|
1801 | Command to use for SSH connections. (default: ``ssh``) | |
1802 |
|
1802 | |||
1803 | ``strict`` |
|
1803 | ``strict`` | |
1804 | Require exact command names, instead of allowing unambiguous |
|
1804 | Require exact command names, instead of allowing unambiguous | |
1805 | abbreviations. (default: False) |
|
1805 | abbreviations. (default: False) | |
1806 |
|
1806 | |||
1807 | ``style`` |
|
1807 | ``style`` | |
1808 | Name of style to use for command output. |
|
1808 | Name of style to use for command output. | |
1809 |
|
1809 | |||
1810 | ``supportcontact`` |
|
1810 | ``supportcontact`` | |
1811 | A URL where users should report a Mercurial traceback. Use this if you are a |
|
1811 | A URL where users should report a Mercurial traceback. Use this if you are a | |
1812 | large organisation with its own Mercurial deployment process and crash |
|
1812 | large organisation with its own Mercurial deployment process and crash | |
1813 | reports should be addressed to your internal support. |
|
1813 | reports should be addressed to your internal support. | |
1814 |
|
1814 | |||
1815 | ``textwidth`` |
|
1815 | ``textwidth`` | |
1816 | Maximum width of help text. A longer line generated by ``hg help`` or |
|
1816 | Maximum width of help text. A longer line generated by ``hg help`` or | |
1817 | ``hg subcommand --help`` will be broken after white space to get this |
|
1817 | ``hg subcommand --help`` will be broken after white space to get this | |
1818 | width or the terminal width, whichever comes first. |
|
1818 | width or the terminal width, whichever comes first. | |
1819 | A non-positive value will disable this and the terminal width will be |
|
1819 | A non-positive value will disable this and the terminal width will be | |
1820 | used. (default: 78) |
|
1820 | used. (default: 78) | |
1821 |
|
1821 | |||
1822 | ``timeout`` |
|
1822 | ``timeout`` | |
1823 | The timeout used when a lock is held (in seconds), a negative value |
|
1823 | The timeout used when a lock is held (in seconds), a negative value | |
1824 | means no timeout. (default: 600) |
|
1824 | means no timeout. (default: 600) | |
1825 |
|
1825 | |||
1826 | ``traceback`` |
|
1826 | ``traceback`` | |
1827 | Mercurial always prints a traceback when an unknown exception |
|
1827 | Mercurial always prints a traceback when an unknown exception | |
1828 | occurs. Setting this to True will make Mercurial print a traceback |
|
1828 | occurs. Setting this to True will make Mercurial print a traceback | |
1829 | on all exceptions, even those recognized by Mercurial (such as |
|
1829 | on all exceptions, even those recognized by Mercurial (such as | |
1830 | IOError or MemoryError). (default: False) |
|
1830 | IOError or MemoryError). (default: False) | |
1831 |
|
1831 | |||
1832 | ``username`` |
|
1832 | ``username`` | |
1833 | The committer of a changeset created when running "commit". |
|
1833 | The committer of a changeset created when running "commit". | |
1834 | Typically a person's name and email address, e.g. ``Fred Widget |
|
1834 | Typically a person's name and email address, e.g. ``Fred Widget | |
1835 | <fred@example.com>``. Environment variables in the |
|
1835 | <fred@example.com>``. Environment variables in the | |
1836 | username are expanded. |
|
1836 | username are expanded. | |
1837 |
|
1837 | |||
1838 | (default: ``$EMAIL`` or ``username@hostname``. If the username in |
|
1838 | (default: ``$EMAIL`` or ``username@hostname``. If the username in | |
1839 | hgrc is empty, e.g. if the system admin set ``username =`` in the |
|
1839 | hgrc is empty, e.g. if the system admin set ``username =`` in the | |
1840 | system hgrc, it has to be specified manually or in a different |
|
1840 | system hgrc, it has to be specified manually or in a different | |
1841 | hgrc file) |
|
1841 | hgrc file) | |
1842 |
|
1842 | |||
1843 | ``verbose`` |
|
1843 | ``verbose`` | |
1844 | Increase the amount of output printed. (default: False) |
|
1844 | Increase the amount of output printed. (default: False) | |
1845 |
|
1845 | |||
1846 |
|
1846 | |||
1847 | ``web`` |
|
1847 | ``web`` | |
1848 | ------- |
|
1848 | ------- | |
1849 |
|
1849 | |||
1850 | Web interface configuration. The settings in this section apply to |
|
1850 | Web interface configuration. The settings in this section apply to | |
1851 | both the builtin webserver (started by :hg:`serve`) and the script you |
|
1851 | both the builtin webserver (started by :hg:`serve`) and the script you | |
1852 | run through a webserver (``hgweb.cgi`` and the derivatives for FastCGI |
|
1852 | run through a webserver (``hgweb.cgi`` and the derivatives for FastCGI | |
1853 | and WSGI). |
|
1853 | and WSGI). | |
1854 |
|
1854 | |||
1855 | The Mercurial webserver does no authentication (it does not prompt for |
|
1855 | The Mercurial webserver does no authentication (it does not prompt for | |
1856 | usernames and passwords to validate *who* users are), but it does do |
|
1856 | usernames and passwords to validate *who* users are), but it does do | |
1857 | authorization (it grants or denies access for *authenticated users* |
|
1857 | authorization (it grants or denies access for *authenticated users* | |
1858 | based on settings in this section). You must either configure your |
|
1858 | based on settings in this section). You must either configure your | |
1859 | webserver to do authentication for you, or disable the authorization |
|
1859 | webserver to do authentication for you, or disable the authorization | |
1860 | checks. |
|
1860 | checks. | |
1861 |
|
1861 | |||
1862 | For a quick setup in a trusted environment, e.g., a private LAN, where |
|
1862 | For a quick setup in a trusted environment, e.g., a private LAN, where | |
1863 | you want it to accept pushes from anybody, you can use the following |
|
1863 | you want it to accept pushes from anybody, you can use the following | |
1864 | command line:: |
|
1864 | command line:: | |
1865 |
|
1865 | |||
1866 | $ hg --config web.allow_push=* --config web.push_ssl=False serve |
|
1866 | $ hg --config web.allow_push=* --config web.push_ssl=False serve | |
1867 |
|
1867 | |||
1868 | Note that this will allow anybody to push anything to the server and |
|
1868 | Note that this will allow anybody to push anything to the server and | |
1869 | that this should not be used for public servers. |
|
1869 | that this should not be used for public servers. | |
1870 |
|
1870 | |||
1871 | The full set of options is: |
|
1871 | The full set of options is: | |
1872 |
|
1872 | |||
1873 | ``accesslog`` |
|
1873 | ``accesslog`` | |
1874 | Where to output the access log. (default: stdout) |
|
1874 | Where to output the access log. (default: stdout) | |
1875 |
|
1875 | |||
1876 | ``address`` |
|
1876 | ``address`` | |
1877 | Interface address to bind to. (default: all) |
|
1877 | Interface address to bind to. (default: all) | |
1878 |
|
1878 | |||
1879 | ``allow_archive`` |
|
1879 | ``allow_archive`` | |
1880 | List of archive format (bz2, gz, zip) allowed for downloading. |
|
1880 | List of archive format (bz2, gz, zip) allowed for downloading. | |
1881 | (default: empty) |
|
1881 | (default: empty) | |
1882 |
|
1882 | |||
1883 | ``allowbz2`` |
|
1883 | ``allowbz2`` | |
1884 | (DEPRECATED) Whether to allow .tar.bz2 downloading of repository |
|
1884 | (DEPRECATED) Whether to allow .tar.bz2 downloading of repository | |
1885 | revisions. |
|
1885 | revisions. | |
1886 | (default: False) |
|
1886 | (default: False) | |
1887 |
|
1887 | |||
1888 | ``allowgz`` |
|
1888 | ``allowgz`` | |
1889 | (DEPRECATED) Whether to allow .tar.gz downloading of repository |
|
1889 | (DEPRECATED) Whether to allow .tar.gz downloading of repository | |
1890 | revisions. |
|
1890 | revisions. | |
1891 | (default: False) |
|
1891 | (default: False) | |
1892 |
|
1892 | |||
1893 | ``allowpull`` |
|
1893 | ``allowpull`` | |
1894 | Whether to allow pulling from the repository. (default: True) |
|
1894 | Whether to allow pulling from the repository. (default: True) | |
1895 |
|
1895 | |||
1896 | ``allow_push`` |
|
1896 | ``allow_push`` | |
1897 | Whether to allow pushing to the repository. If empty or not set, |
|
1897 | Whether to allow pushing to the repository. If empty or not set, | |
1898 | pushing is not allowed. If the special value ``*``, any remote |
|
1898 | pushing is not allowed. If the special value ``*``, any remote | |
1899 | user can push, including unauthenticated users. Otherwise, the |
|
1899 | user can push, including unauthenticated users. Otherwise, the | |
1900 | remote user must have been authenticated, and the authenticated |
|
1900 | remote user must have been authenticated, and the authenticated | |
1901 | user name must be present in this list. The contents of the |
|
1901 | user name must be present in this list. The contents of the | |
1902 | allow_push list are examined after the deny_push list. |
|
1902 | allow_push list are examined after the deny_push list. | |
1903 |
|
1903 | |||
1904 | ``allow_read`` |
|
1904 | ``allow_read`` | |
1905 | If the user has not already been denied repository access due to |
|
1905 | If the user has not already been denied repository access due to | |
1906 | the contents of deny_read, this list determines whether to grant |
|
1906 | the contents of deny_read, this list determines whether to grant | |
1907 | repository access to the user. If this list is not empty, and the |
|
1907 | repository access to the user. If this list is not empty, and the | |
1908 | user is unauthenticated or not present in the list, then access is |
|
1908 | user is unauthenticated or not present in the list, then access is | |
1909 | denied for the user. If the list is empty or not set, then access |
|
1909 | denied for the user. If the list is empty or not set, then access | |
1910 | is permitted to all users by default. Setting allow_read to the |
|
1910 | is permitted to all users by default. Setting allow_read to the | |
1911 | special value ``*`` is equivalent to it not being set (i.e. access |
|
1911 | special value ``*`` is equivalent to it not being set (i.e. access | |
1912 | is permitted to all users). The contents of the allow_read list are |
|
1912 | is permitted to all users). The contents of the allow_read list are | |
1913 | examined after the deny_read list. |
|
1913 | examined after the deny_read list. | |
1914 |
|
1914 | |||
1915 | ``allowzip`` |
|
1915 | ``allowzip`` | |
1916 | (DEPRECATED) Whether to allow .zip downloading of repository |
|
1916 | (DEPRECATED) Whether to allow .zip downloading of repository | |
1917 | revisions. This feature creates temporary files. |
|
1917 | revisions. This feature creates temporary files. | |
1918 | (default: False) |
|
1918 | (default: False) | |
1919 |
|
1919 | |||
1920 | ``archivesubrepos`` |
|
1920 | ``archivesubrepos`` | |
1921 | Whether to recurse into subrepositories when archiving. |
|
1921 | Whether to recurse into subrepositories when archiving. | |
1922 | (default: False) |
|
1922 | (default: False) | |
1923 |
|
1923 | |||
1924 | ``baseurl`` |
|
1924 | ``baseurl`` | |
1925 | Base URL to use when publishing URLs in other locations, so |
|
1925 | Base URL to use when publishing URLs in other locations, so | |
1926 | third-party tools like email notification hooks can construct |
|
1926 | third-party tools like email notification hooks can construct | |
1927 | URLs. Example: ``http://hgserver/repos/``. |
|
1927 | URLs. Example: ``http://hgserver/repos/``. | |
1928 |
|
1928 | |||
1929 | ``cacerts`` |
|
1929 | ``cacerts`` | |
1930 | Path to file containing a list of PEM encoded certificate |
|
1930 | Path to file containing a list of PEM encoded certificate | |
1931 | authority certificates. Environment variables and ``~user`` |
|
1931 | authority certificates. Environment variables and ``~user`` | |
1932 | constructs are expanded in the filename. If specified on the |
|
1932 | constructs are expanded in the filename. If specified on the | |
1933 | client, then it will verify the identity of remote HTTPS servers |
|
1933 | client, then it will verify the identity of remote HTTPS servers | |
1934 | with these certificates. |
|
1934 | with these certificates. | |
1935 |
|
1935 | |||
1936 | To disable SSL verification temporarily, specify ``--insecure`` from |
|
1936 | To disable SSL verification temporarily, specify ``--insecure`` from | |
1937 | command line. |
|
1937 | command line. | |
1938 |
|
1938 | |||
1939 | You can use OpenSSL's CA certificate file if your platform has |
|
1939 | You can use OpenSSL's CA certificate file if your platform has | |
1940 | one. On most Linux systems this will be |
|
1940 | one. On most Linux systems this will be | |
1941 | ``/etc/ssl/certs/ca-certificates.crt``. Otherwise you will have to |
|
1941 | ``/etc/ssl/certs/ca-certificates.crt``. Otherwise you will have to | |
1942 | generate this file manually. The form must be as follows:: |
|
1942 | generate this file manually. The form must be as follows:: | |
1943 |
|
1943 | |||
1944 | -----BEGIN CERTIFICATE----- |
|
1944 | -----BEGIN CERTIFICATE----- | |
1945 | ... (certificate in base64 PEM encoding) ... |
|
1945 | ... (certificate in base64 PEM encoding) ... | |
1946 | -----END CERTIFICATE----- |
|
1946 | -----END CERTIFICATE----- | |
1947 | -----BEGIN CERTIFICATE----- |
|
1947 | -----BEGIN CERTIFICATE----- | |
1948 | ... (certificate in base64 PEM encoding) ... |
|
1948 | ... (certificate in base64 PEM encoding) ... | |
1949 | -----END CERTIFICATE----- |
|
1949 | -----END CERTIFICATE----- | |
1950 |
|
1950 | |||
1951 | ``cache`` |
|
1951 | ``cache`` | |
1952 | Whether to support caching in hgweb. (default: True) |
|
1952 | Whether to support caching in hgweb. (default: True) | |
1953 |
|
1953 | |||
1954 | ``certificate`` |
|
1954 | ``certificate`` | |
1955 | Certificate to use when running :hg:`serve`. |
|
1955 | Certificate to use when running :hg:`serve`. | |
1956 |
|
1956 | |||
1957 | ``collapse`` |
|
1957 | ``collapse`` | |
1958 | With ``descend`` enabled, repositories in subdirectories are shown at |
|
1958 | With ``descend`` enabled, repositories in subdirectories are shown at | |
1959 | a single level alongside repositories in the current path. With |
|
1959 | a single level alongside repositories in the current path. With | |
1960 | ``collapse`` also enabled, repositories residing at a deeper level than |
|
1960 | ``collapse`` also enabled, repositories residing at a deeper level than | |
1961 | the current path are grouped behind navigable directory entries that |
|
1961 | the current path are grouped behind navigable directory entries that | |
1962 | lead to the locations of these repositories. In effect, this setting |
|
1962 | lead to the locations of these repositories. In effect, this setting | |
1963 | collapses each collection of repositories found within a subdirectory |
|
1963 | collapses each collection of repositories found within a subdirectory | |
1964 | into a single entry for that subdirectory. (default: False) |
|
1964 | into a single entry for that subdirectory. (default: False) | |
1965 |
|
1965 | |||
1966 | ``comparisoncontext`` |
|
1966 | ``comparisoncontext`` | |
1967 | Number of lines of context to show in side-by-side file comparison. If |
|
1967 | Number of lines of context to show in side-by-side file comparison. If | |
1968 | negative or the value ``full``, whole files are shown. (default: 5) |
|
1968 | negative or the value ``full``, whole files are shown. (default: 5) | |
1969 |
|
1969 | |||
1970 | This setting can be overridden by a ``context`` request parameter to the |
|
1970 | This setting can be overridden by a ``context`` request parameter to the | |
1971 | ``comparison`` command, taking the same values. |
|
1971 | ``comparison`` command, taking the same values. | |
1972 |
|
1972 | |||
1973 | ``contact`` |
|
1973 | ``contact`` | |
1974 | Name or email address of the person in charge of the repository. |
|
1974 | Name or email address of the person in charge of the repository. | |
1975 | (default: ui.username or ``$EMAIL`` or "unknown" if unset or empty) |
|
1975 | (default: ui.username or ``$EMAIL`` or "unknown" if unset or empty) | |
1976 |
|
1976 | |||
1977 | ``deny_push`` |
|
1977 | ``deny_push`` | |
1978 | Whether to deny pushing to the repository. If empty or not set, |
|
1978 | Whether to deny pushing to the repository. If empty or not set, | |
1979 | push is not denied. If the special value ``*``, all remote users are |
|
1979 | push is not denied. If the special value ``*``, all remote users are | |
1980 | denied push. Otherwise, unauthenticated users are all denied, and |
|
1980 | denied push. Otherwise, unauthenticated users are all denied, and | |
1981 | any authenticated user name present in this list is also denied. The |
|
1981 | any authenticated user name present in this list is also denied. The | |
1982 | contents of the deny_push list are examined before the allow_push list. |
|
1982 | contents of the deny_push list are examined before the allow_push list. | |
1983 |
|
1983 | |||
1984 | ``deny_read`` |
|
1984 | ``deny_read`` | |
1985 | Whether to deny reading/viewing of the repository. If this list is |
|
1985 | Whether to deny reading/viewing of the repository. If this list is | |
1986 | not empty, unauthenticated users are all denied, and any |
|
1986 | not empty, unauthenticated users are all denied, and any | |
1987 | authenticated user name present in this list is also denied access to |
|
1987 | authenticated user name present in this list is also denied access to | |
1988 | the repository. If set to the special value ``*``, all remote users |
|
1988 | the repository. If set to the special value ``*``, all remote users | |
1989 | are denied access (rarely needed ;). If deny_read is empty or not set, |
|
1989 | are denied access (rarely needed ;). If deny_read is empty or not set, | |
1990 | the determination of repository access depends on the presence and |
|
1990 | the determination of repository access depends on the presence and | |
1991 | content of the allow_read list (see description). If both |
|
1991 | content of the allow_read list (see description). If both | |
1992 | deny_read and allow_read are empty or not set, then access is |
|
1992 | deny_read and allow_read are empty or not set, then access is | |
1993 | permitted to all users by default. If the repository is being |
|
1993 | permitted to all users by default. If the repository is being | |
1994 | served via hgwebdir, denied users will not be able to see it in |
|
1994 | served via hgwebdir, denied users will not be able to see it in | |
1995 | the list of repositories. The contents of the deny_read list have |
|
1995 | the list of repositories. The contents of the deny_read list have | |
1996 | priority over (are examined before) the contents of the allow_read |
|
1996 | priority over (are examined before) the contents of the allow_read | |
1997 | list. |
|
1997 | list. | |
1998 |
|
1998 | |||
1999 | ``descend`` |
|
1999 | ``descend`` | |
2000 | hgwebdir indexes will not descend into subdirectories. Only repositories |
|
2000 | hgwebdir indexes will not descend into subdirectories. Only repositories | |
2001 | directly in the current path will be shown (other repositories are still |
|
2001 | directly in the current path will be shown (other repositories are still | |
2002 | available from the index corresponding to their containing path). |
|
2002 | available from the index corresponding to their containing path). | |
2003 |
|
2003 | |||
2004 | ``description`` |
|
2004 | ``description`` | |
2005 | Textual description of the repository's purpose or contents. |
|
2005 | Textual description of the repository's purpose or contents. | |
2006 | (default: "unknown") |
|
2006 | (default: "unknown") | |
2007 |
|
2007 | |||
2008 | ``encoding`` |
|
2008 | ``encoding`` | |
2009 | Character encoding name. (default: the current locale charset) |
|
2009 | Character encoding name. (default: the current locale charset) | |
2010 | Example: "UTF-8". |
|
2010 | Example: "UTF-8". | |
2011 |
|
2011 | |||
2012 | ``errorlog`` |
|
2012 | ``errorlog`` | |
2013 | Where to output the error log. (default: stderr) |
|
2013 | Where to output the error log. (default: stderr) | |
2014 |
|
2014 | |||
2015 | ``guessmime`` |
|
2015 | ``guessmime`` | |
2016 | Control MIME types for raw download of file content. |
|
2016 | Control MIME types for raw download of file content. | |
2017 | Set to True to let hgweb guess the content type from the file |
|
2017 | Set to True to let hgweb guess the content type from the file | |
2018 | extension. This will serve HTML files as ``text/html`` and might |
|
2018 | extension. This will serve HTML files as ``text/html`` and might | |
2019 | allow cross-site scripting attacks when serving untrusted |
|
2019 | allow cross-site scripting attacks when serving untrusted | |
2020 | repositories. (default: False) |
|
2020 | repositories. (default: False) | |
2021 |
|
2021 | |||
2022 | ``hidden`` |
|
2022 | ``hidden`` | |
2023 | Whether to hide the repository in the hgwebdir index. |
|
2023 | Whether to hide the repository in the hgwebdir index. | |
2024 | (default: False) |
|
2024 | (default: False) | |
2025 |
|
2025 | |||
2026 | ``ipv6`` |
|
2026 | ``ipv6`` | |
2027 | Whether to use IPv6. (default: False) |
|
2027 | Whether to use IPv6. (default: False) | |
2028 |
|
2028 | |||
|
2029 | ``labels`` | |||
|
2030 | List of string *labels* associated with the repository. | |||
|
2031 | ||||
|
2032 | Labels are exposed as a template keyword and can be used to customize | |||
|
2033 | output. e.g. the ``index`` template can group or filter repositories | |||
|
2034 | by labels and the ``summary`` template can display additional content | |||
|
2035 | if a specific label is present. | |||
|
2036 | ||||
2029 | ``logoimg`` |
|
2037 | ``logoimg`` | |
2030 | File name of the logo image that some templates display on each page. |
|
2038 | File name of the logo image that some templates display on each page. | |
2031 | The file name is relative to ``staticurl``. That is, the full path to |
|
2039 | The file name is relative to ``staticurl``. That is, the full path to | |
2032 | the logo image is "staticurl/logoimg". |
|
2040 | the logo image is "staticurl/logoimg". | |
2033 | If unset, ``hglogo.png`` will be used. |
|
2041 | If unset, ``hglogo.png`` will be used. | |
2034 |
|
2042 | |||
2035 | ``logourl`` |
|
2043 | ``logourl`` | |
2036 | Base URL to use for logos. If unset, ``https://mercurial-scm.org/`` |
|
2044 | Base URL to use for logos. If unset, ``https://mercurial-scm.org/`` | |
2037 | will be used. |
|
2045 | will be used. | |
2038 |
|
2046 | |||
2039 | ``maxchanges`` |
|
2047 | ``maxchanges`` | |
2040 | Maximum number of changes to list on the changelog. (default: 10) |
|
2048 | Maximum number of changes to list on the changelog. (default: 10) | |
2041 |
|
2049 | |||
2042 | ``maxfiles`` |
|
2050 | ``maxfiles`` | |
2043 | Maximum number of files to list per changeset. (default: 10) |
|
2051 | Maximum number of files to list per changeset. (default: 10) | |
2044 |
|
2052 | |||
2045 | ``maxshortchanges`` |
|
2053 | ``maxshortchanges`` | |
2046 | Maximum number of changes to list on the shortlog, graph or filelog |
|
2054 | Maximum number of changes to list on the shortlog, graph or filelog | |
2047 | pages. (default: 60) |
|
2055 | pages. (default: 60) | |
2048 |
|
2056 | |||
2049 | ``name`` |
|
2057 | ``name`` | |
2050 | Repository name to use in the web interface. |
|
2058 | Repository name to use in the web interface. | |
2051 | (default: current working directory) |
|
2059 | (default: current working directory) | |
2052 |
|
2060 | |||
2053 | ``port`` |
|
2061 | ``port`` | |
2054 | Port to listen on. (default: 8000) |
|
2062 | Port to listen on. (default: 8000) | |
2055 |
|
2063 | |||
2056 | ``prefix`` |
|
2064 | ``prefix`` | |
2057 | Prefix path to serve from. (default: '' (server root)) |
|
2065 | Prefix path to serve from. (default: '' (server root)) | |
2058 |
|
2066 | |||
2059 | ``push_ssl`` |
|
2067 | ``push_ssl`` | |
2060 | Whether to require that inbound pushes be transported over SSL to |
|
2068 | Whether to require that inbound pushes be transported over SSL to | |
2061 | prevent password sniffing. (default: True) |
|
2069 | prevent password sniffing. (default: True) | |
2062 |
|
2070 | |||
2063 | ``refreshinterval`` |
|
2071 | ``refreshinterval`` | |
2064 | How frequently directory listings re-scan the filesystem for new |
|
2072 | How frequently directory listings re-scan the filesystem for new | |
2065 | repositories, in seconds. This is relevant when wildcards are used |
|
2073 | repositories, in seconds. This is relevant when wildcards are used | |
2066 | to define paths. Depending on how much filesystem traversal is |
|
2074 | to define paths. Depending on how much filesystem traversal is | |
2067 | required, refreshing may negatively impact performance. |
|
2075 | required, refreshing may negatively impact performance. | |
2068 |
|
2076 | |||
2069 | Values less than or equal to 0 always refresh. |
|
2077 | Values less than or equal to 0 always refresh. | |
2070 | (default: 20) |
|
2078 | (default: 20) | |
2071 |
|
2079 | |||
2072 | ``staticurl`` |
|
2080 | ``staticurl`` | |
2073 | Base URL to use for static files. If unset, static files (e.g. the |
|
2081 | Base URL to use for static files. If unset, static files (e.g. the | |
2074 | hgicon.png favicon) will be served by the CGI script itself. Use |
|
2082 | hgicon.png favicon) will be served by the CGI script itself. Use | |
2075 | this setting to serve them directly with the HTTP server. |
|
2083 | this setting to serve them directly with the HTTP server. | |
2076 | Example: ``http://hgserver/static/``. |
|
2084 | Example: ``http://hgserver/static/``. | |
2077 |
|
2085 | |||
2078 | ``stripes`` |
|
2086 | ``stripes`` | |
2079 | How many lines a "zebra stripe" should span in multi-line output. |
|
2087 | How many lines a "zebra stripe" should span in multi-line output. | |
2080 | Set to 0 to disable. (default: 1) |
|
2088 | Set to 0 to disable. (default: 1) | |
2081 |
|
2089 | |||
2082 | ``style`` |
|
2090 | ``style`` | |
2083 | Which template map style to use. The available options are the names of |
|
2091 | Which template map style to use. The available options are the names of | |
2084 | subdirectories in the HTML templates path. (default: ``paper``) |
|
2092 | subdirectories in the HTML templates path. (default: ``paper``) | |
2085 | Example: ``monoblue``. |
|
2093 | Example: ``monoblue``. | |
2086 |
|
2094 | |||
2087 | ``templates`` |
|
2095 | ``templates`` | |
2088 | Where to find the HTML templates. The default path to the HTML templates |
|
2096 | Where to find the HTML templates. The default path to the HTML templates | |
2089 | can be obtained from ``hg debuginstall``. |
|
2097 | can be obtained from ``hg debuginstall``. | |
2090 |
|
2098 | |||
2091 | ``websub`` |
|
2099 | ``websub`` | |
2092 | ---------- |
|
2100 | ---------- | |
2093 |
|
2101 | |||
2094 | Web substitution filter definition. You can use this section to |
|
2102 | Web substitution filter definition. You can use this section to | |
2095 | define a set of regular expression substitution patterns which |
|
2103 | define a set of regular expression substitution patterns which | |
2096 | let you automatically modify the hgweb server output. |
|
2104 | let you automatically modify the hgweb server output. | |
2097 |
|
2105 | |||
2098 | The default hgweb templates only apply these substitution patterns |
|
2106 | The default hgweb templates only apply these substitution patterns | |
2099 | on the revision description fields. You can apply them anywhere |
|
2107 | on the revision description fields. You can apply them anywhere | |
2100 | you want when you create your own templates by adding calls to the |
|
2108 | you want when you create your own templates by adding calls to the | |
2101 | "websub" filter (usually after calling the "escape" filter). |
|
2109 | "websub" filter (usually after calling the "escape" filter). | |
2102 |
|
2110 | |||
2103 | This can be used, for example, to convert issue references to links |
|
2111 | This can be used, for example, to convert issue references to links | |
2104 | to your issue tracker, or to convert "markdown-like" syntax into |
|
2112 | to your issue tracker, or to convert "markdown-like" syntax into | |
2105 | HTML (see the examples below). |
|
2113 | HTML (see the examples below). | |
2106 |
|
2114 | |||
2107 | Each entry in this section names a substitution filter. |
|
2115 | Each entry in this section names a substitution filter. | |
2108 | The value of each entry defines the substitution expression itself. |
|
2116 | The value of each entry defines the substitution expression itself. | |
2109 | The websub expressions follow the old interhg extension syntax, |
|
2117 | The websub expressions follow the old interhg extension syntax, | |
2110 | which in turn imitates the Unix sed replacement syntax:: |
|
2118 | which in turn imitates the Unix sed replacement syntax:: | |
2111 |
|
2119 | |||
2112 | patternname = s/SEARCH_REGEX/REPLACE_EXPRESSION/[i] |
|
2120 | patternname = s/SEARCH_REGEX/REPLACE_EXPRESSION/[i] | |
2113 |
|
2121 | |||
2114 | You can use any separator other than "/". The final "i" is optional |
|
2122 | You can use any separator other than "/". The final "i" is optional | |
2115 | and indicates that the search must be case insensitive. |
|
2123 | and indicates that the search must be case insensitive. | |
2116 |
|
2124 | |||
2117 | Examples:: |
|
2125 | Examples:: | |
2118 |
|
2126 | |||
2119 | [websub] |
|
2127 | [websub] | |
2120 | issues = s|issue(\d+)|<a href="http://bts.example.org/issue\1">issue\1</a>|i |
|
2128 | issues = s|issue(\d+)|<a href="http://bts.example.org/issue\1">issue\1</a>|i | |
2121 | italic = s/\b_(\S+)_\b/<i>\1<\/i>/ |
|
2129 | italic = s/\b_(\S+)_\b/<i>\1<\/i>/ | |
2122 | bold = s/\*\b(\S+)\b\*/<b>\1<\/b>/ |
|
2130 | bold = s/\*\b(\S+)\b\*/<b>\1<\/b>/ | |
2123 |
|
2131 | |||
2124 | ``worker`` |
|
2132 | ``worker`` | |
2125 | ---------- |
|
2133 | ---------- | |
2126 |
|
2134 | |||
2127 | Parallel master/worker configuration. We currently perform working |
|
2135 | Parallel master/worker configuration. We currently perform working | |
2128 | directory updates in parallel on Unix-like systems, which greatly |
|
2136 | directory updates in parallel on Unix-like systems, which greatly | |
2129 | helps performance. |
|
2137 | helps performance. | |
2130 |
|
2138 | |||
2131 | ``numcpus`` |
|
2139 | ``numcpus`` | |
2132 | Number of CPUs to use for parallel operations. A zero or |
|
2140 | Number of CPUs to use for parallel operations. A zero or | |
2133 | negative value is treated as ``use the default``. |
|
2141 | negative value is treated as ``use the default``. | |
2134 | (default: 4 or the number of CPUs on the system, whichever is larger) |
|
2142 | (default: 4 or the number of CPUs on the system, whichever is larger) | |
2135 |
|
2143 | |||
2136 | ``backgroundclose`` |
|
2144 | ``backgroundclose`` | |
2137 | Whether to enable closing file handles on background threads during certain |
|
2145 | Whether to enable closing file handles on background threads during certain | |
2138 | operations. Some platforms aren't very efficient at closing file |
|
2146 | operations. Some platforms aren't very efficient at closing file | |
2139 | handles that have been written or appended to. By performing file closing |
|
2147 | handles that have been written or appended to. By performing file closing | |
2140 | on background threads, file write rate can increase substantially. |
|
2148 | on background threads, file write rate can increase substantially. | |
2141 | (default: true on Windows, false elsewhere) |
|
2149 | (default: true on Windows, false elsewhere) | |
2142 |
|
2150 | |||
2143 | ``backgroundcloseminfilecount`` |
|
2151 | ``backgroundcloseminfilecount`` | |
2144 | Minimum number of files required to trigger background file closing. |
|
2152 | Minimum number of files required to trigger background file closing. | |
2145 | Operations not writing this many files won't start background close |
|
2153 | Operations not writing this many files won't start background close | |
2146 | threads. |
|
2154 | threads. | |
2147 | (default: 2048) |
|
2155 | (default: 2048) | |
2148 |
|
2156 | |||
2149 | ``backgroundclosemaxqueue`` |
|
2157 | ``backgroundclosemaxqueue`` | |
2150 | The maximum number of opened file handles waiting to be closed in the |
|
2158 | The maximum number of opened file handles waiting to be closed in the | |
2151 | background. This option only has an effect if ``backgroundclose`` is |
|
2159 | background. This option only has an effect if ``backgroundclose`` is | |
2152 | enabled. |
|
2160 | enabled. | |
2153 | (default: 384) |
|
2161 | (default: 384) | |
2154 |
|
2162 | |||
2155 | ``backgroundclosethreadcount`` |
|
2163 | ``backgroundclosethreadcount`` | |
2156 | Number of threads to process background file closes. Only relevant if |
|
2164 | Number of threads to process background file closes. Only relevant if | |
2157 | ``backgroundclose`` is enabled. |
|
2165 | ``backgroundclose`` is enabled. | |
2158 | (default: 4) |
|
2166 | (default: 4) |
@@ -1,512 +1,515 b'' | |||||
1 | # hgweb/hgwebdir_mod.py - Web interface for a directory of repositories. |
|
1 | # hgweb/hgwebdir_mod.py - Web interface for a directory of repositories. | |
2 | # |
|
2 | # | |
3 | # Copyright 21 May 2005 - (c) 2005 Jake Edge <jake@edge2.net> |
|
3 | # Copyright 21 May 2005 - (c) 2005 Jake Edge <jake@edge2.net> | |
4 | # Copyright 2005, 2006 Matt Mackall <mpm@selenic.com> |
|
4 | # Copyright 2005, 2006 Matt Mackall <mpm@selenic.com> | |
5 | # |
|
5 | # | |
6 | # This software may be used and distributed according to the terms of the |
|
6 | # This software may be used and distributed according to the terms of the | |
7 | # GNU General Public License version 2 or any later version. |
|
7 | # GNU General Public License version 2 or any later version. | |
8 |
|
8 | |||
9 | from __future__ import absolute_import |
|
9 | from __future__ import absolute_import | |
10 |
|
10 | |||
11 | import os |
|
11 | import os | |
12 | import re |
|
12 | import re | |
13 | import time |
|
13 | import time | |
14 |
|
14 | |||
15 | from ..i18n import _ |
|
15 | from ..i18n import _ | |
16 |
|
16 | |||
17 | from .common import ( |
|
17 | from .common import ( | |
18 | ErrorResponse, |
|
18 | ErrorResponse, | |
19 | HTTP_NOT_FOUND, |
|
19 | HTTP_NOT_FOUND, | |
20 | HTTP_OK, |
|
20 | HTTP_OK, | |
21 | HTTP_SERVER_ERROR, |
|
21 | HTTP_SERVER_ERROR, | |
22 | get_contact, |
|
22 | get_contact, | |
23 | get_mtime, |
|
23 | get_mtime, | |
24 | ismember, |
|
24 | ismember, | |
25 | paritygen, |
|
25 | paritygen, | |
26 | staticfile, |
|
26 | staticfile, | |
27 | ) |
|
27 | ) | |
28 | from .request import wsgirequest |
|
28 | from .request import wsgirequest | |
29 |
|
29 | |||
30 | from .. import ( |
|
30 | from .. import ( | |
31 | encoding, |
|
31 | encoding, | |
32 | error, |
|
32 | error, | |
33 | hg, |
|
33 | hg, | |
34 | scmutil, |
|
34 | scmutil, | |
35 | templater, |
|
35 | templater, | |
36 | ui as uimod, |
|
36 | ui as uimod, | |
37 | util, |
|
37 | util, | |
38 | ) |
|
38 | ) | |
39 |
|
39 | |||
40 | from . import ( |
|
40 | from . import ( | |
41 | hgweb_mod, |
|
41 | hgweb_mod, | |
42 | webutil, |
|
42 | webutil, | |
43 | wsgicgi, |
|
43 | wsgicgi, | |
44 | ) |
|
44 | ) | |
45 |
|
45 | |||
46 | def cleannames(items): |
|
46 | def cleannames(items): | |
47 | return [(util.pconvert(name).strip('/'), path) for name, path in items] |
|
47 | return [(util.pconvert(name).strip('/'), path) for name, path in items] | |
48 |
|
48 | |||
49 | def findrepos(paths): |
|
49 | def findrepos(paths): | |
50 | repos = [] |
|
50 | repos = [] | |
51 | for prefix, root in cleannames(paths): |
|
51 | for prefix, root in cleannames(paths): | |
52 | roothead, roottail = os.path.split(root) |
|
52 | roothead, roottail = os.path.split(root) | |
53 | # "foo = /bar/*" or "foo = /bar/**" lets every repo /bar/N in or below |
|
53 | # "foo = /bar/*" or "foo = /bar/**" lets every repo /bar/N in or below | |
54 | # /bar/ be served as as foo/N . |
|
54 | # /bar/ be served as as foo/N . | |
55 | # '*' will not search inside dirs with .hg (except .hg/patches), |
|
55 | # '*' will not search inside dirs with .hg (except .hg/patches), | |
56 | # '**' will search inside dirs with .hg (and thus also find subrepos). |
|
56 | # '**' will search inside dirs with .hg (and thus also find subrepos). | |
57 | try: |
|
57 | try: | |
58 | recurse = {'*': False, '**': True}[roottail] |
|
58 | recurse = {'*': False, '**': True}[roottail] | |
59 | except KeyError: |
|
59 | except KeyError: | |
60 | repos.append((prefix, root)) |
|
60 | repos.append((prefix, root)) | |
61 | continue |
|
61 | continue | |
62 | roothead = os.path.normpath(os.path.abspath(roothead)) |
|
62 | roothead = os.path.normpath(os.path.abspath(roothead)) | |
63 | paths = scmutil.walkrepos(roothead, followsym=True, recurse=recurse) |
|
63 | paths = scmutil.walkrepos(roothead, followsym=True, recurse=recurse) | |
64 | repos.extend(urlrepos(prefix, roothead, paths)) |
|
64 | repos.extend(urlrepos(prefix, roothead, paths)) | |
65 | return repos |
|
65 | return repos | |
66 |
|
66 | |||
67 | def urlrepos(prefix, roothead, paths): |
|
67 | def urlrepos(prefix, roothead, paths): | |
68 | """yield url paths and filesystem paths from a list of repo paths |
|
68 | """yield url paths and filesystem paths from a list of repo paths | |
69 |
|
69 | |||
70 | >>> conv = lambda seq: [(v, util.pconvert(p)) for v,p in seq] |
|
70 | >>> conv = lambda seq: [(v, util.pconvert(p)) for v,p in seq] | |
71 | >>> conv(urlrepos('hg', '/opt', ['/opt/r', '/opt/r/r', '/opt'])) |
|
71 | >>> conv(urlrepos('hg', '/opt', ['/opt/r', '/opt/r/r', '/opt'])) | |
72 | [('hg/r', '/opt/r'), ('hg/r/r', '/opt/r/r'), ('hg', '/opt')] |
|
72 | [('hg/r', '/opt/r'), ('hg/r/r', '/opt/r/r'), ('hg', '/opt')] | |
73 | >>> conv(urlrepos('', '/opt', ['/opt/r', '/opt/r/r', '/opt'])) |
|
73 | >>> conv(urlrepos('', '/opt', ['/opt/r', '/opt/r/r', '/opt'])) | |
74 | [('r', '/opt/r'), ('r/r', '/opt/r/r'), ('', '/opt')] |
|
74 | [('r', '/opt/r'), ('r/r', '/opt/r/r'), ('', '/opt')] | |
75 | """ |
|
75 | """ | |
76 | for path in paths: |
|
76 | for path in paths: | |
77 | path = os.path.normpath(path) |
|
77 | path = os.path.normpath(path) | |
78 | yield (prefix + '/' + |
|
78 | yield (prefix + '/' + | |
79 | util.pconvert(path[len(roothead):]).lstrip('/')).strip('/'), path |
|
79 | util.pconvert(path[len(roothead):]).lstrip('/')).strip('/'), path | |
80 |
|
80 | |||
81 | def geturlcgivars(baseurl, port): |
|
81 | def geturlcgivars(baseurl, port): | |
82 | """ |
|
82 | """ | |
83 | Extract CGI variables from baseurl |
|
83 | Extract CGI variables from baseurl | |
84 |
|
84 | |||
85 | >>> geturlcgivars("http://host.org/base", "80") |
|
85 | >>> geturlcgivars("http://host.org/base", "80") | |
86 | ('host.org', '80', '/base') |
|
86 | ('host.org', '80', '/base') | |
87 | >>> geturlcgivars("http://host.org:8000/base", "80") |
|
87 | >>> geturlcgivars("http://host.org:8000/base", "80") | |
88 | ('host.org', '8000', '/base') |
|
88 | ('host.org', '8000', '/base') | |
89 | >>> geturlcgivars('/base', 8000) |
|
89 | >>> geturlcgivars('/base', 8000) | |
90 | ('', '8000', '/base') |
|
90 | ('', '8000', '/base') | |
91 | >>> geturlcgivars("base", '8000') |
|
91 | >>> geturlcgivars("base", '8000') | |
92 | ('', '8000', '/base') |
|
92 | ('', '8000', '/base') | |
93 | >>> geturlcgivars("http://host", '8000') |
|
93 | >>> geturlcgivars("http://host", '8000') | |
94 | ('host', '8000', '/') |
|
94 | ('host', '8000', '/') | |
95 | >>> geturlcgivars("http://host/", '8000') |
|
95 | >>> geturlcgivars("http://host/", '8000') | |
96 | ('host', '8000', '/') |
|
96 | ('host', '8000', '/') | |
97 | """ |
|
97 | """ | |
98 | u = util.url(baseurl) |
|
98 | u = util.url(baseurl) | |
99 | name = u.host or '' |
|
99 | name = u.host or '' | |
100 | if u.port: |
|
100 | if u.port: | |
101 | port = u.port |
|
101 | port = u.port | |
102 | path = u.path or "" |
|
102 | path = u.path or "" | |
103 | if not path.startswith('/'): |
|
103 | if not path.startswith('/'): | |
104 | path = '/' + path |
|
104 | path = '/' + path | |
105 |
|
105 | |||
106 | return name, str(port), path |
|
106 | return name, str(port), path | |
107 |
|
107 | |||
108 | class hgwebdir(object): |
|
108 | class hgwebdir(object): | |
109 | """HTTP server for multiple repositories. |
|
109 | """HTTP server for multiple repositories. | |
110 |
|
110 | |||
111 | Given a configuration, different repositories will be served depending |
|
111 | Given a configuration, different repositories will be served depending | |
112 | on the request path. |
|
112 | on the request path. | |
113 |
|
113 | |||
114 | Instances are typically used as WSGI applications. |
|
114 | Instances are typically used as WSGI applications. | |
115 | """ |
|
115 | """ | |
116 | def __init__(self, conf, baseui=None): |
|
116 | def __init__(self, conf, baseui=None): | |
117 | self.conf = conf |
|
117 | self.conf = conf | |
118 | self.baseui = baseui |
|
118 | self.baseui = baseui | |
119 | self.ui = None |
|
119 | self.ui = None | |
120 | self.lastrefresh = 0 |
|
120 | self.lastrefresh = 0 | |
121 | self.motd = None |
|
121 | self.motd = None | |
122 | self.refresh() |
|
122 | self.refresh() | |
123 |
|
123 | |||
124 | def refresh(self): |
|
124 | def refresh(self): | |
125 | refreshinterval = 20 |
|
125 | refreshinterval = 20 | |
126 | if self.ui: |
|
126 | if self.ui: | |
127 | refreshinterval = self.ui.configint('web', 'refreshinterval', |
|
127 | refreshinterval = self.ui.configint('web', 'refreshinterval', | |
128 | refreshinterval) |
|
128 | refreshinterval) | |
129 |
|
129 | |||
130 | # refreshinterval <= 0 means to always refresh. |
|
130 | # refreshinterval <= 0 means to always refresh. | |
131 | if (refreshinterval > 0 and |
|
131 | if (refreshinterval > 0 and | |
132 | self.lastrefresh + refreshinterval > time.time()): |
|
132 | self.lastrefresh + refreshinterval > time.time()): | |
133 | return |
|
133 | return | |
134 |
|
134 | |||
135 | if self.baseui: |
|
135 | if self.baseui: | |
136 | u = self.baseui.copy() |
|
136 | u = self.baseui.copy() | |
137 | else: |
|
137 | else: | |
138 | u = uimod.ui() |
|
138 | u = uimod.ui() | |
139 | u.setconfig('ui', 'report_untrusted', 'off', 'hgwebdir') |
|
139 | u.setconfig('ui', 'report_untrusted', 'off', 'hgwebdir') | |
140 | u.setconfig('ui', 'nontty', 'true', 'hgwebdir') |
|
140 | u.setconfig('ui', 'nontty', 'true', 'hgwebdir') | |
141 | # displaying bundling progress bar while serving feels wrong and may |
|
141 | # displaying bundling progress bar while serving feels wrong and may | |
142 | # break some wsgi implementations. |
|
142 | # break some wsgi implementations. | |
143 | u.setconfig('progress', 'disable', 'true', 'hgweb') |
|
143 | u.setconfig('progress', 'disable', 'true', 'hgweb') | |
144 |
|
144 | |||
145 | if not isinstance(self.conf, (dict, list, tuple)): |
|
145 | if not isinstance(self.conf, (dict, list, tuple)): | |
146 | map = {'paths': 'hgweb-paths'} |
|
146 | map = {'paths': 'hgweb-paths'} | |
147 | if not os.path.exists(self.conf): |
|
147 | if not os.path.exists(self.conf): | |
148 | raise error.Abort(_('config file %s not found!') % self.conf) |
|
148 | raise error.Abort(_('config file %s not found!') % self.conf) | |
149 | u.readconfig(self.conf, remap=map, trust=True) |
|
149 | u.readconfig(self.conf, remap=map, trust=True) | |
150 | paths = [] |
|
150 | paths = [] | |
151 | for name, ignored in u.configitems('hgweb-paths'): |
|
151 | for name, ignored in u.configitems('hgweb-paths'): | |
152 | for path in u.configlist('hgweb-paths', name): |
|
152 | for path in u.configlist('hgweb-paths', name): | |
153 | paths.append((name, path)) |
|
153 | paths.append((name, path)) | |
154 | elif isinstance(self.conf, (list, tuple)): |
|
154 | elif isinstance(self.conf, (list, tuple)): | |
155 | paths = self.conf |
|
155 | paths = self.conf | |
156 | elif isinstance(self.conf, dict): |
|
156 | elif isinstance(self.conf, dict): | |
157 | paths = self.conf.items() |
|
157 | paths = self.conf.items() | |
158 |
|
158 | |||
159 | repos = findrepos(paths) |
|
159 | repos = findrepos(paths) | |
160 | for prefix, root in u.configitems('collections'): |
|
160 | for prefix, root in u.configitems('collections'): | |
161 | prefix = util.pconvert(prefix) |
|
161 | prefix = util.pconvert(prefix) | |
162 | for path in scmutil.walkrepos(root, followsym=True): |
|
162 | for path in scmutil.walkrepos(root, followsym=True): | |
163 | repo = os.path.normpath(path) |
|
163 | repo = os.path.normpath(path) | |
164 | name = util.pconvert(repo) |
|
164 | name = util.pconvert(repo) | |
165 | if name.startswith(prefix): |
|
165 | if name.startswith(prefix): | |
166 | name = name[len(prefix):] |
|
166 | name = name[len(prefix):] | |
167 | repos.append((name.lstrip('/'), repo)) |
|
167 | repos.append((name.lstrip('/'), repo)) | |
168 |
|
168 | |||
169 | self.repos = repos |
|
169 | self.repos = repos | |
170 | self.ui = u |
|
170 | self.ui = u | |
171 | encoding.encoding = self.ui.config('web', 'encoding', |
|
171 | encoding.encoding = self.ui.config('web', 'encoding', | |
172 | encoding.encoding) |
|
172 | encoding.encoding) | |
173 | self.style = self.ui.config('web', 'style', 'paper') |
|
173 | self.style = self.ui.config('web', 'style', 'paper') | |
174 | self.templatepath = self.ui.config('web', 'templates', None) |
|
174 | self.templatepath = self.ui.config('web', 'templates', None) | |
175 | self.stripecount = self.ui.config('web', 'stripes', 1) |
|
175 | self.stripecount = self.ui.config('web', 'stripes', 1) | |
176 | if self.stripecount: |
|
176 | if self.stripecount: | |
177 | self.stripecount = int(self.stripecount) |
|
177 | self.stripecount = int(self.stripecount) | |
178 | self._baseurl = self.ui.config('web', 'baseurl') |
|
178 | self._baseurl = self.ui.config('web', 'baseurl') | |
179 | prefix = self.ui.config('web', 'prefix', '') |
|
179 | prefix = self.ui.config('web', 'prefix', '') | |
180 | if prefix.startswith('/'): |
|
180 | if prefix.startswith('/'): | |
181 | prefix = prefix[1:] |
|
181 | prefix = prefix[1:] | |
182 | if prefix.endswith('/'): |
|
182 | if prefix.endswith('/'): | |
183 | prefix = prefix[:-1] |
|
183 | prefix = prefix[:-1] | |
184 | self.prefix = prefix |
|
184 | self.prefix = prefix | |
185 | self.lastrefresh = time.time() |
|
185 | self.lastrefresh = time.time() | |
186 |
|
186 | |||
187 | def run(self): |
|
187 | def run(self): | |
188 | if not os.environ.get('GATEWAY_INTERFACE', '').startswith("CGI/1."): |
|
188 | if not os.environ.get('GATEWAY_INTERFACE', '').startswith("CGI/1."): | |
189 | raise RuntimeError("This function is only intended to be " |
|
189 | raise RuntimeError("This function is only intended to be " | |
190 | "called while running as a CGI script.") |
|
190 | "called while running as a CGI script.") | |
191 | wsgicgi.launch(self) |
|
191 | wsgicgi.launch(self) | |
192 |
|
192 | |||
193 | def __call__(self, env, respond): |
|
193 | def __call__(self, env, respond): | |
194 | req = wsgirequest(env, respond) |
|
194 | req = wsgirequest(env, respond) | |
195 | return self.run_wsgi(req) |
|
195 | return self.run_wsgi(req) | |
196 |
|
196 | |||
197 | def read_allowed(self, ui, req): |
|
197 | def read_allowed(self, ui, req): | |
198 | """Check allow_read and deny_read config options of a repo's ui object |
|
198 | """Check allow_read and deny_read config options of a repo's ui object | |
199 | to determine user permissions. By default, with neither option set (or |
|
199 | to determine user permissions. By default, with neither option set (or | |
200 | both empty), allow all users to read the repo. There are two ways a |
|
200 | both empty), allow all users to read the repo. There are two ways a | |
201 | user can be denied read access: (1) deny_read is not empty, and the |
|
201 | user can be denied read access: (1) deny_read is not empty, and the | |
202 | user is unauthenticated or deny_read contains user (or *), and (2) |
|
202 | user is unauthenticated or deny_read contains user (or *), and (2) | |
203 | allow_read is not empty and the user is not in allow_read. Return True |
|
203 | allow_read is not empty and the user is not in allow_read. Return True | |
204 | if user is allowed to read the repo, else return False.""" |
|
204 | if user is allowed to read the repo, else return False.""" | |
205 |
|
205 | |||
206 | user = req.env.get('REMOTE_USER') |
|
206 | user = req.env.get('REMOTE_USER') | |
207 |
|
207 | |||
208 | deny_read = ui.configlist('web', 'deny_read', untrusted=True) |
|
208 | deny_read = ui.configlist('web', 'deny_read', untrusted=True) | |
209 | if deny_read and (not user or ismember(ui, user, deny_read)): |
|
209 | if deny_read and (not user or ismember(ui, user, deny_read)): | |
210 | return False |
|
210 | return False | |
211 |
|
211 | |||
212 | allow_read = ui.configlist('web', 'allow_read', untrusted=True) |
|
212 | allow_read = ui.configlist('web', 'allow_read', untrusted=True) | |
213 | # by default, allow reading if no allow_read option has been set |
|
213 | # by default, allow reading if no allow_read option has been set | |
214 | if (not allow_read) or ismember(ui, user, allow_read): |
|
214 | if (not allow_read) or ismember(ui, user, allow_read): | |
215 | return True |
|
215 | return True | |
216 |
|
216 | |||
217 | return False |
|
217 | return False | |
218 |
|
218 | |||
219 | def run_wsgi(self, req): |
|
219 | def run_wsgi(self, req): | |
220 | try: |
|
220 | try: | |
221 | self.refresh() |
|
221 | self.refresh() | |
222 |
|
222 | |||
223 | virtual = req.env.get("PATH_INFO", "").strip('/') |
|
223 | virtual = req.env.get("PATH_INFO", "").strip('/') | |
224 | tmpl = self.templater(req) |
|
224 | tmpl = self.templater(req) | |
225 | ctype = tmpl('mimetype', encoding=encoding.encoding) |
|
225 | ctype = tmpl('mimetype', encoding=encoding.encoding) | |
226 | ctype = templater.stringify(ctype) |
|
226 | ctype = templater.stringify(ctype) | |
227 |
|
227 | |||
228 | # a static file |
|
228 | # a static file | |
229 | if virtual.startswith('static/') or 'static' in req.form: |
|
229 | if virtual.startswith('static/') or 'static' in req.form: | |
230 | if virtual.startswith('static/'): |
|
230 | if virtual.startswith('static/'): | |
231 | fname = virtual[7:] |
|
231 | fname = virtual[7:] | |
232 | else: |
|
232 | else: | |
233 | fname = req.form['static'][0] |
|
233 | fname = req.form['static'][0] | |
234 | static = self.ui.config("web", "static", None, |
|
234 | static = self.ui.config("web", "static", None, | |
235 | untrusted=False) |
|
235 | untrusted=False) | |
236 | if not static: |
|
236 | if not static: | |
237 | tp = self.templatepath or templater.templatepaths() |
|
237 | tp = self.templatepath or templater.templatepaths() | |
238 | if isinstance(tp, str): |
|
238 | if isinstance(tp, str): | |
239 | tp = [tp] |
|
239 | tp = [tp] | |
240 | static = [os.path.join(p, 'static') for p in tp] |
|
240 | static = [os.path.join(p, 'static') for p in tp] | |
241 | staticfile(static, fname, req) |
|
241 | staticfile(static, fname, req) | |
242 | return [] |
|
242 | return [] | |
243 |
|
243 | |||
244 | # top-level index |
|
244 | # top-level index | |
245 | elif not virtual: |
|
245 | elif not virtual: | |
246 | req.respond(HTTP_OK, ctype) |
|
246 | req.respond(HTTP_OK, ctype) | |
247 | return self.makeindex(req, tmpl) |
|
247 | return self.makeindex(req, tmpl) | |
248 |
|
248 | |||
249 | # nested indexes and hgwebs |
|
249 | # nested indexes and hgwebs | |
250 |
|
250 | |||
251 | repos = dict(self.repos) |
|
251 | repos = dict(self.repos) | |
252 | virtualrepo = virtual |
|
252 | virtualrepo = virtual | |
253 | while virtualrepo: |
|
253 | while virtualrepo: | |
254 | real = repos.get(virtualrepo) |
|
254 | real = repos.get(virtualrepo) | |
255 | if real: |
|
255 | if real: | |
256 | req.env['REPO_NAME'] = virtualrepo |
|
256 | req.env['REPO_NAME'] = virtualrepo | |
257 | try: |
|
257 | try: | |
258 | # ensure caller gets private copy of ui |
|
258 | # ensure caller gets private copy of ui | |
259 | repo = hg.repository(self.ui.copy(), real) |
|
259 | repo = hg.repository(self.ui.copy(), real) | |
260 | return hgweb_mod.hgweb(repo).run_wsgi(req) |
|
260 | return hgweb_mod.hgweb(repo).run_wsgi(req) | |
261 | except IOError as inst: |
|
261 | except IOError as inst: | |
262 | msg = inst.strerror |
|
262 | msg = inst.strerror | |
263 | raise ErrorResponse(HTTP_SERVER_ERROR, msg) |
|
263 | raise ErrorResponse(HTTP_SERVER_ERROR, msg) | |
264 | except error.RepoError as inst: |
|
264 | except error.RepoError as inst: | |
265 | raise ErrorResponse(HTTP_SERVER_ERROR, str(inst)) |
|
265 | raise ErrorResponse(HTTP_SERVER_ERROR, str(inst)) | |
266 |
|
266 | |||
267 | up = virtualrepo.rfind('/') |
|
267 | up = virtualrepo.rfind('/') | |
268 | if up < 0: |
|
268 | if up < 0: | |
269 | break |
|
269 | break | |
270 | virtualrepo = virtualrepo[:up] |
|
270 | virtualrepo = virtualrepo[:up] | |
271 |
|
271 | |||
272 | # browse subdirectories |
|
272 | # browse subdirectories | |
273 | subdir = virtual + '/' |
|
273 | subdir = virtual + '/' | |
274 | if [r for r in repos if r.startswith(subdir)]: |
|
274 | if [r for r in repos if r.startswith(subdir)]: | |
275 | req.respond(HTTP_OK, ctype) |
|
275 | req.respond(HTTP_OK, ctype) | |
276 | return self.makeindex(req, tmpl, subdir) |
|
276 | return self.makeindex(req, tmpl, subdir) | |
277 |
|
277 | |||
278 | # prefixes not found |
|
278 | # prefixes not found | |
279 | req.respond(HTTP_NOT_FOUND, ctype) |
|
279 | req.respond(HTTP_NOT_FOUND, ctype) | |
280 | return tmpl("notfound", repo=virtual) |
|
280 | return tmpl("notfound", repo=virtual) | |
281 |
|
281 | |||
282 | except ErrorResponse as err: |
|
282 | except ErrorResponse as err: | |
283 | req.respond(err, ctype) |
|
283 | req.respond(err, ctype) | |
284 | return tmpl('error', error=err.message or '') |
|
284 | return tmpl('error', error=err.message or '') | |
285 | finally: |
|
285 | finally: | |
286 | tmpl = None |
|
286 | tmpl = None | |
287 |
|
287 | |||
288 | def makeindex(self, req, tmpl, subdir=""): |
|
288 | def makeindex(self, req, tmpl, subdir=""): | |
289 |
|
289 | |||
290 | def archivelist(ui, nodeid, url): |
|
290 | def archivelist(ui, nodeid, url): | |
291 | allowed = ui.configlist("web", "allow_archive", untrusted=True) |
|
291 | allowed = ui.configlist("web", "allow_archive", untrusted=True) | |
292 | archives = [] |
|
292 | archives = [] | |
293 | for i in [('zip', '.zip'), ('gz', '.tar.gz'), ('bz2', '.tar.bz2')]: |
|
293 | for i in [('zip', '.zip'), ('gz', '.tar.gz'), ('bz2', '.tar.bz2')]: | |
294 | if i[0] in allowed or ui.configbool("web", "allow" + i[0], |
|
294 | if i[0] in allowed or ui.configbool("web", "allow" + i[0], | |
295 | untrusted=True): |
|
295 | untrusted=True): | |
296 | archives.append({"type" : i[0], "extension": i[1], |
|
296 | archives.append({"type" : i[0], "extension": i[1], | |
297 | "node": nodeid, "url": url}) |
|
297 | "node": nodeid, "url": url}) | |
298 | return archives |
|
298 | return archives | |
299 |
|
299 | |||
300 | def rawentries(subdir="", **map): |
|
300 | def rawentries(subdir="", **map): | |
301 |
|
301 | |||
302 | descend = self.ui.configbool('web', 'descend', True) |
|
302 | descend = self.ui.configbool('web', 'descend', True) | |
303 | collapse = self.ui.configbool('web', 'collapse', False) |
|
303 | collapse = self.ui.configbool('web', 'collapse', False) | |
304 | seenrepos = set() |
|
304 | seenrepos = set() | |
305 | seendirs = set() |
|
305 | seendirs = set() | |
306 | for name, path in self.repos: |
|
306 | for name, path in self.repos: | |
307 |
|
307 | |||
308 | if not name.startswith(subdir): |
|
308 | if not name.startswith(subdir): | |
309 | continue |
|
309 | continue | |
310 | name = name[len(subdir):] |
|
310 | name = name[len(subdir):] | |
311 | directory = False |
|
311 | directory = False | |
312 |
|
312 | |||
313 | if '/' in name: |
|
313 | if '/' in name: | |
314 | if not descend: |
|
314 | if not descend: | |
315 | continue |
|
315 | continue | |
316 |
|
316 | |||
317 | nameparts = name.split('/') |
|
317 | nameparts = name.split('/') | |
318 | rootname = nameparts[0] |
|
318 | rootname = nameparts[0] | |
319 |
|
319 | |||
320 | if not collapse: |
|
320 | if not collapse: | |
321 | pass |
|
321 | pass | |
322 | elif rootname in seendirs: |
|
322 | elif rootname in seendirs: | |
323 | continue |
|
323 | continue | |
324 | elif rootname in seenrepos: |
|
324 | elif rootname in seenrepos: | |
325 | pass |
|
325 | pass | |
326 | else: |
|
326 | else: | |
327 | directory = True |
|
327 | directory = True | |
328 | name = rootname |
|
328 | name = rootname | |
329 |
|
329 | |||
330 | # redefine the path to refer to the directory |
|
330 | # redefine the path to refer to the directory | |
331 | discarded = '/'.join(nameparts[1:]) |
|
331 | discarded = '/'.join(nameparts[1:]) | |
332 |
|
332 | |||
333 | # remove name parts plus accompanying slash |
|
333 | # remove name parts plus accompanying slash | |
334 | path = path[:-len(discarded) - 1] |
|
334 | path = path[:-len(discarded) - 1] | |
335 |
|
335 | |||
336 | try: |
|
336 | try: | |
337 | r = hg.repository(self.ui, path) |
|
337 | r = hg.repository(self.ui, path) | |
338 | directory = False |
|
338 | directory = False | |
339 | except (IOError, error.RepoError): |
|
339 | except (IOError, error.RepoError): | |
340 | pass |
|
340 | pass | |
341 |
|
341 | |||
342 | parts = [name] |
|
342 | parts = [name] | |
343 | if 'PATH_INFO' in req.env: |
|
343 | if 'PATH_INFO' in req.env: | |
344 | parts.insert(0, req.env['PATH_INFO'].rstrip('/')) |
|
344 | parts.insert(0, req.env['PATH_INFO'].rstrip('/')) | |
345 | if req.env['SCRIPT_NAME']: |
|
345 | if req.env['SCRIPT_NAME']: | |
346 | parts.insert(0, req.env['SCRIPT_NAME']) |
|
346 | parts.insert(0, req.env['SCRIPT_NAME']) | |
347 | url = re.sub(r'/+', '/', '/'.join(parts) + '/') |
|
347 | url = re.sub(r'/+', '/', '/'.join(parts) + '/') | |
348 |
|
348 | |||
349 | # show either a directory entry or a repository |
|
349 | # show either a directory entry or a repository | |
350 | if directory: |
|
350 | if directory: | |
351 | # get the directory's time information |
|
351 | # get the directory's time information | |
352 | try: |
|
352 | try: | |
353 | d = (get_mtime(path), util.makedate()[1]) |
|
353 | d = (get_mtime(path), util.makedate()[1]) | |
354 | except OSError: |
|
354 | except OSError: | |
355 | continue |
|
355 | continue | |
356 |
|
356 | |||
357 | # add '/' to the name to make it obvious that |
|
357 | # add '/' to the name to make it obvious that | |
358 | # the entry is a directory, not a regular repository |
|
358 | # the entry is a directory, not a regular repository | |
359 | row = {'contact': "", |
|
359 | row = {'contact': "", | |
360 | 'contact_sort': "", |
|
360 | 'contact_sort': "", | |
361 | 'name': name + '/', |
|
361 | 'name': name + '/', | |
362 | 'name_sort': name, |
|
362 | 'name_sort': name, | |
363 | 'url': url, |
|
363 | 'url': url, | |
364 | 'description': "", |
|
364 | 'description': "", | |
365 | 'description_sort': "", |
|
365 | 'description_sort': "", | |
366 | 'lastchange': d, |
|
366 | 'lastchange': d, | |
367 | 'lastchange_sort': d[1]-d[0], |
|
367 | 'lastchange_sort': d[1]-d[0], | |
368 | 'archives': [], |
|
368 | 'archives': [], | |
369 |
'isdirectory': True |
|
369 | 'isdirectory': True, | |
|
370 | 'labels': [], | |||
|
371 | } | |||
370 |
|
372 | |||
371 | seendirs.add(name) |
|
373 | seendirs.add(name) | |
372 | yield row |
|
374 | yield row | |
373 | continue |
|
375 | continue | |
374 |
|
376 | |||
375 | u = self.ui.copy() |
|
377 | u = self.ui.copy() | |
376 | try: |
|
378 | try: | |
377 | u.readconfig(os.path.join(path, '.hg', 'hgrc')) |
|
379 | u.readconfig(os.path.join(path, '.hg', 'hgrc')) | |
378 | except Exception as e: |
|
380 | except Exception as e: | |
379 | u.warn(_('error reading %s/.hg/hgrc: %s\n') % (path, e)) |
|
381 | u.warn(_('error reading %s/.hg/hgrc: %s\n') % (path, e)) | |
380 | continue |
|
382 | continue | |
381 | def get(section, name, default=None): |
|
383 | def get(section, name, default=None): | |
382 | return u.config(section, name, default, untrusted=True) |
|
384 | return u.config(section, name, default, untrusted=True) | |
383 |
|
385 | |||
384 | if u.configbool("web", "hidden", untrusted=True): |
|
386 | if u.configbool("web", "hidden", untrusted=True): | |
385 | continue |
|
387 | continue | |
386 |
|
388 | |||
387 | if not self.read_allowed(u, req): |
|
389 | if not self.read_allowed(u, req): | |
388 | continue |
|
390 | continue | |
389 |
|
391 | |||
390 | # update time with local timezone |
|
392 | # update time with local timezone | |
391 | try: |
|
393 | try: | |
392 | r = hg.repository(self.ui, path) |
|
394 | r = hg.repository(self.ui, path) | |
393 | except IOError: |
|
395 | except IOError: | |
394 | u.warn(_('error accessing repository at %s\n') % path) |
|
396 | u.warn(_('error accessing repository at %s\n') % path) | |
395 | continue |
|
397 | continue | |
396 | except error.RepoError: |
|
398 | except error.RepoError: | |
397 | u.warn(_('error accessing repository at %s\n') % path) |
|
399 | u.warn(_('error accessing repository at %s\n') % path) | |
398 | continue |
|
400 | continue | |
399 | try: |
|
401 | try: | |
400 | d = (get_mtime(r.spath), util.makedate()[1]) |
|
402 | d = (get_mtime(r.spath), util.makedate()[1]) | |
401 | except OSError: |
|
403 | except OSError: | |
402 | continue |
|
404 | continue | |
403 |
|
405 | |||
404 | contact = get_contact(get) |
|
406 | contact = get_contact(get) | |
405 | description = get("web", "description", "") |
|
407 | description = get("web", "description", "") | |
406 | seenrepos.add(name) |
|
408 | seenrepos.add(name) | |
407 | name = get("web", "name", name) |
|
409 | name = get("web", "name", name) | |
408 | row = {'contact': contact or "unknown", |
|
410 | row = {'contact': contact or "unknown", | |
409 | 'contact_sort': contact.upper() or "unknown", |
|
411 | 'contact_sort': contact.upper() or "unknown", | |
410 | 'name': name, |
|
412 | 'name': name, | |
411 | 'name_sort': name, |
|
413 | 'name_sort': name, | |
412 | 'url': url, |
|
414 | 'url': url, | |
413 | 'description': description or "unknown", |
|
415 | 'description': description or "unknown", | |
414 | 'description_sort': description.upper() or "unknown", |
|
416 | 'description_sort': description.upper() or "unknown", | |
415 | 'lastchange': d, |
|
417 | 'lastchange': d, | |
416 | 'lastchange_sort': d[1]-d[0], |
|
418 | 'lastchange_sort': d[1]-d[0], | |
417 | 'archives': archivelist(u, "tip", url), |
|
419 | 'archives': archivelist(u, "tip", url), | |
418 | 'isdirectory': None, |
|
420 | 'isdirectory': None, | |
|
421 | 'labels': u.configlist('web', 'labels', untrusted=True), | |||
419 | } |
|
422 | } | |
420 |
|
423 | |||
421 | yield row |
|
424 | yield row | |
422 |
|
425 | |||
423 | sortdefault = None, False |
|
426 | sortdefault = None, False | |
424 | def entries(sortcolumn="", descending=False, subdir="", **map): |
|
427 | def entries(sortcolumn="", descending=False, subdir="", **map): | |
425 | rows = rawentries(subdir=subdir, **map) |
|
428 | rows = rawentries(subdir=subdir, **map) | |
426 |
|
429 | |||
427 | if sortcolumn and sortdefault != (sortcolumn, descending): |
|
430 | if sortcolumn and sortdefault != (sortcolumn, descending): | |
428 | sortkey = '%s_sort' % sortcolumn |
|
431 | sortkey = '%s_sort' % sortcolumn | |
429 | rows = sorted(rows, key=lambda x: x[sortkey], |
|
432 | rows = sorted(rows, key=lambda x: x[sortkey], | |
430 | reverse=descending) |
|
433 | reverse=descending) | |
431 | for row, parity in zip(rows, paritygen(self.stripecount)): |
|
434 | for row, parity in zip(rows, paritygen(self.stripecount)): | |
432 | row['parity'] = parity |
|
435 | row['parity'] = parity | |
433 | yield row |
|
436 | yield row | |
434 |
|
437 | |||
435 | self.refresh() |
|
438 | self.refresh() | |
436 | sortable = ["name", "description", "contact", "lastchange"] |
|
439 | sortable = ["name", "description", "contact", "lastchange"] | |
437 | sortcolumn, descending = sortdefault |
|
440 | sortcolumn, descending = sortdefault | |
438 | if 'sort' in req.form: |
|
441 | if 'sort' in req.form: | |
439 | sortcolumn = req.form['sort'][0] |
|
442 | sortcolumn = req.form['sort'][0] | |
440 | descending = sortcolumn.startswith('-') |
|
443 | descending = sortcolumn.startswith('-') | |
441 | if descending: |
|
444 | if descending: | |
442 | sortcolumn = sortcolumn[1:] |
|
445 | sortcolumn = sortcolumn[1:] | |
443 | if sortcolumn not in sortable: |
|
446 | if sortcolumn not in sortable: | |
444 | sortcolumn = "" |
|
447 | sortcolumn = "" | |
445 |
|
448 | |||
446 | sort = [("sort_%s" % column, |
|
449 | sort = [("sort_%s" % column, | |
447 | "%s%s" % ((not descending and column == sortcolumn) |
|
450 | "%s%s" % ((not descending and column == sortcolumn) | |
448 | and "-" or "", column)) |
|
451 | and "-" or "", column)) | |
449 | for column in sortable] |
|
452 | for column in sortable] | |
450 |
|
453 | |||
451 | self.refresh() |
|
454 | self.refresh() | |
452 | self.updatereqenv(req.env) |
|
455 | self.updatereqenv(req.env) | |
453 |
|
456 | |||
454 | return tmpl("index", entries=entries, subdir=subdir, |
|
457 | return tmpl("index", entries=entries, subdir=subdir, | |
455 | pathdef=hgweb_mod.makebreadcrumb('/' + subdir, self.prefix), |
|
458 | pathdef=hgweb_mod.makebreadcrumb('/' + subdir, self.prefix), | |
456 | sortcolumn=sortcolumn, descending=descending, |
|
459 | sortcolumn=sortcolumn, descending=descending, | |
457 | **dict(sort)) |
|
460 | **dict(sort)) | |
458 |
|
461 | |||
459 | def templater(self, req): |
|
462 | def templater(self, req): | |
460 |
|
463 | |||
461 | def motd(**map): |
|
464 | def motd(**map): | |
462 | if self.motd is not None: |
|
465 | if self.motd is not None: | |
463 | yield self.motd |
|
466 | yield self.motd | |
464 | else: |
|
467 | else: | |
465 | yield config('web', 'motd', '') |
|
468 | yield config('web', 'motd', '') | |
466 |
|
469 | |||
467 | def config(section, name, default=None, untrusted=True): |
|
470 | def config(section, name, default=None, untrusted=True): | |
468 | return self.ui.config(section, name, default, untrusted) |
|
471 | return self.ui.config(section, name, default, untrusted) | |
469 |
|
472 | |||
470 | self.updatereqenv(req.env) |
|
473 | self.updatereqenv(req.env) | |
471 |
|
474 | |||
472 | url = req.env.get('SCRIPT_NAME', '') |
|
475 | url = req.env.get('SCRIPT_NAME', '') | |
473 | if not url.endswith('/'): |
|
476 | if not url.endswith('/'): | |
474 | url += '/' |
|
477 | url += '/' | |
475 |
|
478 | |||
476 | vars = {} |
|
479 | vars = {} | |
477 | styles = ( |
|
480 | styles = ( | |
478 | req.form.get('style', [None])[0], |
|
481 | req.form.get('style', [None])[0], | |
479 | config('web', 'style'), |
|
482 | config('web', 'style'), | |
480 | 'paper' |
|
483 | 'paper' | |
481 | ) |
|
484 | ) | |
482 | style, mapfile = templater.stylemap(styles, self.templatepath) |
|
485 | style, mapfile = templater.stylemap(styles, self.templatepath) | |
483 | if style == styles[0]: |
|
486 | if style == styles[0]: | |
484 | vars['style'] = style |
|
487 | vars['style'] = style | |
485 |
|
488 | |||
486 | start = url[-1] == '?' and '&' or '?' |
|
489 | start = url[-1] == '?' and '&' or '?' | |
487 | sessionvars = webutil.sessionvars(vars, start) |
|
490 | sessionvars = webutil.sessionvars(vars, start) | |
488 | logourl = config('web', 'logourl', 'https://mercurial-scm.org/') |
|
491 | logourl = config('web', 'logourl', 'https://mercurial-scm.org/') | |
489 | logoimg = config('web', 'logoimg', 'hglogo.png') |
|
492 | logoimg = config('web', 'logoimg', 'hglogo.png') | |
490 | staticurl = config('web', 'staticurl') or url + 'static/' |
|
493 | staticurl = config('web', 'staticurl') or url + 'static/' | |
491 | if not staticurl.endswith('/'): |
|
494 | if not staticurl.endswith('/'): | |
492 | staticurl += '/' |
|
495 | staticurl += '/' | |
493 |
|
496 | |||
494 | defaults = { |
|
497 | defaults = { | |
495 | "encoding": encoding.encoding, |
|
498 | "encoding": encoding.encoding, | |
496 | "motd": motd, |
|
499 | "motd": motd, | |
497 | "url": url, |
|
500 | "url": url, | |
498 | "logourl": logourl, |
|
501 | "logourl": logourl, | |
499 | "logoimg": logoimg, |
|
502 | "logoimg": logoimg, | |
500 | "staticurl": staticurl, |
|
503 | "staticurl": staticurl, | |
501 | "sessionvars": sessionvars, |
|
504 | "sessionvars": sessionvars, | |
502 | "style": style, |
|
505 | "style": style, | |
503 | } |
|
506 | } | |
504 | tmpl = templater.templater.frommapfile(mapfile, defaults=defaults) |
|
507 | tmpl = templater.templater.frommapfile(mapfile, defaults=defaults) | |
505 | return tmpl |
|
508 | return tmpl | |
506 |
|
509 | |||
507 | def updatereqenv(self, env): |
|
510 | def updatereqenv(self, env): | |
508 | if self._baseurl is not None: |
|
511 | if self._baseurl is not None: | |
509 | name, port, path = geturlcgivars(self._baseurl, env['SERVER_PORT']) |
|
512 | name, port, path = geturlcgivars(self._baseurl, env['SERVER_PORT']) | |
510 | env['SERVER_NAME'] = name |
|
513 | env['SERVER_NAME'] = name | |
511 | env['SERVER_PORT'] = port |
|
514 | env['SERVER_PORT'] = port | |
512 | env['SCRIPT_NAME'] = path |
|
515 | env['SCRIPT_NAME'] = path |
@@ -1,1303 +1,1304 b'' | |||||
1 | # |
|
1 | # | |
2 | # Copyright 21 May 2005 - (c) 2005 Jake Edge <jake@edge2.net> |
|
2 | # Copyright 21 May 2005 - (c) 2005 Jake Edge <jake@edge2.net> | |
3 | # Copyright 2005-2007 Matt Mackall <mpm@selenic.com> |
|
3 | # Copyright 2005-2007 Matt Mackall <mpm@selenic.com> | |
4 | # |
|
4 | # | |
5 | # This software may be used and distributed according to the terms of the |
|
5 | # This software may be used and distributed according to the terms of the | |
6 | # GNU General Public License version 2 or any later version. |
|
6 | # GNU General Public License version 2 or any later version. | |
7 |
|
7 | |||
8 | from __future__ import absolute_import |
|
8 | from __future__ import absolute_import | |
9 |
|
9 | |||
10 | import cgi |
|
10 | import cgi | |
11 | import copy |
|
11 | import copy | |
12 | import mimetypes |
|
12 | import mimetypes | |
13 | import os |
|
13 | import os | |
14 | import re |
|
14 | import re | |
15 |
|
15 | |||
16 | from ..i18n import _ |
|
16 | from ..i18n import _ | |
17 | from ..node import hex, short |
|
17 | from ..node import hex, short | |
18 |
|
18 | |||
19 | from .common import ( |
|
19 | from .common import ( | |
20 | ErrorResponse, |
|
20 | ErrorResponse, | |
21 | HTTP_FORBIDDEN, |
|
21 | HTTP_FORBIDDEN, | |
22 | HTTP_NOT_FOUND, |
|
22 | HTTP_NOT_FOUND, | |
23 | HTTP_OK, |
|
23 | HTTP_OK, | |
24 | get_contact, |
|
24 | get_contact, | |
25 | paritygen, |
|
25 | paritygen, | |
26 | staticfile, |
|
26 | staticfile, | |
27 | ) |
|
27 | ) | |
28 |
|
28 | |||
29 | from .. import ( |
|
29 | from .. import ( | |
30 | archival, |
|
30 | archival, | |
31 | encoding, |
|
31 | encoding, | |
32 | error, |
|
32 | error, | |
33 | graphmod, |
|
33 | graphmod, | |
34 | patch, |
|
34 | patch, | |
35 | revset, |
|
35 | revset, | |
36 | scmutil, |
|
36 | scmutil, | |
37 | templatefilters, |
|
37 | templatefilters, | |
38 | templater, |
|
38 | templater, | |
39 | util, |
|
39 | util, | |
40 | ) |
|
40 | ) | |
41 |
|
41 | |||
42 | from . import ( |
|
42 | from . import ( | |
43 | webutil, |
|
43 | webutil, | |
44 | ) |
|
44 | ) | |
45 |
|
45 | |||
46 | __all__ = [] |
|
46 | __all__ = [] | |
47 | commands = {} |
|
47 | commands = {} | |
48 |
|
48 | |||
49 | class webcommand(object): |
|
49 | class webcommand(object): | |
50 | """Decorator used to register a web command handler. |
|
50 | """Decorator used to register a web command handler. | |
51 |
|
51 | |||
52 | The decorator takes as its positional arguments the name/path the |
|
52 | The decorator takes as its positional arguments the name/path the | |
53 | command should be accessible under. |
|
53 | command should be accessible under. | |
54 |
|
54 | |||
55 | Usage: |
|
55 | Usage: | |
56 |
|
56 | |||
57 | @webcommand('mycommand') |
|
57 | @webcommand('mycommand') | |
58 | def mycommand(web, req, tmpl): |
|
58 | def mycommand(web, req, tmpl): | |
59 | pass |
|
59 | pass | |
60 | """ |
|
60 | """ | |
61 |
|
61 | |||
62 | def __init__(self, name): |
|
62 | def __init__(self, name): | |
63 | self.name = name |
|
63 | self.name = name | |
64 |
|
64 | |||
65 | def __call__(self, func): |
|
65 | def __call__(self, func): | |
66 | __all__.append(self.name) |
|
66 | __all__.append(self.name) | |
67 | commands[self.name] = func |
|
67 | commands[self.name] = func | |
68 | return func |
|
68 | return func | |
69 |
|
69 | |||
70 | @webcommand('log') |
|
70 | @webcommand('log') | |
71 | def log(web, req, tmpl): |
|
71 | def log(web, req, tmpl): | |
72 | """ |
|
72 | """ | |
73 | /log[/{revision}[/{path}]] |
|
73 | /log[/{revision}[/{path}]] | |
74 | -------------------------- |
|
74 | -------------------------- | |
75 |
|
75 | |||
76 | Show repository or file history. |
|
76 | Show repository or file history. | |
77 |
|
77 | |||
78 | For URLs of the form ``/log/{revision}``, a list of changesets starting at |
|
78 | For URLs of the form ``/log/{revision}``, a list of changesets starting at | |
79 | the specified changeset identifier is shown. If ``{revision}`` is not |
|
79 | the specified changeset identifier is shown. If ``{revision}`` is not | |
80 | defined, the default is ``tip``. This form is equivalent to the |
|
80 | defined, the default is ``tip``. This form is equivalent to the | |
81 | ``changelog`` handler. |
|
81 | ``changelog`` handler. | |
82 |
|
82 | |||
83 | For URLs of the form ``/log/{revision}/{file}``, the history for a specific |
|
83 | For URLs of the form ``/log/{revision}/{file}``, the history for a specific | |
84 | file will be shown. This form is equivalent to the ``filelog`` handler. |
|
84 | file will be shown. This form is equivalent to the ``filelog`` handler. | |
85 | """ |
|
85 | """ | |
86 |
|
86 | |||
87 | if 'file' in req.form and req.form['file'][0]: |
|
87 | if 'file' in req.form and req.form['file'][0]: | |
88 | return filelog(web, req, tmpl) |
|
88 | return filelog(web, req, tmpl) | |
89 | else: |
|
89 | else: | |
90 | return changelog(web, req, tmpl) |
|
90 | return changelog(web, req, tmpl) | |
91 |
|
91 | |||
92 | @webcommand('rawfile') |
|
92 | @webcommand('rawfile') | |
93 | def rawfile(web, req, tmpl): |
|
93 | def rawfile(web, req, tmpl): | |
94 | guessmime = web.configbool('web', 'guessmime', False) |
|
94 | guessmime = web.configbool('web', 'guessmime', False) | |
95 |
|
95 | |||
96 | path = webutil.cleanpath(web.repo, req.form.get('file', [''])[0]) |
|
96 | path = webutil.cleanpath(web.repo, req.form.get('file', [''])[0]) | |
97 | if not path: |
|
97 | if not path: | |
98 | content = manifest(web, req, tmpl) |
|
98 | content = manifest(web, req, tmpl) | |
99 | req.respond(HTTP_OK, web.ctype) |
|
99 | req.respond(HTTP_OK, web.ctype) | |
100 | return content |
|
100 | return content | |
101 |
|
101 | |||
102 | try: |
|
102 | try: | |
103 | fctx = webutil.filectx(web.repo, req) |
|
103 | fctx = webutil.filectx(web.repo, req) | |
104 | except error.LookupError as inst: |
|
104 | except error.LookupError as inst: | |
105 | try: |
|
105 | try: | |
106 | content = manifest(web, req, tmpl) |
|
106 | content = manifest(web, req, tmpl) | |
107 | req.respond(HTTP_OK, web.ctype) |
|
107 | req.respond(HTTP_OK, web.ctype) | |
108 | return content |
|
108 | return content | |
109 | except ErrorResponse: |
|
109 | except ErrorResponse: | |
110 | raise inst |
|
110 | raise inst | |
111 |
|
111 | |||
112 | path = fctx.path() |
|
112 | path = fctx.path() | |
113 | text = fctx.data() |
|
113 | text = fctx.data() | |
114 | mt = 'application/binary' |
|
114 | mt = 'application/binary' | |
115 | if guessmime: |
|
115 | if guessmime: | |
116 | mt = mimetypes.guess_type(path)[0] |
|
116 | mt = mimetypes.guess_type(path)[0] | |
117 | if mt is None: |
|
117 | if mt is None: | |
118 | if util.binary(text): |
|
118 | if util.binary(text): | |
119 | mt = 'application/binary' |
|
119 | mt = 'application/binary' | |
120 | else: |
|
120 | else: | |
121 | mt = 'text/plain' |
|
121 | mt = 'text/plain' | |
122 | if mt.startswith('text/'): |
|
122 | if mt.startswith('text/'): | |
123 | mt += '; charset="%s"' % encoding.encoding |
|
123 | mt += '; charset="%s"' % encoding.encoding | |
124 |
|
124 | |||
125 | req.respond(HTTP_OK, mt, path, body=text) |
|
125 | req.respond(HTTP_OK, mt, path, body=text) | |
126 | return [] |
|
126 | return [] | |
127 |
|
127 | |||
128 | def _filerevision(web, req, tmpl, fctx): |
|
128 | def _filerevision(web, req, tmpl, fctx): | |
129 | f = fctx.path() |
|
129 | f = fctx.path() | |
130 | text = fctx.data() |
|
130 | text = fctx.data() | |
131 | parity = paritygen(web.stripecount) |
|
131 | parity = paritygen(web.stripecount) | |
132 |
|
132 | |||
133 | if util.binary(text): |
|
133 | if util.binary(text): | |
134 | mt = mimetypes.guess_type(f)[0] or 'application/octet-stream' |
|
134 | mt = mimetypes.guess_type(f)[0] or 'application/octet-stream' | |
135 | text = '(binary:%s)' % mt |
|
135 | text = '(binary:%s)' % mt | |
136 |
|
136 | |||
137 | def lines(): |
|
137 | def lines(): | |
138 | for lineno, t in enumerate(text.splitlines(True)): |
|
138 | for lineno, t in enumerate(text.splitlines(True)): | |
139 | yield {"line": t, |
|
139 | yield {"line": t, | |
140 | "lineid": "l%d" % (lineno + 1), |
|
140 | "lineid": "l%d" % (lineno + 1), | |
141 | "linenumber": "% 6d" % (lineno + 1), |
|
141 | "linenumber": "% 6d" % (lineno + 1), | |
142 | "parity": next(parity)} |
|
142 | "parity": next(parity)} | |
143 |
|
143 | |||
144 | return tmpl("filerevision", |
|
144 | return tmpl("filerevision", | |
145 | file=f, |
|
145 | file=f, | |
146 | path=webutil.up(f), |
|
146 | path=webutil.up(f), | |
147 | text=lines(), |
|
147 | text=lines(), | |
148 | symrev=webutil.symrevorshortnode(req, fctx), |
|
148 | symrev=webutil.symrevorshortnode(req, fctx), | |
149 | rename=webutil.renamelink(fctx), |
|
149 | rename=webutil.renamelink(fctx), | |
150 | permissions=fctx.manifest().flags(f), |
|
150 | permissions=fctx.manifest().flags(f), | |
151 | **webutil.commonentry(web.repo, fctx)) |
|
151 | **webutil.commonentry(web.repo, fctx)) | |
152 |
|
152 | |||
153 | @webcommand('file') |
|
153 | @webcommand('file') | |
154 | def file(web, req, tmpl): |
|
154 | def file(web, req, tmpl): | |
155 | """ |
|
155 | """ | |
156 | /file/{revision}[/{path}] |
|
156 | /file/{revision}[/{path}] | |
157 | ------------------------- |
|
157 | ------------------------- | |
158 |
|
158 | |||
159 | Show information about a directory or file in the repository. |
|
159 | Show information about a directory or file in the repository. | |
160 |
|
160 | |||
161 | Info about the ``path`` given as a URL parameter will be rendered. |
|
161 | Info about the ``path`` given as a URL parameter will be rendered. | |
162 |
|
162 | |||
163 | If ``path`` is a directory, information about the entries in that |
|
163 | If ``path`` is a directory, information about the entries in that | |
164 | directory will be rendered. This form is equivalent to the ``manifest`` |
|
164 | directory will be rendered. This form is equivalent to the ``manifest`` | |
165 | handler. |
|
165 | handler. | |
166 |
|
166 | |||
167 | If ``path`` is a file, information about that file will be shown via |
|
167 | If ``path`` is a file, information about that file will be shown via | |
168 | the ``filerevision`` template. |
|
168 | the ``filerevision`` template. | |
169 |
|
169 | |||
170 | If ``path`` is not defined, information about the root directory will |
|
170 | If ``path`` is not defined, information about the root directory will | |
171 | be rendered. |
|
171 | be rendered. | |
172 | """ |
|
172 | """ | |
173 | path = webutil.cleanpath(web.repo, req.form.get('file', [''])[0]) |
|
173 | path = webutil.cleanpath(web.repo, req.form.get('file', [''])[0]) | |
174 | if not path: |
|
174 | if not path: | |
175 | return manifest(web, req, tmpl) |
|
175 | return manifest(web, req, tmpl) | |
176 | try: |
|
176 | try: | |
177 | return _filerevision(web, req, tmpl, webutil.filectx(web.repo, req)) |
|
177 | return _filerevision(web, req, tmpl, webutil.filectx(web.repo, req)) | |
178 | except error.LookupError as inst: |
|
178 | except error.LookupError as inst: | |
179 | try: |
|
179 | try: | |
180 | return manifest(web, req, tmpl) |
|
180 | return manifest(web, req, tmpl) | |
181 | except ErrorResponse: |
|
181 | except ErrorResponse: | |
182 | raise inst |
|
182 | raise inst | |
183 |
|
183 | |||
184 | def _search(web, req, tmpl): |
|
184 | def _search(web, req, tmpl): | |
185 | MODE_REVISION = 'rev' |
|
185 | MODE_REVISION = 'rev' | |
186 | MODE_KEYWORD = 'keyword' |
|
186 | MODE_KEYWORD = 'keyword' | |
187 | MODE_REVSET = 'revset' |
|
187 | MODE_REVSET = 'revset' | |
188 |
|
188 | |||
189 | def revsearch(ctx): |
|
189 | def revsearch(ctx): | |
190 | yield ctx |
|
190 | yield ctx | |
191 |
|
191 | |||
192 | def keywordsearch(query): |
|
192 | def keywordsearch(query): | |
193 | lower = encoding.lower |
|
193 | lower = encoding.lower | |
194 | qw = lower(query).split() |
|
194 | qw = lower(query).split() | |
195 |
|
195 | |||
196 | def revgen(): |
|
196 | def revgen(): | |
197 | cl = web.repo.changelog |
|
197 | cl = web.repo.changelog | |
198 | for i in xrange(len(web.repo) - 1, 0, -100): |
|
198 | for i in xrange(len(web.repo) - 1, 0, -100): | |
199 | l = [] |
|
199 | l = [] | |
200 | for j in cl.revs(max(0, i - 99), i): |
|
200 | for j in cl.revs(max(0, i - 99), i): | |
201 | ctx = web.repo[j] |
|
201 | ctx = web.repo[j] | |
202 | l.append(ctx) |
|
202 | l.append(ctx) | |
203 | l.reverse() |
|
203 | l.reverse() | |
204 | for e in l: |
|
204 | for e in l: | |
205 | yield e |
|
205 | yield e | |
206 |
|
206 | |||
207 | for ctx in revgen(): |
|
207 | for ctx in revgen(): | |
208 | miss = 0 |
|
208 | miss = 0 | |
209 | for q in qw: |
|
209 | for q in qw: | |
210 | if not (q in lower(ctx.user()) or |
|
210 | if not (q in lower(ctx.user()) or | |
211 | q in lower(ctx.description()) or |
|
211 | q in lower(ctx.description()) or | |
212 | q in lower(" ".join(ctx.files()))): |
|
212 | q in lower(" ".join(ctx.files()))): | |
213 | miss = 1 |
|
213 | miss = 1 | |
214 | break |
|
214 | break | |
215 | if miss: |
|
215 | if miss: | |
216 | continue |
|
216 | continue | |
217 |
|
217 | |||
218 | yield ctx |
|
218 | yield ctx | |
219 |
|
219 | |||
220 | def revsetsearch(revs): |
|
220 | def revsetsearch(revs): | |
221 | for r in revs: |
|
221 | for r in revs: | |
222 | yield web.repo[r] |
|
222 | yield web.repo[r] | |
223 |
|
223 | |||
224 | searchfuncs = { |
|
224 | searchfuncs = { | |
225 | MODE_REVISION: (revsearch, 'exact revision search'), |
|
225 | MODE_REVISION: (revsearch, 'exact revision search'), | |
226 | MODE_KEYWORD: (keywordsearch, 'literal keyword search'), |
|
226 | MODE_KEYWORD: (keywordsearch, 'literal keyword search'), | |
227 | MODE_REVSET: (revsetsearch, 'revset expression search'), |
|
227 | MODE_REVSET: (revsetsearch, 'revset expression search'), | |
228 | } |
|
228 | } | |
229 |
|
229 | |||
230 | def getsearchmode(query): |
|
230 | def getsearchmode(query): | |
231 | try: |
|
231 | try: | |
232 | ctx = web.repo[query] |
|
232 | ctx = web.repo[query] | |
233 | except (error.RepoError, error.LookupError): |
|
233 | except (error.RepoError, error.LookupError): | |
234 | # query is not an exact revision pointer, need to |
|
234 | # query is not an exact revision pointer, need to | |
235 | # decide if it's a revset expression or keywords |
|
235 | # decide if it's a revset expression or keywords | |
236 | pass |
|
236 | pass | |
237 | else: |
|
237 | else: | |
238 | return MODE_REVISION, ctx |
|
238 | return MODE_REVISION, ctx | |
239 |
|
239 | |||
240 | revdef = 'reverse(%s)' % query |
|
240 | revdef = 'reverse(%s)' % query | |
241 | try: |
|
241 | try: | |
242 | tree = revset.parse(revdef) |
|
242 | tree = revset.parse(revdef) | |
243 | except error.ParseError: |
|
243 | except error.ParseError: | |
244 | # can't parse to a revset tree |
|
244 | # can't parse to a revset tree | |
245 | return MODE_KEYWORD, query |
|
245 | return MODE_KEYWORD, query | |
246 |
|
246 | |||
247 | if revset.depth(tree) <= 2: |
|
247 | if revset.depth(tree) <= 2: | |
248 | # no revset syntax used |
|
248 | # no revset syntax used | |
249 | return MODE_KEYWORD, query |
|
249 | return MODE_KEYWORD, query | |
250 |
|
250 | |||
251 | if any((token, (value or '')[:3]) == ('string', 're:') |
|
251 | if any((token, (value or '')[:3]) == ('string', 're:') | |
252 | for token, value, pos in revset.tokenize(revdef)): |
|
252 | for token, value, pos in revset.tokenize(revdef)): | |
253 | return MODE_KEYWORD, query |
|
253 | return MODE_KEYWORD, query | |
254 |
|
254 | |||
255 | funcsused = revset.funcsused(tree) |
|
255 | funcsused = revset.funcsused(tree) | |
256 | if not funcsused.issubset(revset.safesymbols): |
|
256 | if not funcsused.issubset(revset.safesymbols): | |
257 | return MODE_KEYWORD, query |
|
257 | return MODE_KEYWORD, query | |
258 |
|
258 | |||
259 | mfunc = revset.match(web.repo.ui, revdef) |
|
259 | mfunc = revset.match(web.repo.ui, revdef) | |
260 | try: |
|
260 | try: | |
261 | revs = mfunc(web.repo) |
|
261 | revs = mfunc(web.repo) | |
262 | return MODE_REVSET, revs |
|
262 | return MODE_REVSET, revs | |
263 | # ParseError: wrongly placed tokens, wrongs arguments, etc |
|
263 | # ParseError: wrongly placed tokens, wrongs arguments, etc | |
264 | # RepoLookupError: no such revision, e.g. in 'revision:' |
|
264 | # RepoLookupError: no such revision, e.g. in 'revision:' | |
265 | # Abort: bookmark/tag not exists |
|
265 | # Abort: bookmark/tag not exists | |
266 | # LookupError: ambiguous identifier, e.g. in '(bc)' on a large repo |
|
266 | # LookupError: ambiguous identifier, e.g. in '(bc)' on a large repo | |
267 | except (error.ParseError, error.RepoLookupError, error.Abort, |
|
267 | except (error.ParseError, error.RepoLookupError, error.Abort, | |
268 | LookupError): |
|
268 | LookupError): | |
269 | return MODE_KEYWORD, query |
|
269 | return MODE_KEYWORD, query | |
270 |
|
270 | |||
271 | def changelist(**map): |
|
271 | def changelist(**map): | |
272 | count = 0 |
|
272 | count = 0 | |
273 |
|
273 | |||
274 | for ctx in searchfunc[0](funcarg): |
|
274 | for ctx in searchfunc[0](funcarg): | |
275 | count += 1 |
|
275 | count += 1 | |
276 | n = ctx.node() |
|
276 | n = ctx.node() | |
277 | showtags = webutil.showtag(web.repo, tmpl, 'changelogtag', n) |
|
277 | showtags = webutil.showtag(web.repo, tmpl, 'changelogtag', n) | |
278 | files = webutil.listfilediffs(tmpl, ctx.files(), n, web.maxfiles) |
|
278 | files = webutil.listfilediffs(tmpl, ctx.files(), n, web.maxfiles) | |
279 |
|
279 | |||
280 | yield tmpl('searchentry', |
|
280 | yield tmpl('searchentry', | |
281 | parity=next(parity), |
|
281 | parity=next(parity), | |
282 | changelogtag=showtags, |
|
282 | changelogtag=showtags, | |
283 | files=files, |
|
283 | files=files, | |
284 | **webutil.commonentry(web.repo, ctx)) |
|
284 | **webutil.commonentry(web.repo, ctx)) | |
285 |
|
285 | |||
286 | if count >= revcount: |
|
286 | if count >= revcount: | |
287 | break |
|
287 | break | |
288 |
|
288 | |||
289 | query = req.form['rev'][0] |
|
289 | query = req.form['rev'][0] | |
290 | revcount = web.maxchanges |
|
290 | revcount = web.maxchanges | |
291 | if 'revcount' in req.form: |
|
291 | if 'revcount' in req.form: | |
292 | try: |
|
292 | try: | |
293 | revcount = int(req.form.get('revcount', [revcount])[0]) |
|
293 | revcount = int(req.form.get('revcount', [revcount])[0]) | |
294 | revcount = max(revcount, 1) |
|
294 | revcount = max(revcount, 1) | |
295 | tmpl.defaults['sessionvars']['revcount'] = revcount |
|
295 | tmpl.defaults['sessionvars']['revcount'] = revcount | |
296 | except ValueError: |
|
296 | except ValueError: | |
297 | pass |
|
297 | pass | |
298 |
|
298 | |||
299 | lessvars = copy.copy(tmpl.defaults['sessionvars']) |
|
299 | lessvars = copy.copy(tmpl.defaults['sessionvars']) | |
300 | lessvars['revcount'] = max(revcount / 2, 1) |
|
300 | lessvars['revcount'] = max(revcount / 2, 1) | |
301 | lessvars['rev'] = query |
|
301 | lessvars['rev'] = query | |
302 | morevars = copy.copy(tmpl.defaults['sessionvars']) |
|
302 | morevars = copy.copy(tmpl.defaults['sessionvars']) | |
303 | morevars['revcount'] = revcount * 2 |
|
303 | morevars['revcount'] = revcount * 2 | |
304 | morevars['rev'] = query |
|
304 | morevars['rev'] = query | |
305 |
|
305 | |||
306 | mode, funcarg = getsearchmode(query) |
|
306 | mode, funcarg = getsearchmode(query) | |
307 |
|
307 | |||
308 | if 'forcekw' in req.form: |
|
308 | if 'forcekw' in req.form: | |
309 | showforcekw = '' |
|
309 | showforcekw = '' | |
310 | showunforcekw = searchfuncs[mode][1] |
|
310 | showunforcekw = searchfuncs[mode][1] | |
311 | mode = MODE_KEYWORD |
|
311 | mode = MODE_KEYWORD | |
312 | funcarg = query |
|
312 | funcarg = query | |
313 | else: |
|
313 | else: | |
314 | if mode != MODE_KEYWORD: |
|
314 | if mode != MODE_KEYWORD: | |
315 | showforcekw = searchfuncs[MODE_KEYWORD][1] |
|
315 | showforcekw = searchfuncs[MODE_KEYWORD][1] | |
316 | else: |
|
316 | else: | |
317 | showforcekw = '' |
|
317 | showforcekw = '' | |
318 | showunforcekw = '' |
|
318 | showunforcekw = '' | |
319 |
|
319 | |||
320 | searchfunc = searchfuncs[mode] |
|
320 | searchfunc = searchfuncs[mode] | |
321 |
|
321 | |||
322 | tip = web.repo['tip'] |
|
322 | tip = web.repo['tip'] | |
323 | parity = paritygen(web.stripecount) |
|
323 | parity = paritygen(web.stripecount) | |
324 |
|
324 | |||
325 | return tmpl('search', query=query, node=tip.hex(), symrev='tip', |
|
325 | return tmpl('search', query=query, node=tip.hex(), symrev='tip', | |
326 | entries=changelist, archives=web.archivelist("tip"), |
|
326 | entries=changelist, archives=web.archivelist("tip"), | |
327 | morevars=morevars, lessvars=lessvars, |
|
327 | morevars=morevars, lessvars=lessvars, | |
328 | modedesc=searchfunc[1], |
|
328 | modedesc=searchfunc[1], | |
329 | showforcekw=showforcekw, showunforcekw=showunforcekw) |
|
329 | showforcekw=showforcekw, showunforcekw=showunforcekw) | |
330 |
|
330 | |||
331 | @webcommand('changelog') |
|
331 | @webcommand('changelog') | |
332 | def changelog(web, req, tmpl, shortlog=False): |
|
332 | def changelog(web, req, tmpl, shortlog=False): | |
333 | """ |
|
333 | """ | |
334 | /changelog[/{revision}] |
|
334 | /changelog[/{revision}] | |
335 | ----------------------- |
|
335 | ----------------------- | |
336 |
|
336 | |||
337 | Show information about multiple changesets. |
|
337 | Show information about multiple changesets. | |
338 |
|
338 | |||
339 | If the optional ``revision`` URL argument is absent, information about |
|
339 | If the optional ``revision`` URL argument is absent, information about | |
340 | all changesets starting at ``tip`` will be rendered. If the ``revision`` |
|
340 | all changesets starting at ``tip`` will be rendered. If the ``revision`` | |
341 | argument is present, changesets will be shown starting from the specified |
|
341 | argument is present, changesets will be shown starting from the specified | |
342 | revision. |
|
342 | revision. | |
343 |
|
343 | |||
344 | If ``revision`` is absent, the ``rev`` query string argument may be |
|
344 | If ``revision`` is absent, the ``rev`` query string argument may be | |
345 | defined. This will perform a search for changesets. |
|
345 | defined. This will perform a search for changesets. | |
346 |
|
346 | |||
347 | The argument for ``rev`` can be a single revision, a revision set, |
|
347 | The argument for ``rev`` can be a single revision, a revision set, | |
348 | or a literal keyword to search for in changeset data (equivalent to |
|
348 | or a literal keyword to search for in changeset data (equivalent to | |
349 | :hg:`log -k`). |
|
349 | :hg:`log -k`). | |
350 |
|
350 | |||
351 | The ``revcount`` query string argument defines the maximum numbers of |
|
351 | The ``revcount`` query string argument defines the maximum numbers of | |
352 | changesets to render. |
|
352 | changesets to render. | |
353 |
|
353 | |||
354 | For non-searches, the ``changelog`` template will be rendered. |
|
354 | For non-searches, the ``changelog`` template will be rendered. | |
355 | """ |
|
355 | """ | |
356 |
|
356 | |||
357 | query = '' |
|
357 | query = '' | |
358 | if 'node' in req.form: |
|
358 | if 'node' in req.form: | |
359 | ctx = webutil.changectx(web.repo, req) |
|
359 | ctx = webutil.changectx(web.repo, req) | |
360 | symrev = webutil.symrevorshortnode(req, ctx) |
|
360 | symrev = webutil.symrevorshortnode(req, ctx) | |
361 | elif 'rev' in req.form: |
|
361 | elif 'rev' in req.form: | |
362 | return _search(web, req, tmpl) |
|
362 | return _search(web, req, tmpl) | |
363 | else: |
|
363 | else: | |
364 | ctx = web.repo['tip'] |
|
364 | ctx = web.repo['tip'] | |
365 | symrev = 'tip' |
|
365 | symrev = 'tip' | |
366 |
|
366 | |||
367 | def changelist(): |
|
367 | def changelist(): | |
368 | revs = [] |
|
368 | revs = [] | |
369 | if pos != -1: |
|
369 | if pos != -1: | |
370 | revs = web.repo.changelog.revs(pos, 0) |
|
370 | revs = web.repo.changelog.revs(pos, 0) | |
371 | curcount = 0 |
|
371 | curcount = 0 | |
372 | for rev in revs: |
|
372 | for rev in revs: | |
373 | curcount += 1 |
|
373 | curcount += 1 | |
374 | if curcount > revcount + 1: |
|
374 | if curcount > revcount + 1: | |
375 | break |
|
375 | break | |
376 |
|
376 | |||
377 | entry = webutil.changelistentry(web, web.repo[rev], tmpl) |
|
377 | entry = webutil.changelistentry(web, web.repo[rev], tmpl) | |
378 | entry['parity'] = next(parity) |
|
378 | entry['parity'] = next(parity) | |
379 | yield entry |
|
379 | yield entry | |
380 |
|
380 | |||
381 | if shortlog: |
|
381 | if shortlog: | |
382 | revcount = web.maxshortchanges |
|
382 | revcount = web.maxshortchanges | |
383 | else: |
|
383 | else: | |
384 | revcount = web.maxchanges |
|
384 | revcount = web.maxchanges | |
385 |
|
385 | |||
386 | if 'revcount' in req.form: |
|
386 | if 'revcount' in req.form: | |
387 | try: |
|
387 | try: | |
388 | revcount = int(req.form.get('revcount', [revcount])[0]) |
|
388 | revcount = int(req.form.get('revcount', [revcount])[0]) | |
389 | revcount = max(revcount, 1) |
|
389 | revcount = max(revcount, 1) | |
390 | tmpl.defaults['sessionvars']['revcount'] = revcount |
|
390 | tmpl.defaults['sessionvars']['revcount'] = revcount | |
391 | except ValueError: |
|
391 | except ValueError: | |
392 | pass |
|
392 | pass | |
393 |
|
393 | |||
394 | lessvars = copy.copy(tmpl.defaults['sessionvars']) |
|
394 | lessvars = copy.copy(tmpl.defaults['sessionvars']) | |
395 | lessvars['revcount'] = max(revcount / 2, 1) |
|
395 | lessvars['revcount'] = max(revcount / 2, 1) | |
396 | morevars = copy.copy(tmpl.defaults['sessionvars']) |
|
396 | morevars = copy.copy(tmpl.defaults['sessionvars']) | |
397 | morevars['revcount'] = revcount * 2 |
|
397 | morevars['revcount'] = revcount * 2 | |
398 |
|
398 | |||
399 | count = len(web.repo) |
|
399 | count = len(web.repo) | |
400 | pos = ctx.rev() |
|
400 | pos = ctx.rev() | |
401 | parity = paritygen(web.stripecount) |
|
401 | parity = paritygen(web.stripecount) | |
402 |
|
402 | |||
403 | changenav = webutil.revnav(web.repo).gen(pos, revcount, count) |
|
403 | changenav = webutil.revnav(web.repo).gen(pos, revcount, count) | |
404 |
|
404 | |||
405 | entries = list(changelist()) |
|
405 | entries = list(changelist()) | |
406 | latestentry = entries[:1] |
|
406 | latestentry = entries[:1] | |
407 | if len(entries) > revcount: |
|
407 | if len(entries) > revcount: | |
408 | nextentry = entries[-1:] |
|
408 | nextentry = entries[-1:] | |
409 | entries = entries[:-1] |
|
409 | entries = entries[:-1] | |
410 | else: |
|
410 | else: | |
411 | nextentry = [] |
|
411 | nextentry = [] | |
412 |
|
412 | |||
413 | return tmpl(shortlog and 'shortlog' or 'changelog', changenav=changenav, |
|
413 | return tmpl(shortlog and 'shortlog' or 'changelog', changenav=changenav, | |
414 | node=ctx.hex(), rev=pos, symrev=symrev, changesets=count, |
|
414 | node=ctx.hex(), rev=pos, symrev=symrev, changesets=count, | |
415 | entries=entries, |
|
415 | entries=entries, | |
416 | latestentry=latestentry, nextentry=nextentry, |
|
416 | latestentry=latestentry, nextentry=nextentry, | |
417 | archives=web.archivelist("tip"), revcount=revcount, |
|
417 | archives=web.archivelist("tip"), revcount=revcount, | |
418 | morevars=morevars, lessvars=lessvars, query=query) |
|
418 | morevars=morevars, lessvars=lessvars, query=query) | |
419 |
|
419 | |||
420 | @webcommand('shortlog') |
|
420 | @webcommand('shortlog') | |
421 | def shortlog(web, req, tmpl): |
|
421 | def shortlog(web, req, tmpl): | |
422 | """ |
|
422 | """ | |
423 | /shortlog |
|
423 | /shortlog | |
424 | --------- |
|
424 | --------- | |
425 |
|
425 | |||
426 | Show basic information about a set of changesets. |
|
426 | Show basic information about a set of changesets. | |
427 |
|
427 | |||
428 | This accepts the same parameters as the ``changelog`` handler. The only |
|
428 | This accepts the same parameters as the ``changelog`` handler. The only | |
429 | difference is the ``shortlog`` template will be rendered instead of the |
|
429 | difference is the ``shortlog`` template will be rendered instead of the | |
430 | ``changelog`` template. |
|
430 | ``changelog`` template. | |
431 | """ |
|
431 | """ | |
432 | return changelog(web, req, tmpl, shortlog=True) |
|
432 | return changelog(web, req, tmpl, shortlog=True) | |
433 |
|
433 | |||
434 | @webcommand('changeset') |
|
434 | @webcommand('changeset') | |
435 | def changeset(web, req, tmpl): |
|
435 | def changeset(web, req, tmpl): | |
436 | """ |
|
436 | """ | |
437 | /changeset[/{revision}] |
|
437 | /changeset[/{revision}] | |
438 | ----------------------- |
|
438 | ----------------------- | |
439 |
|
439 | |||
440 | Show information about a single changeset. |
|
440 | Show information about a single changeset. | |
441 |
|
441 | |||
442 | A URL path argument is the changeset identifier to show. See ``hg help |
|
442 | A URL path argument is the changeset identifier to show. See ``hg help | |
443 | revisions`` for possible values. If not defined, the ``tip`` changeset |
|
443 | revisions`` for possible values. If not defined, the ``tip`` changeset | |
444 | will be shown. |
|
444 | will be shown. | |
445 |
|
445 | |||
446 | The ``changeset`` template is rendered. Contents of the ``changesettag``, |
|
446 | The ``changeset`` template is rendered. Contents of the ``changesettag``, | |
447 | ``changesetbookmark``, ``filenodelink``, ``filenolink``, and the many |
|
447 | ``changesetbookmark``, ``filenodelink``, ``filenolink``, and the many | |
448 | templates related to diffs may all be used to produce the output. |
|
448 | templates related to diffs may all be used to produce the output. | |
449 | """ |
|
449 | """ | |
450 | ctx = webutil.changectx(web.repo, req) |
|
450 | ctx = webutil.changectx(web.repo, req) | |
451 |
|
451 | |||
452 | return tmpl('changeset', **webutil.changesetentry(web, req, tmpl, ctx)) |
|
452 | return tmpl('changeset', **webutil.changesetentry(web, req, tmpl, ctx)) | |
453 |
|
453 | |||
454 | rev = webcommand('rev')(changeset) |
|
454 | rev = webcommand('rev')(changeset) | |
455 |
|
455 | |||
456 | def decodepath(path): |
|
456 | def decodepath(path): | |
457 | """Hook for mapping a path in the repository to a path in the |
|
457 | """Hook for mapping a path in the repository to a path in the | |
458 | working copy. |
|
458 | working copy. | |
459 |
|
459 | |||
460 | Extensions (e.g., largefiles) can override this to remap files in |
|
460 | Extensions (e.g., largefiles) can override this to remap files in | |
461 | the virtual file system presented by the manifest command below.""" |
|
461 | the virtual file system presented by the manifest command below.""" | |
462 | return path |
|
462 | return path | |
463 |
|
463 | |||
464 | @webcommand('manifest') |
|
464 | @webcommand('manifest') | |
465 | def manifest(web, req, tmpl): |
|
465 | def manifest(web, req, tmpl): | |
466 | """ |
|
466 | """ | |
467 | /manifest[/{revision}[/{path}]] |
|
467 | /manifest[/{revision}[/{path}]] | |
468 | ------------------------------- |
|
468 | ------------------------------- | |
469 |
|
469 | |||
470 | Show information about a directory. |
|
470 | Show information about a directory. | |
471 |
|
471 | |||
472 | If the URL path arguments are omitted, information about the root |
|
472 | If the URL path arguments are omitted, information about the root | |
473 | directory for the ``tip`` changeset will be shown. |
|
473 | directory for the ``tip`` changeset will be shown. | |
474 |
|
474 | |||
475 | Because this handler can only show information for directories, it |
|
475 | Because this handler can only show information for directories, it | |
476 | is recommended to use the ``file`` handler instead, as it can handle both |
|
476 | is recommended to use the ``file`` handler instead, as it can handle both | |
477 | directories and files. |
|
477 | directories and files. | |
478 |
|
478 | |||
479 | The ``manifest`` template will be rendered for this handler. |
|
479 | The ``manifest`` template will be rendered for this handler. | |
480 | """ |
|
480 | """ | |
481 | if 'node' in req.form: |
|
481 | if 'node' in req.form: | |
482 | ctx = webutil.changectx(web.repo, req) |
|
482 | ctx = webutil.changectx(web.repo, req) | |
483 | symrev = webutil.symrevorshortnode(req, ctx) |
|
483 | symrev = webutil.symrevorshortnode(req, ctx) | |
484 | else: |
|
484 | else: | |
485 | ctx = web.repo['tip'] |
|
485 | ctx = web.repo['tip'] | |
486 | symrev = 'tip' |
|
486 | symrev = 'tip' | |
487 | path = webutil.cleanpath(web.repo, req.form.get('file', [''])[0]) |
|
487 | path = webutil.cleanpath(web.repo, req.form.get('file', [''])[0]) | |
488 | mf = ctx.manifest() |
|
488 | mf = ctx.manifest() | |
489 | node = ctx.node() |
|
489 | node = ctx.node() | |
490 |
|
490 | |||
491 | files = {} |
|
491 | files = {} | |
492 | dirs = {} |
|
492 | dirs = {} | |
493 | parity = paritygen(web.stripecount) |
|
493 | parity = paritygen(web.stripecount) | |
494 |
|
494 | |||
495 | if path and path[-1] != "/": |
|
495 | if path and path[-1] != "/": | |
496 | path += "/" |
|
496 | path += "/" | |
497 | l = len(path) |
|
497 | l = len(path) | |
498 | abspath = "/" + path |
|
498 | abspath = "/" + path | |
499 |
|
499 | |||
500 | for full, n in mf.iteritems(): |
|
500 | for full, n in mf.iteritems(): | |
501 | # the virtual path (working copy path) used for the full |
|
501 | # the virtual path (working copy path) used for the full | |
502 | # (repository) path |
|
502 | # (repository) path | |
503 | f = decodepath(full) |
|
503 | f = decodepath(full) | |
504 |
|
504 | |||
505 | if f[:l] != path: |
|
505 | if f[:l] != path: | |
506 | continue |
|
506 | continue | |
507 | remain = f[l:] |
|
507 | remain = f[l:] | |
508 | elements = remain.split('/') |
|
508 | elements = remain.split('/') | |
509 | if len(elements) == 1: |
|
509 | if len(elements) == 1: | |
510 | files[remain] = full |
|
510 | files[remain] = full | |
511 | else: |
|
511 | else: | |
512 | h = dirs # need to retain ref to dirs (root) |
|
512 | h = dirs # need to retain ref to dirs (root) | |
513 | for elem in elements[0:-1]: |
|
513 | for elem in elements[0:-1]: | |
514 | if elem not in h: |
|
514 | if elem not in h: | |
515 | h[elem] = {} |
|
515 | h[elem] = {} | |
516 | h = h[elem] |
|
516 | h = h[elem] | |
517 | if len(h) > 1: |
|
517 | if len(h) > 1: | |
518 | break |
|
518 | break | |
519 | h[None] = None # denotes files present |
|
519 | h[None] = None # denotes files present | |
520 |
|
520 | |||
521 | if mf and not files and not dirs: |
|
521 | if mf and not files and not dirs: | |
522 | raise ErrorResponse(HTTP_NOT_FOUND, 'path not found: ' + path) |
|
522 | raise ErrorResponse(HTTP_NOT_FOUND, 'path not found: ' + path) | |
523 |
|
523 | |||
524 | def filelist(**map): |
|
524 | def filelist(**map): | |
525 | for f in sorted(files): |
|
525 | for f in sorted(files): | |
526 | full = files[f] |
|
526 | full = files[f] | |
527 |
|
527 | |||
528 | fctx = ctx.filectx(full) |
|
528 | fctx = ctx.filectx(full) | |
529 | yield {"file": full, |
|
529 | yield {"file": full, | |
530 | "parity": next(parity), |
|
530 | "parity": next(parity), | |
531 | "basename": f, |
|
531 | "basename": f, | |
532 | "date": fctx.date(), |
|
532 | "date": fctx.date(), | |
533 | "size": fctx.size(), |
|
533 | "size": fctx.size(), | |
534 | "permissions": mf.flags(full)} |
|
534 | "permissions": mf.flags(full)} | |
535 |
|
535 | |||
536 | def dirlist(**map): |
|
536 | def dirlist(**map): | |
537 | for d in sorted(dirs): |
|
537 | for d in sorted(dirs): | |
538 |
|
538 | |||
539 | emptydirs = [] |
|
539 | emptydirs = [] | |
540 | h = dirs[d] |
|
540 | h = dirs[d] | |
541 | while isinstance(h, dict) and len(h) == 1: |
|
541 | while isinstance(h, dict) and len(h) == 1: | |
542 | k, v = h.items()[0] |
|
542 | k, v = h.items()[0] | |
543 | if v: |
|
543 | if v: | |
544 | emptydirs.append(k) |
|
544 | emptydirs.append(k) | |
545 | h = v |
|
545 | h = v | |
546 |
|
546 | |||
547 | path = "%s%s" % (abspath, d) |
|
547 | path = "%s%s" % (abspath, d) | |
548 | yield {"parity": next(parity), |
|
548 | yield {"parity": next(parity), | |
549 | "path": path, |
|
549 | "path": path, | |
550 | "emptydirs": "/".join(emptydirs), |
|
550 | "emptydirs": "/".join(emptydirs), | |
551 | "basename": d} |
|
551 | "basename": d} | |
552 |
|
552 | |||
553 | return tmpl("manifest", |
|
553 | return tmpl("manifest", | |
554 | symrev=symrev, |
|
554 | symrev=symrev, | |
555 | path=abspath, |
|
555 | path=abspath, | |
556 | up=webutil.up(abspath), |
|
556 | up=webutil.up(abspath), | |
557 | upparity=next(parity), |
|
557 | upparity=next(parity), | |
558 | fentries=filelist, |
|
558 | fentries=filelist, | |
559 | dentries=dirlist, |
|
559 | dentries=dirlist, | |
560 | archives=web.archivelist(hex(node)), |
|
560 | archives=web.archivelist(hex(node)), | |
561 | **webutil.commonentry(web.repo, ctx)) |
|
561 | **webutil.commonentry(web.repo, ctx)) | |
562 |
|
562 | |||
563 | @webcommand('tags') |
|
563 | @webcommand('tags') | |
564 | def tags(web, req, tmpl): |
|
564 | def tags(web, req, tmpl): | |
565 | """ |
|
565 | """ | |
566 | /tags |
|
566 | /tags | |
567 | ----- |
|
567 | ----- | |
568 |
|
568 | |||
569 | Show information about tags. |
|
569 | Show information about tags. | |
570 |
|
570 | |||
571 | No arguments are accepted. |
|
571 | No arguments are accepted. | |
572 |
|
572 | |||
573 | The ``tags`` template is rendered. |
|
573 | The ``tags`` template is rendered. | |
574 | """ |
|
574 | """ | |
575 | i = list(reversed(web.repo.tagslist())) |
|
575 | i = list(reversed(web.repo.tagslist())) | |
576 | parity = paritygen(web.stripecount) |
|
576 | parity = paritygen(web.stripecount) | |
577 |
|
577 | |||
578 | def entries(notip, latestonly, **map): |
|
578 | def entries(notip, latestonly, **map): | |
579 | t = i |
|
579 | t = i | |
580 | if notip: |
|
580 | if notip: | |
581 | t = [(k, n) for k, n in i if k != "tip"] |
|
581 | t = [(k, n) for k, n in i if k != "tip"] | |
582 | if latestonly: |
|
582 | if latestonly: | |
583 | t = t[:1] |
|
583 | t = t[:1] | |
584 | for k, n in t: |
|
584 | for k, n in t: | |
585 | yield {"parity": next(parity), |
|
585 | yield {"parity": next(parity), | |
586 | "tag": k, |
|
586 | "tag": k, | |
587 | "date": web.repo[n].date(), |
|
587 | "date": web.repo[n].date(), | |
588 | "node": hex(n)} |
|
588 | "node": hex(n)} | |
589 |
|
589 | |||
590 | return tmpl("tags", |
|
590 | return tmpl("tags", | |
591 | node=hex(web.repo.changelog.tip()), |
|
591 | node=hex(web.repo.changelog.tip()), | |
592 | entries=lambda **x: entries(False, False, **x), |
|
592 | entries=lambda **x: entries(False, False, **x), | |
593 | entriesnotip=lambda **x: entries(True, False, **x), |
|
593 | entriesnotip=lambda **x: entries(True, False, **x), | |
594 | latestentry=lambda **x: entries(True, True, **x)) |
|
594 | latestentry=lambda **x: entries(True, True, **x)) | |
595 |
|
595 | |||
596 | @webcommand('bookmarks') |
|
596 | @webcommand('bookmarks') | |
597 | def bookmarks(web, req, tmpl): |
|
597 | def bookmarks(web, req, tmpl): | |
598 | """ |
|
598 | """ | |
599 | /bookmarks |
|
599 | /bookmarks | |
600 | ---------- |
|
600 | ---------- | |
601 |
|
601 | |||
602 | Show information about bookmarks. |
|
602 | Show information about bookmarks. | |
603 |
|
603 | |||
604 | No arguments are accepted. |
|
604 | No arguments are accepted. | |
605 |
|
605 | |||
606 | The ``bookmarks`` template is rendered. |
|
606 | The ``bookmarks`` template is rendered. | |
607 | """ |
|
607 | """ | |
608 | i = [b for b in web.repo._bookmarks.items() if b[1] in web.repo] |
|
608 | i = [b for b in web.repo._bookmarks.items() if b[1] in web.repo] | |
609 | sortkey = lambda b: (web.repo[b[1]].rev(), b[0]) |
|
609 | sortkey = lambda b: (web.repo[b[1]].rev(), b[0]) | |
610 | i = sorted(i, key=sortkey, reverse=True) |
|
610 | i = sorted(i, key=sortkey, reverse=True) | |
611 | parity = paritygen(web.stripecount) |
|
611 | parity = paritygen(web.stripecount) | |
612 |
|
612 | |||
613 | def entries(latestonly, **map): |
|
613 | def entries(latestonly, **map): | |
614 | t = i |
|
614 | t = i | |
615 | if latestonly: |
|
615 | if latestonly: | |
616 | t = i[:1] |
|
616 | t = i[:1] | |
617 | for k, n in t: |
|
617 | for k, n in t: | |
618 | yield {"parity": next(parity), |
|
618 | yield {"parity": next(parity), | |
619 | "bookmark": k, |
|
619 | "bookmark": k, | |
620 | "date": web.repo[n].date(), |
|
620 | "date": web.repo[n].date(), | |
621 | "node": hex(n)} |
|
621 | "node": hex(n)} | |
622 |
|
622 | |||
623 | if i: |
|
623 | if i: | |
624 | latestrev = i[0][1] |
|
624 | latestrev = i[0][1] | |
625 | else: |
|
625 | else: | |
626 | latestrev = -1 |
|
626 | latestrev = -1 | |
627 |
|
627 | |||
628 | return tmpl("bookmarks", |
|
628 | return tmpl("bookmarks", | |
629 | node=hex(web.repo.changelog.tip()), |
|
629 | node=hex(web.repo.changelog.tip()), | |
630 | lastchange=[{"date": web.repo[latestrev].date()}], |
|
630 | lastchange=[{"date": web.repo[latestrev].date()}], | |
631 | entries=lambda **x: entries(latestonly=False, **x), |
|
631 | entries=lambda **x: entries(latestonly=False, **x), | |
632 | latestentry=lambda **x: entries(latestonly=True, **x)) |
|
632 | latestentry=lambda **x: entries(latestonly=True, **x)) | |
633 |
|
633 | |||
634 | @webcommand('branches') |
|
634 | @webcommand('branches') | |
635 | def branches(web, req, tmpl): |
|
635 | def branches(web, req, tmpl): | |
636 | """ |
|
636 | """ | |
637 | /branches |
|
637 | /branches | |
638 | --------- |
|
638 | --------- | |
639 |
|
639 | |||
640 | Show information about branches. |
|
640 | Show information about branches. | |
641 |
|
641 | |||
642 | All known branches are contained in the output, even closed branches. |
|
642 | All known branches are contained in the output, even closed branches. | |
643 |
|
643 | |||
644 | No arguments are accepted. |
|
644 | No arguments are accepted. | |
645 |
|
645 | |||
646 | The ``branches`` template is rendered. |
|
646 | The ``branches`` template is rendered. | |
647 | """ |
|
647 | """ | |
648 | entries = webutil.branchentries(web.repo, web.stripecount) |
|
648 | entries = webutil.branchentries(web.repo, web.stripecount) | |
649 | latestentry = webutil.branchentries(web.repo, web.stripecount, 1) |
|
649 | latestentry = webutil.branchentries(web.repo, web.stripecount, 1) | |
650 | return tmpl('branches', node=hex(web.repo.changelog.tip()), |
|
650 | return tmpl('branches', node=hex(web.repo.changelog.tip()), | |
651 | entries=entries, latestentry=latestentry) |
|
651 | entries=entries, latestentry=latestentry) | |
652 |
|
652 | |||
653 | @webcommand('summary') |
|
653 | @webcommand('summary') | |
654 | def summary(web, req, tmpl): |
|
654 | def summary(web, req, tmpl): | |
655 | """ |
|
655 | """ | |
656 | /summary |
|
656 | /summary | |
657 | -------- |
|
657 | -------- | |
658 |
|
658 | |||
659 | Show a summary of repository state. |
|
659 | Show a summary of repository state. | |
660 |
|
660 | |||
661 | Information about the latest changesets, bookmarks, tags, and branches |
|
661 | Information about the latest changesets, bookmarks, tags, and branches | |
662 | is captured by this handler. |
|
662 | is captured by this handler. | |
663 |
|
663 | |||
664 | The ``summary`` template is rendered. |
|
664 | The ``summary`` template is rendered. | |
665 | """ |
|
665 | """ | |
666 | i = reversed(web.repo.tagslist()) |
|
666 | i = reversed(web.repo.tagslist()) | |
667 |
|
667 | |||
668 | def tagentries(**map): |
|
668 | def tagentries(**map): | |
669 | parity = paritygen(web.stripecount) |
|
669 | parity = paritygen(web.stripecount) | |
670 | count = 0 |
|
670 | count = 0 | |
671 | for k, n in i: |
|
671 | for k, n in i: | |
672 | if k == "tip": # skip tip |
|
672 | if k == "tip": # skip tip | |
673 | continue |
|
673 | continue | |
674 |
|
674 | |||
675 | count += 1 |
|
675 | count += 1 | |
676 | if count > 10: # limit to 10 tags |
|
676 | if count > 10: # limit to 10 tags | |
677 | break |
|
677 | break | |
678 |
|
678 | |||
679 | yield tmpl("tagentry", |
|
679 | yield tmpl("tagentry", | |
680 | parity=next(parity), |
|
680 | parity=next(parity), | |
681 | tag=k, |
|
681 | tag=k, | |
682 | node=hex(n), |
|
682 | node=hex(n), | |
683 | date=web.repo[n].date()) |
|
683 | date=web.repo[n].date()) | |
684 |
|
684 | |||
685 | def bookmarks(**map): |
|
685 | def bookmarks(**map): | |
686 | parity = paritygen(web.stripecount) |
|
686 | parity = paritygen(web.stripecount) | |
687 | marks = [b for b in web.repo._bookmarks.items() if b[1] in web.repo] |
|
687 | marks = [b for b in web.repo._bookmarks.items() if b[1] in web.repo] | |
688 | sortkey = lambda b: (web.repo[b[1]].rev(), b[0]) |
|
688 | sortkey = lambda b: (web.repo[b[1]].rev(), b[0]) | |
689 | marks = sorted(marks, key=sortkey, reverse=True) |
|
689 | marks = sorted(marks, key=sortkey, reverse=True) | |
690 | for k, n in marks[:10]: # limit to 10 bookmarks |
|
690 | for k, n in marks[:10]: # limit to 10 bookmarks | |
691 | yield {'parity': next(parity), |
|
691 | yield {'parity': next(parity), | |
692 | 'bookmark': k, |
|
692 | 'bookmark': k, | |
693 | 'date': web.repo[n].date(), |
|
693 | 'date': web.repo[n].date(), | |
694 | 'node': hex(n)} |
|
694 | 'node': hex(n)} | |
695 |
|
695 | |||
696 | def changelist(**map): |
|
696 | def changelist(**map): | |
697 | parity = paritygen(web.stripecount, offset=start - end) |
|
697 | parity = paritygen(web.stripecount, offset=start - end) | |
698 | l = [] # build a list in forward order for efficiency |
|
698 | l = [] # build a list in forward order for efficiency | |
699 | revs = [] |
|
699 | revs = [] | |
700 | if start < end: |
|
700 | if start < end: | |
701 | revs = web.repo.changelog.revs(start, end - 1) |
|
701 | revs = web.repo.changelog.revs(start, end - 1) | |
702 | for i in revs: |
|
702 | for i in revs: | |
703 | ctx = web.repo[i] |
|
703 | ctx = web.repo[i] | |
704 |
|
704 | |||
705 | l.append(tmpl( |
|
705 | l.append(tmpl( | |
706 | 'shortlogentry', |
|
706 | 'shortlogentry', | |
707 | parity=next(parity), |
|
707 | parity=next(parity), | |
708 | **webutil.commonentry(web.repo, ctx))) |
|
708 | **webutil.commonentry(web.repo, ctx))) | |
709 |
|
709 | |||
710 | for entry in reversed(l): |
|
710 | for entry in reversed(l): | |
711 | yield entry |
|
711 | yield entry | |
712 |
|
712 | |||
713 | tip = web.repo['tip'] |
|
713 | tip = web.repo['tip'] | |
714 | count = len(web.repo) |
|
714 | count = len(web.repo) | |
715 | start = max(0, count - web.maxchanges) |
|
715 | start = max(0, count - web.maxchanges) | |
716 | end = min(count, start + web.maxchanges) |
|
716 | end = min(count, start + web.maxchanges) | |
717 |
|
717 | |||
718 | return tmpl("summary", |
|
718 | return tmpl("summary", | |
719 | desc=web.config("web", "description", "unknown"), |
|
719 | desc=web.config("web", "description", "unknown"), | |
720 | owner=get_contact(web.config) or "unknown", |
|
720 | owner=get_contact(web.config) or "unknown", | |
721 | lastchange=tip.date(), |
|
721 | lastchange=tip.date(), | |
722 | tags=tagentries, |
|
722 | tags=tagentries, | |
723 | bookmarks=bookmarks, |
|
723 | bookmarks=bookmarks, | |
724 | branches=webutil.branchentries(web.repo, web.stripecount, 10), |
|
724 | branches=webutil.branchentries(web.repo, web.stripecount, 10), | |
725 | shortlog=changelist, |
|
725 | shortlog=changelist, | |
726 | node=tip.hex(), |
|
726 | node=tip.hex(), | |
727 | symrev='tip', |
|
727 | symrev='tip', | |
728 |
archives=web.archivelist("tip") |
|
728 | archives=web.archivelist("tip"), | |
|
729 | labels=web.configlist('web', 'labels')) | |||
729 |
|
730 | |||
730 | @webcommand('filediff') |
|
731 | @webcommand('filediff') | |
731 | def filediff(web, req, tmpl): |
|
732 | def filediff(web, req, tmpl): | |
732 | """ |
|
733 | """ | |
733 | /diff/{revision}/{path} |
|
734 | /diff/{revision}/{path} | |
734 | ----------------------- |
|
735 | ----------------------- | |
735 |
|
736 | |||
736 | Show how a file changed in a particular commit. |
|
737 | Show how a file changed in a particular commit. | |
737 |
|
738 | |||
738 | The ``filediff`` template is rendered. |
|
739 | The ``filediff`` template is rendered. | |
739 |
|
740 | |||
740 | This handler is registered under both the ``/diff`` and ``/filediff`` |
|
741 | This handler is registered under both the ``/diff`` and ``/filediff`` | |
741 | paths. ``/diff`` is used in modern code. |
|
742 | paths. ``/diff`` is used in modern code. | |
742 | """ |
|
743 | """ | |
743 | fctx, ctx = None, None |
|
744 | fctx, ctx = None, None | |
744 | try: |
|
745 | try: | |
745 | fctx = webutil.filectx(web.repo, req) |
|
746 | fctx = webutil.filectx(web.repo, req) | |
746 | except LookupError: |
|
747 | except LookupError: | |
747 | ctx = webutil.changectx(web.repo, req) |
|
748 | ctx = webutil.changectx(web.repo, req) | |
748 | path = webutil.cleanpath(web.repo, req.form['file'][0]) |
|
749 | path = webutil.cleanpath(web.repo, req.form['file'][0]) | |
749 | if path not in ctx.files(): |
|
750 | if path not in ctx.files(): | |
750 | raise |
|
751 | raise | |
751 |
|
752 | |||
752 | if fctx is not None: |
|
753 | if fctx is not None: | |
753 | path = fctx.path() |
|
754 | path = fctx.path() | |
754 | ctx = fctx.changectx() |
|
755 | ctx = fctx.changectx() | |
755 |
|
756 | |||
756 | parity = paritygen(web.stripecount) |
|
757 | parity = paritygen(web.stripecount) | |
757 | style = web.config('web', 'style', 'paper') |
|
758 | style = web.config('web', 'style', 'paper') | |
758 | if 'style' in req.form: |
|
759 | if 'style' in req.form: | |
759 | style = req.form['style'][0] |
|
760 | style = req.form['style'][0] | |
760 |
|
761 | |||
761 | diffs = webutil.diffs(web.repo, tmpl, ctx, None, [path], parity, style) |
|
762 | diffs = webutil.diffs(web.repo, tmpl, ctx, None, [path], parity, style) | |
762 | if fctx is not None: |
|
763 | if fctx is not None: | |
763 | rename = webutil.renamelink(fctx) |
|
764 | rename = webutil.renamelink(fctx) | |
764 | ctx = fctx |
|
765 | ctx = fctx | |
765 | else: |
|
766 | else: | |
766 | rename = [] |
|
767 | rename = [] | |
767 | ctx = ctx |
|
768 | ctx = ctx | |
768 | return tmpl("filediff", |
|
769 | return tmpl("filediff", | |
769 | file=path, |
|
770 | file=path, | |
770 | symrev=webutil.symrevorshortnode(req, ctx), |
|
771 | symrev=webutil.symrevorshortnode(req, ctx), | |
771 | rename=rename, |
|
772 | rename=rename, | |
772 | diff=diffs, |
|
773 | diff=diffs, | |
773 | **webutil.commonentry(web.repo, ctx)) |
|
774 | **webutil.commonentry(web.repo, ctx)) | |
774 |
|
775 | |||
775 | diff = webcommand('diff')(filediff) |
|
776 | diff = webcommand('diff')(filediff) | |
776 |
|
777 | |||
777 | @webcommand('comparison') |
|
778 | @webcommand('comparison') | |
778 | def comparison(web, req, tmpl): |
|
779 | def comparison(web, req, tmpl): | |
779 | """ |
|
780 | """ | |
780 | /comparison/{revision}/{path} |
|
781 | /comparison/{revision}/{path} | |
781 | ----------------------------- |
|
782 | ----------------------------- | |
782 |
|
783 | |||
783 | Show a comparison between the old and new versions of a file from changes |
|
784 | Show a comparison between the old and new versions of a file from changes | |
784 | made on a particular revision. |
|
785 | made on a particular revision. | |
785 |
|
786 | |||
786 | This is similar to the ``diff`` handler. However, this form features |
|
787 | This is similar to the ``diff`` handler. However, this form features | |
787 | a split or side-by-side diff rather than a unified diff. |
|
788 | a split or side-by-side diff rather than a unified diff. | |
788 |
|
789 | |||
789 | The ``context`` query string argument can be used to control the lines of |
|
790 | The ``context`` query string argument can be used to control the lines of | |
790 | context in the diff. |
|
791 | context in the diff. | |
791 |
|
792 | |||
792 | The ``filecomparison`` template is rendered. |
|
793 | The ``filecomparison`` template is rendered. | |
793 | """ |
|
794 | """ | |
794 | ctx = webutil.changectx(web.repo, req) |
|
795 | ctx = webutil.changectx(web.repo, req) | |
795 | if 'file' not in req.form: |
|
796 | if 'file' not in req.form: | |
796 | raise ErrorResponse(HTTP_NOT_FOUND, 'file not given') |
|
797 | raise ErrorResponse(HTTP_NOT_FOUND, 'file not given') | |
797 | path = webutil.cleanpath(web.repo, req.form['file'][0]) |
|
798 | path = webutil.cleanpath(web.repo, req.form['file'][0]) | |
798 |
|
799 | |||
799 | parsecontext = lambda v: v == 'full' and -1 or int(v) |
|
800 | parsecontext = lambda v: v == 'full' and -1 or int(v) | |
800 | if 'context' in req.form: |
|
801 | if 'context' in req.form: | |
801 | context = parsecontext(req.form['context'][0]) |
|
802 | context = parsecontext(req.form['context'][0]) | |
802 | else: |
|
803 | else: | |
803 | context = parsecontext(web.config('web', 'comparisoncontext', '5')) |
|
804 | context = parsecontext(web.config('web', 'comparisoncontext', '5')) | |
804 |
|
805 | |||
805 | def filelines(f): |
|
806 | def filelines(f): | |
806 | if util.binary(f.data()): |
|
807 | if util.binary(f.data()): | |
807 | mt = mimetypes.guess_type(f.path())[0] |
|
808 | mt = mimetypes.guess_type(f.path())[0] | |
808 | if not mt: |
|
809 | if not mt: | |
809 | mt = 'application/octet-stream' |
|
810 | mt = 'application/octet-stream' | |
810 | return [_('(binary file %s, hash: %s)') % (mt, hex(f.filenode()))] |
|
811 | return [_('(binary file %s, hash: %s)') % (mt, hex(f.filenode()))] | |
811 | return f.data().splitlines() |
|
812 | return f.data().splitlines() | |
812 |
|
813 | |||
813 | fctx = None |
|
814 | fctx = None | |
814 | parent = ctx.p1() |
|
815 | parent = ctx.p1() | |
815 | leftrev = parent.rev() |
|
816 | leftrev = parent.rev() | |
816 | leftnode = parent.node() |
|
817 | leftnode = parent.node() | |
817 | rightrev = ctx.rev() |
|
818 | rightrev = ctx.rev() | |
818 | rightnode = ctx.node() |
|
819 | rightnode = ctx.node() | |
819 | if path in ctx: |
|
820 | if path in ctx: | |
820 | fctx = ctx[path] |
|
821 | fctx = ctx[path] | |
821 | rightlines = filelines(fctx) |
|
822 | rightlines = filelines(fctx) | |
822 | if path not in parent: |
|
823 | if path not in parent: | |
823 | leftlines = () |
|
824 | leftlines = () | |
824 | else: |
|
825 | else: | |
825 | pfctx = parent[path] |
|
826 | pfctx = parent[path] | |
826 | leftlines = filelines(pfctx) |
|
827 | leftlines = filelines(pfctx) | |
827 | else: |
|
828 | else: | |
828 | rightlines = () |
|
829 | rightlines = () | |
829 | pfctx = ctx.parents()[0][path] |
|
830 | pfctx = ctx.parents()[0][path] | |
830 | leftlines = filelines(pfctx) |
|
831 | leftlines = filelines(pfctx) | |
831 |
|
832 | |||
832 | comparison = webutil.compare(tmpl, context, leftlines, rightlines) |
|
833 | comparison = webutil.compare(tmpl, context, leftlines, rightlines) | |
833 | if fctx is not None: |
|
834 | if fctx is not None: | |
834 | rename = webutil.renamelink(fctx) |
|
835 | rename = webutil.renamelink(fctx) | |
835 | ctx = fctx |
|
836 | ctx = fctx | |
836 | else: |
|
837 | else: | |
837 | rename = [] |
|
838 | rename = [] | |
838 | ctx = ctx |
|
839 | ctx = ctx | |
839 | return tmpl('filecomparison', |
|
840 | return tmpl('filecomparison', | |
840 | file=path, |
|
841 | file=path, | |
841 | symrev=webutil.symrevorshortnode(req, ctx), |
|
842 | symrev=webutil.symrevorshortnode(req, ctx), | |
842 | rename=rename, |
|
843 | rename=rename, | |
843 | leftrev=leftrev, |
|
844 | leftrev=leftrev, | |
844 | leftnode=hex(leftnode), |
|
845 | leftnode=hex(leftnode), | |
845 | rightrev=rightrev, |
|
846 | rightrev=rightrev, | |
846 | rightnode=hex(rightnode), |
|
847 | rightnode=hex(rightnode), | |
847 | comparison=comparison, |
|
848 | comparison=comparison, | |
848 | **webutil.commonentry(web.repo, ctx)) |
|
849 | **webutil.commonentry(web.repo, ctx)) | |
849 |
|
850 | |||
850 | @webcommand('annotate') |
|
851 | @webcommand('annotate') | |
851 | def annotate(web, req, tmpl): |
|
852 | def annotate(web, req, tmpl): | |
852 | """ |
|
853 | """ | |
853 | /annotate/{revision}/{path} |
|
854 | /annotate/{revision}/{path} | |
854 | --------------------------- |
|
855 | --------------------------- | |
855 |
|
856 | |||
856 | Show changeset information for each line in a file. |
|
857 | Show changeset information for each line in a file. | |
857 |
|
858 | |||
858 | The ``fileannotate`` template is rendered. |
|
859 | The ``fileannotate`` template is rendered. | |
859 | """ |
|
860 | """ | |
860 | fctx = webutil.filectx(web.repo, req) |
|
861 | fctx = webutil.filectx(web.repo, req) | |
861 | f = fctx.path() |
|
862 | f = fctx.path() | |
862 | parity = paritygen(web.stripecount) |
|
863 | parity = paritygen(web.stripecount) | |
863 | diffopts = patch.difffeatureopts(web.repo.ui, untrusted=True, |
|
864 | diffopts = patch.difffeatureopts(web.repo.ui, untrusted=True, | |
864 | section='annotate', whitespace=True) |
|
865 | section='annotate', whitespace=True) | |
865 |
|
866 | |||
866 | def annotate(**map): |
|
867 | def annotate(**map): | |
867 | if util.binary(fctx.data()): |
|
868 | if util.binary(fctx.data()): | |
868 | mt = (mimetypes.guess_type(fctx.path())[0] |
|
869 | mt = (mimetypes.guess_type(fctx.path())[0] | |
869 | or 'application/octet-stream') |
|
870 | or 'application/octet-stream') | |
870 | lines = enumerate([((fctx.filectx(fctx.filerev()), 1), |
|
871 | lines = enumerate([((fctx.filectx(fctx.filerev()), 1), | |
871 | '(binary:%s)' % mt)]) |
|
872 | '(binary:%s)' % mt)]) | |
872 | else: |
|
873 | else: | |
873 | lines = enumerate(fctx.annotate(follow=True, linenumber=True, |
|
874 | lines = enumerate(fctx.annotate(follow=True, linenumber=True, | |
874 | diffopts=diffopts)) |
|
875 | diffopts=diffopts)) | |
875 | previousrev = None |
|
876 | previousrev = None | |
876 | for lineno, ((f, targetline), l) in lines: |
|
877 | for lineno, ((f, targetline), l) in lines: | |
877 | rev = f.rev() |
|
878 | rev = f.rev() | |
878 | blockhead = rev != previousrev or None |
|
879 | blockhead = rev != previousrev or None | |
879 | previousrev = rev |
|
880 | previousrev = rev | |
880 | yield {"parity": next(parity), |
|
881 | yield {"parity": next(parity), | |
881 | "node": f.hex(), |
|
882 | "node": f.hex(), | |
882 | "rev": rev, |
|
883 | "rev": rev, | |
883 | "author": f.user(), |
|
884 | "author": f.user(), | |
884 | "desc": f.description(), |
|
885 | "desc": f.description(), | |
885 | "extra": f.extra(), |
|
886 | "extra": f.extra(), | |
886 | "file": f.path(), |
|
887 | "file": f.path(), | |
887 | "blockhead": blockhead, |
|
888 | "blockhead": blockhead, | |
888 | "targetline": targetline, |
|
889 | "targetline": targetline, | |
889 | "line": l, |
|
890 | "line": l, | |
890 | "lineno": lineno + 1, |
|
891 | "lineno": lineno + 1, | |
891 | "lineid": "l%d" % (lineno + 1), |
|
892 | "lineid": "l%d" % (lineno + 1), | |
892 | "linenumber": "% 6d" % (lineno + 1), |
|
893 | "linenumber": "% 6d" % (lineno + 1), | |
893 | "revdate": f.date()} |
|
894 | "revdate": f.date()} | |
894 |
|
895 | |||
895 | return tmpl("fileannotate", |
|
896 | return tmpl("fileannotate", | |
896 | file=f, |
|
897 | file=f, | |
897 | annotate=annotate, |
|
898 | annotate=annotate, | |
898 | path=webutil.up(f), |
|
899 | path=webutil.up(f), | |
899 | symrev=webutil.symrevorshortnode(req, fctx), |
|
900 | symrev=webutil.symrevorshortnode(req, fctx), | |
900 | rename=webutil.renamelink(fctx), |
|
901 | rename=webutil.renamelink(fctx), | |
901 | permissions=fctx.manifest().flags(f), |
|
902 | permissions=fctx.manifest().flags(f), | |
902 | **webutil.commonentry(web.repo, fctx)) |
|
903 | **webutil.commonentry(web.repo, fctx)) | |
903 |
|
904 | |||
904 | @webcommand('filelog') |
|
905 | @webcommand('filelog') | |
905 | def filelog(web, req, tmpl): |
|
906 | def filelog(web, req, tmpl): | |
906 | """ |
|
907 | """ | |
907 | /filelog/{revision}/{path} |
|
908 | /filelog/{revision}/{path} | |
908 | -------------------------- |
|
909 | -------------------------- | |
909 |
|
910 | |||
910 | Show information about the history of a file in the repository. |
|
911 | Show information about the history of a file in the repository. | |
911 |
|
912 | |||
912 | The ``revcount`` query string argument can be defined to control the |
|
913 | The ``revcount`` query string argument can be defined to control the | |
913 | maximum number of entries to show. |
|
914 | maximum number of entries to show. | |
914 |
|
915 | |||
915 | The ``filelog`` template will be rendered. |
|
916 | The ``filelog`` template will be rendered. | |
916 | """ |
|
917 | """ | |
917 |
|
918 | |||
918 | try: |
|
919 | try: | |
919 | fctx = webutil.filectx(web.repo, req) |
|
920 | fctx = webutil.filectx(web.repo, req) | |
920 | f = fctx.path() |
|
921 | f = fctx.path() | |
921 | fl = fctx.filelog() |
|
922 | fl = fctx.filelog() | |
922 | except error.LookupError: |
|
923 | except error.LookupError: | |
923 | f = webutil.cleanpath(web.repo, req.form['file'][0]) |
|
924 | f = webutil.cleanpath(web.repo, req.form['file'][0]) | |
924 | fl = web.repo.file(f) |
|
925 | fl = web.repo.file(f) | |
925 | numrevs = len(fl) |
|
926 | numrevs = len(fl) | |
926 | if not numrevs: # file doesn't exist at all |
|
927 | if not numrevs: # file doesn't exist at all | |
927 | raise |
|
928 | raise | |
928 | rev = webutil.changectx(web.repo, req).rev() |
|
929 | rev = webutil.changectx(web.repo, req).rev() | |
929 | first = fl.linkrev(0) |
|
930 | first = fl.linkrev(0) | |
930 | if rev < first: # current rev is from before file existed |
|
931 | if rev < first: # current rev is from before file existed | |
931 | raise |
|
932 | raise | |
932 | frev = numrevs - 1 |
|
933 | frev = numrevs - 1 | |
933 | while fl.linkrev(frev) > rev: |
|
934 | while fl.linkrev(frev) > rev: | |
934 | frev -= 1 |
|
935 | frev -= 1 | |
935 | fctx = web.repo.filectx(f, fl.linkrev(frev)) |
|
936 | fctx = web.repo.filectx(f, fl.linkrev(frev)) | |
936 |
|
937 | |||
937 | revcount = web.maxshortchanges |
|
938 | revcount = web.maxshortchanges | |
938 | if 'revcount' in req.form: |
|
939 | if 'revcount' in req.form: | |
939 | try: |
|
940 | try: | |
940 | revcount = int(req.form.get('revcount', [revcount])[0]) |
|
941 | revcount = int(req.form.get('revcount', [revcount])[0]) | |
941 | revcount = max(revcount, 1) |
|
942 | revcount = max(revcount, 1) | |
942 | tmpl.defaults['sessionvars']['revcount'] = revcount |
|
943 | tmpl.defaults['sessionvars']['revcount'] = revcount | |
943 | except ValueError: |
|
944 | except ValueError: | |
944 | pass |
|
945 | pass | |
945 |
|
946 | |||
946 | lessvars = copy.copy(tmpl.defaults['sessionvars']) |
|
947 | lessvars = copy.copy(tmpl.defaults['sessionvars']) | |
947 | lessvars['revcount'] = max(revcount / 2, 1) |
|
948 | lessvars['revcount'] = max(revcount / 2, 1) | |
948 | morevars = copy.copy(tmpl.defaults['sessionvars']) |
|
949 | morevars = copy.copy(tmpl.defaults['sessionvars']) | |
949 | morevars['revcount'] = revcount * 2 |
|
950 | morevars['revcount'] = revcount * 2 | |
950 |
|
951 | |||
951 | count = fctx.filerev() + 1 |
|
952 | count = fctx.filerev() + 1 | |
952 | start = max(0, fctx.filerev() - revcount + 1) # first rev on this page |
|
953 | start = max(0, fctx.filerev() - revcount + 1) # first rev on this page | |
953 | end = min(count, start + revcount) # last rev on this page |
|
954 | end = min(count, start + revcount) # last rev on this page | |
954 | parity = paritygen(web.stripecount, offset=start - end) |
|
955 | parity = paritygen(web.stripecount, offset=start - end) | |
955 |
|
956 | |||
956 | def entries(): |
|
957 | def entries(): | |
957 | l = [] |
|
958 | l = [] | |
958 |
|
959 | |||
959 | repo = web.repo |
|
960 | repo = web.repo | |
960 | revs = fctx.filelog().revs(start, end - 1) |
|
961 | revs = fctx.filelog().revs(start, end - 1) | |
961 | for i in revs: |
|
962 | for i in revs: | |
962 | iterfctx = fctx.filectx(i) |
|
963 | iterfctx = fctx.filectx(i) | |
963 |
|
964 | |||
964 | l.append(dict( |
|
965 | l.append(dict( | |
965 | parity=next(parity), |
|
966 | parity=next(parity), | |
966 | filerev=i, |
|
967 | filerev=i, | |
967 | file=f, |
|
968 | file=f, | |
968 | rename=webutil.renamelink(iterfctx), |
|
969 | rename=webutil.renamelink(iterfctx), | |
969 | **webutil.commonentry(repo, iterfctx))) |
|
970 | **webutil.commonentry(repo, iterfctx))) | |
970 | for e in reversed(l): |
|
971 | for e in reversed(l): | |
971 | yield e |
|
972 | yield e | |
972 |
|
973 | |||
973 | entries = list(entries()) |
|
974 | entries = list(entries()) | |
974 | latestentry = entries[:1] |
|
975 | latestentry = entries[:1] | |
975 |
|
976 | |||
976 | revnav = webutil.filerevnav(web.repo, fctx.path()) |
|
977 | revnav = webutil.filerevnav(web.repo, fctx.path()) | |
977 | nav = revnav.gen(end - 1, revcount, count) |
|
978 | nav = revnav.gen(end - 1, revcount, count) | |
978 | return tmpl("filelog", |
|
979 | return tmpl("filelog", | |
979 | file=f, |
|
980 | file=f, | |
980 | nav=nav, |
|
981 | nav=nav, | |
981 | symrev=webutil.symrevorshortnode(req, fctx), |
|
982 | symrev=webutil.symrevorshortnode(req, fctx), | |
982 | entries=entries, |
|
983 | entries=entries, | |
983 | latestentry=latestentry, |
|
984 | latestentry=latestentry, | |
984 | revcount=revcount, |
|
985 | revcount=revcount, | |
985 | morevars=morevars, |
|
986 | morevars=morevars, | |
986 | lessvars=lessvars, |
|
987 | lessvars=lessvars, | |
987 | **webutil.commonentry(web.repo, fctx)) |
|
988 | **webutil.commonentry(web.repo, fctx)) | |
988 |
|
989 | |||
989 | @webcommand('archive') |
|
990 | @webcommand('archive') | |
990 | def archive(web, req, tmpl): |
|
991 | def archive(web, req, tmpl): | |
991 | """ |
|
992 | """ | |
992 | /archive/{revision}.{format}[/{path}] |
|
993 | /archive/{revision}.{format}[/{path}] | |
993 | ------------------------------------- |
|
994 | ------------------------------------- | |
994 |
|
995 | |||
995 | Obtain an archive of repository content. |
|
996 | Obtain an archive of repository content. | |
996 |
|
997 | |||
997 | The content and type of the archive is defined by a URL path parameter. |
|
998 | The content and type of the archive is defined by a URL path parameter. | |
998 | ``format`` is the file extension of the archive type to be generated. e.g. |
|
999 | ``format`` is the file extension of the archive type to be generated. e.g. | |
999 | ``zip`` or ``tar.bz2``. Not all archive types may be allowed by your |
|
1000 | ``zip`` or ``tar.bz2``. Not all archive types may be allowed by your | |
1000 | server configuration. |
|
1001 | server configuration. | |
1001 |
|
1002 | |||
1002 | The optional ``path`` URL parameter controls content to include in the |
|
1003 | The optional ``path`` URL parameter controls content to include in the | |
1003 | archive. If omitted, every file in the specified revision is present in the |
|
1004 | archive. If omitted, every file in the specified revision is present in the | |
1004 | archive. If included, only the specified file or contents of the specified |
|
1005 | archive. If included, only the specified file or contents of the specified | |
1005 | directory will be included in the archive. |
|
1006 | directory will be included in the archive. | |
1006 |
|
1007 | |||
1007 | No template is used for this handler. Raw, binary content is generated. |
|
1008 | No template is used for this handler. Raw, binary content is generated. | |
1008 | """ |
|
1009 | """ | |
1009 |
|
1010 | |||
1010 | type_ = req.form.get('type', [None])[0] |
|
1011 | type_ = req.form.get('type', [None])[0] | |
1011 | allowed = web.configlist("web", "allow_archive") |
|
1012 | allowed = web.configlist("web", "allow_archive") | |
1012 | key = req.form['node'][0] |
|
1013 | key = req.form['node'][0] | |
1013 |
|
1014 | |||
1014 | if type_ not in web.archives: |
|
1015 | if type_ not in web.archives: | |
1015 | msg = 'Unsupported archive type: %s' % type_ |
|
1016 | msg = 'Unsupported archive type: %s' % type_ | |
1016 | raise ErrorResponse(HTTP_NOT_FOUND, msg) |
|
1017 | raise ErrorResponse(HTTP_NOT_FOUND, msg) | |
1017 |
|
1018 | |||
1018 | if not ((type_ in allowed or |
|
1019 | if not ((type_ in allowed or | |
1019 | web.configbool("web", "allow" + type_, False))): |
|
1020 | web.configbool("web", "allow" + type_, False))): | |
1020 | msg = 'Archive type not allowed: %s' % type_ |
|
1021 | msg = 'Archive type not allowed: %s' % type_ | |
1021 | raise ErrorResponse(HTTP_FORBIDDEN, msg) |
|
1022 | raise ErrorResponse(HTTP_FORBIDDEN, msg) | |
1022 |
|
1023 | |||
1023 | reponame = re.sub(r"\W+", "-", os.path.basename(web.reponame)) |
|
1024 | reponame = re.sub(r"\W+", "-", os.path.basename(web.reponame)) | |
1024 | cnode = web.repo.lookup(key) |
|
1025 | cnode = web.repo.lookup(key) | |
1025 | arch_version = key |
|
1026 | arch_version = key | |
1026 | if cnode == key or key == 'tip': |
|
1027 | if cnode == key or key == 'tip': | |
1027 | arch_version = short(cnode) |
|
1028 | arch_version = short(cnode) | |
1028 | name = "%s-%s" % (reponame, arch_version) |
|
1029 | name = "%s-%s" % (reponame, arch_version) | |
1029 |
|
1030 | |||
1030 | ctx = webutil.changectx(web.repo, req) |
|
1031 | ctx = webutil.changectx(web.repo, req) | |
1031 | pats = [] |
|
1032 | pats = [] | |
1032 | matchfn = scmutil.match(ctx, []) |
|
1033 | matchfn = scmutil.match(ctx, []) | |
1033 | file = req.form.get('file', None) |
|
1034 | file = req.form.get('file', None) | |
1034 | if file: |
|
1035 | if file: | |
1035 | pats = ['path:' + file[0]] |
|
1036 | pats = ['path:' + file[0]] | |
1036 | matchfn = scmutil.match(ctx, pats, default='path') |
|
1037 | matchfn = scmutil.match(ctx, pats, default='path') | |
1037 | if pats: |
|
1038 | if pats: | |
1038 | files = [f for f in ctx.manifest().keys() if matchfn(f)] |
|
1039 | files = [f for f in ctx.manifest().keys() if matchfn(f)] | |
1039 | if not files: |
|
1040 | if not files: | |
1040 | raise ErrorResponse(HTTP_NOT_FOUND, |
|
1041 | raise ErrorResponse(HTTP_NOT_FOUND, | |
1041 | 'file(s) not found: %s' % file[0]) |
|
1042 | 'file(s) not found: %s' % file[0]) | |
1042 |
|
1043 | |||
1043 | mimetype, artype, extension, encoding = web.archivespecs[type_] |
|
1044 | mimetype, artype, extension, encoding = web.archivespecs[type_] | |
1044 | headers = [ |
|
1045 | headers = [ | |
1045 | ('Content-Disposition', 'attachment; filename=%s%s' % (name, extension)) |
|
1046 | ('Content-Disposition', 'attachment; filename=%s%s' % (name, extension)) | |
1046 | ] |
|
1047 | ] | |
1047 | if encoding: |
|
1048 | if encoding: | |
1048 | headers.append(('Content-Encoding', encoding)) |
|
1049 | headers.append(('Content-Encoding', encoding)) | |
1049 | req.headers.extend(headers) |
|
1050 | req.headers.extend(headers) | |
1050 | req.respond(HTTP_OK, mimetype) |
|
1051 | req.respond(HTTP_OK, mimetype) | |
1051 |
|
1052 | |||
1052 | archival.archive(web.repo, req, cnode, artype, prefix=name, |
|
1053 | archival.archive(web.repo, req, cnode, artype, prefix=name, | |
1053 | matchfn=matchfn, |
|
1054 | matchfn=matchfn, | |
1054 | subrepos=web.configbool("web", "archivesubrepos")) |
|
1055 | subrepos=web.configbool("web", "archivesubrepos")) | |
1055 | return [] |
|
1056 | return [] | |
1056 |
|
1057 | |||
1057 |
|
1058 | |||
1058 | @webcommand('static') |
|
1059 | @webcommand('static') | |
1059 | def static(web, req, tmpl): |
|
1060 | def static(web, req, tmpl): | |
1060 | fname = req.form['file'][0] |
|
1061 | fname = req.form['file'][0] | |
1061 | # a repo owner may set web.static in .hg/hgrc to get any file |
|
1062 | # a repo owner may set web.static in .hg/hgrc to get any file | |
1062 | # readable by the user running the CGI script |
|
1063 | # readable by the user running the CGI script | |
1063 | static = web.config("web", "static", None, untrusted=False) |
|
1064 | static = web.config("web", "static", None, untrusted=False) | |
1064 | if not static: |
|
1065 | if not static: | |
1065 | tp = web.templatepath or templater.templatepaths() |
|
1066 | tp = web.templatepath or templater.templatepaths() | |
1066 | if isinstance(tp, str): |
|
1067 | if isinstance(tp, str): | |
1067 | tp = [tp] |
|
1068 | tp = [tp] | |
1068 | static = [os.path.join(p, 'static') for p in tp] |
|
1069 | static = [os.path.join(p, 'static') for p in tp] | |
1069 | staticfile(static, fname, req) |
|
1070 | staticfile(static, fname, req) | |
1070 | return [] |
|
1071 | return [] | |
1071 |
|
1072 | |||
1072 | @webcommand('graph') |
|
1073 | @webcommand('graph') | |
1073 | def graph(web, req, tmpl): |
|
1074 | def graph(web, req, tmpl): | |
1074 | """ |
|
1075 | """ | |
1075 | /graph[/{revision}] |
|
1076 | /graph[/{revision}] | |
1076 | ------------------- |
|
1077 | ------------------- | |
1077 |
|
1078 | |||
1078 | Show information about the graphical topology of the repository. |
|
1079 | Show information about the graphical topology of the repository. | |
1079 |
|
1080 | |||
1080 | Information rendered by this handler can be used to create visual |
|
1081 | Information rendered by this handler can be used to create visual | |
1081 | representations of repository topology. |
|
1082 | representations of repository topology. | |
1082 |
|
1083 | |||
1083 | The ``revision`` URL parameter controls the starting changeset. |
|
1084 | The ``revision`` URL parameter controls the starting changeset. | |
1084 |
|
1085 | |||
1085 | The ``revcount`` query string argument can define the number of changesets |
|
1086 | The ``revcount`` query string argument can define the number of changesets | |
1086 | to show information for. |
|
1087 | to show information for. | |
1087 |
|
1088 | |||
1088 | This handler will render the ``graph`` template. |
|
1089 | This handler will render the ``graph`` template. | |
1089 | """ |
|
1090 | """ | |
1090 |
|
1091 | |||
1091 | if 'node' in req.form: |
|
1092 | if 'node' in req.form: | |
1092 | ctx = webutil.changectx(web.repo, req) |
|
1093 | ctx = webutil.changectx(web.repo, req) | |
1093 | symrev = webutil.symrevorshortnode(req, ctx) |
|
1094 | symrev = webutil.symrevorshortnode(req, ctx) | |
1094 | else: |
|
1095 | else: | |
1095 | ctx = web.repo['tip'] |
|
1096 | ctx = web.repo['tip'] | |
1096 | symrev = 'tip' |
|
1097 | symrev = 'tip' | |
1097 | rev = ctx.rev() |
|
1098 | rev = ctx.rev() | |
1098 |
|
1099 | |||
1099 | bg_height = 39 |
|
1100 | bg_height = 39 | |
1100 | revcount = web.maxshortchanges |
|
1101 | revcount = web.maxshortchanges | |
1101 | if 'revcount' in req.form: |
|
1102 | if 'revcount' in req.form: | |
1102 | try: |
|
1103 | try: | |
1103 | revcount = int(req.form.get('revcount', [revcount])[0]) |
|
1104 | revcount = int(req.form.get('revcount', [revcount])[0]) | |
1104 | revcount = max(revcount, 1) |
|
1105 | revcount = max(revcount, 1) | |
1105 | tmpl.defaults['sessionvars']['revcount'] = revcount |
|
1106 | tmpl.defaults['sessionvars']['revcount'] = revcount | |
1106 | except ValueError: |
|
1107 | except ValueError: | |
1107 | pass |
|
1108 | pass | |
1108 |
|
1109 | |||
1109 | lessvars = copy.copy(tmpl.defaults['sessionvars']) |
|
1110 | lessvars = copy.copy(tmpl.defaults['sessionvars']) | |
1110 | lessvars['revcount'] = max(revcount / 2, 1) |
|
1111 | lessvars['revcount'] = max(revcount / 2, 1) | |
1111 | morevars = copy.copy(tmpl.defaults['sessionvars']) |
|
1112 | morevars = copy.copy(tmpl.defaults['sessionvars']) | |
1112 | morevars['revcount'] = revcount * 2 |
|
1113 | morevars['revcount'] = revcount * 2 | |
1113 |
|
1114 | |||
1114 | count = len(web.repo) |
|
1115 | count = len(web.repo) | |
1115 | pos = rev |
|
1116 | pos = rev | |
1116 |
|
1117 | |||
1117 | uprev = min(max(0, count - 1), rev + revcount) |
|
1118 | uprev = min(max(0, count - 1), rev + revcount) | |
1118 | downrev = max(0, rev - revcount) |
|
1119 | downrev = max(0, rev - revcount) | |
1119 | changenav = webutil.revnav(web.repo).gen(pos, revcount, count) |
|
1120 | changenav = webutil.revnav(web.repo).gen(pos, revcount, count) | |
1120 |
|
1121 | |||
1121 | tree = [] |
|
1122 | tree = [] | |
1122 | if pos != -1: |
|
1123 | if pos != -1: | |
1123 | allrevs = web.repo.changelog.revs(pos, 0) |
|
1124 | allrevs = web.repo.changelog.revs(pos, 0) | |
1124 | revs = [] |
|
1125 | revs = [] | |
1125 | for i in allrevs: |
|
1126 | for i in allrevs: | |
1126 | revs.append(i) |
|
1127 | revs.append(i) | |
1127 | if len(revs) >= revcount: |
|
1128 | if len(revs) >= revcount: | |
1128 | break |
|
1129 | break | |
1129 |
|
1130 | |||
1130 | # We have to feed a baseset to dagwalker as it is expecting smartset |
|
1131 | # We have to feed a baseset to dagwalker as it is expecting smartset | |
1131 | # object. This does not have a big impact on hgweb performance itself |
|
1132 | # object. This does not have a big impact on hgweb performance itself | |
1132 | # since hgweb graphing code is not itself lazy yet. |
|
1133 | # since hgweb graphing code is not itself lazy yet. | |
1133 | dag = graphmod.dagwalker(web.repo, revset.baseset(revs)) |
|
1134 | dag = graphmod.dagwalker(web.repo, revset.baseset(revs)) | |
1134 | # As we said one line above... not lazy. |
|
1135 | # As we said one line above... not lazy. | |
1135 | tree = list(graphmod.colored(dag, web.repo)) |
|
1136 | tree = list(graphmod.colored(dag, web.repo)) | |
1136 |
|
1137 | |||
1137 | def getcolumns(tree): |
|
1138 | def getcolumns(tree): | |
1138 | cols = 0 |
|
1139 | cols = 0 | |
1139 | for (id, type, ctx, vtx, edges) in tree: |
|
1140 | for (id, type, ctx, vtx, edges) in tree: | |
1140 | if type != graphmod.CHANGESET: |
|
1141 | if type != graphmod.CHANGESET: | |
1141 | continue |
|
1142 | continue | |
1142 | cols = max(cols, max([edge[0] for edge in edges] or [0]), |
|
1143 | cols = max(cols, max([edge[0] for edge in edges] or [0]), | |
1143 | max([edge[1] for edge in edges] or [0])) |
|
1144 | max([edge[1] for edge in edges] or [0])) | |
1144 | return cols |
|
1145 | return cols | |
1145 |
|
1146 | |||
1146 | def graphdata(usetuples, encodestr): |
|
1147 | def graphdata(usetuples, encodestr): | |
1147 | data = [] |
|
1148 | data = [] | |
1148 |
|
1149 | |||
1149 | row = 0 |
|
1150 | row = 0 | |
1150 | for (id, type, ctx, vtx, edges) in tree: |
|
1151 | for (id, type, ctx, vtx, edges) in tree: | |
1151 | if type != graphmod.CHANGESET: |
|
1152 | if type != graphmod.CHANGESET: | |
1152 | continue |
|
1153 | continue | |
1153 | node = str(ctx) |
|
1154 | node = str(ctx) | |
1154 | age = encodestr(templatefilters.age(ctx.date())) |
|
1155 | age = encodestr(templatefilters.age(ctx.date())) | |
1155 | desc = templatefilters.firstline(encodestr(ctx.description())) |
|
1156 | desc = templatefilters.firstline(encodestr(ctx.description())) | |
1156 | desc = cgi.escape(templatefilters.nonempty(desc)) |
|
1157 | desc = cgi.escape(templatefilters.nonempty(desc)) | |
1157 | user = cgi.escape(templatefilters.person(encodestr(ctx.user()))) |
|
1158 | user = cgi.escape(templatefilters.person(encodestr(ctx.user()))) | |
1158 | branch = cgi.escape(encodestr(ctx.branch())) |
|
1159 | branch = cgi.escape(encodestr(ctx.branch())) | |
1159 | try: |
|
1160 | try: | |
1160 | branchnode = web.repo.branchtip(branch) |
|
1161 | branchnode = web.repo.branchtip(branch) | |
1161 | except error.RepoLookupError: |
|
1162 | except error.RepoLookupError: | |
1162 | branchnode = None |
|
1163 | branchnode = None | |
1163 | branch = branch, branchnode == ctx.node() |
|
1164 | branch = branch, branchnode == ctx.node() | |
1164 |
|
1165 | |||
1165 | if usetuples: |
|
1166 | if usetuples: | |
1166 | data.append((node, vtx, edges, desc, user, age, branch, |
|
1167 | data.append((node, vtx, edges, desc, user, age, branch, | |
1167 | [cgi.escape(encodestr(x)) for x in ctx.tags()], |
|
1168 | [cgi.escape(encodestr(x)) for x in ctx.tags()], | |
1168 | [cgi.escape(encodestr(x)) |
|
1169 | [cgi.escape(encodestr(x)) | |
1169 | for x in ctx.bookmarks()])) |
|
1170 | for x in ctx.bookmarks()])) | |
1170 | else: |
|
1171 | else: | |
1171 | edgedata = [{'col': edge[0], 'nextcol': edge[1], |
|
1172 | edgedata = [{'col': edge[0], 'nextcol': edge[1], | |
1172 | 'color': (edge[2] - 1) % 6 + 1, |
|
1173 | 'color': (edge[2] - 1) % 6 + 1, | |
1173 | 'width': edge[3], 'bcolor': edge[4]} |
|
1174 | 'width': edge[3], 'bcolor': edge[4]} | |
1174 | for edge in edges] |
|
1175 | for edge in edges] | |
1175 |
|
1176 | |||
1176 | data.append( |
|
1177 | data.append( | |
1177 | {'node': node, |
|
1178 | {'node': node, | |
1178 | 'col': vtx[0], |
|
1179 | 'col': vtx[0], | |
1179 | 'color': (vtx[1] - 1) % 6 + 1, |
|
1180 | 'color': (vtx[1] - 1) % 6 + 1, | |
1180 | 'edges': edgedata, |
|
1181 | 'edges': edgedata, | |
1181 | 'row': row, |
|
1182 | 'row': row, | |
1182 | 'nextrow': row + 1, |
|
1183 | 'nextrow': row + 1, | |
1183 | 'desc': desc, |
|
1184 | 'desc': desc, | |
1184 | 'user': user, |
|
1185 | 'user': user, | |
1185 | 'age': age, |
|
1186 | 'age': age, | |
1186 | 'bookmarks': webutil.nodebookmarksdict( |
|
1187 | 'bookmarks': webutil.nodebookmarksdict( | |
1187 | web.repo, ctx.node()), |
|
1188 | web.repo, ctx.node()), | |
1188 | 'branches': webutil.nodebranchdict(web.repo, ctx), |
|
1189 | 'branches': webutil.nodebranchdict(web.repo, ctx), | |
1189 | 'inbranch': webutil.nodeinbranch(web.repo, ctx), |
|
1190 | 'inbranch': webutil.nodeinbranch(web.repo, ctx), | |
1190 | 'tags': webutil.nodetagsdict(web.repo, ctx.node())}) |
|
1191 | 'tags': webutil.nodetagsdict(web.repo, ctx.node())}) | |
1191 |
|
1192 | |||
1192 | row += 1 |
|
1193 | row += 1 | |
1193 |
|
1194 | |||
1194 | return data |
|
1195 | return data | |
1195 |
|
1196 | |||
1196 | cols = getcolumns(tree) |
|
1197 | cols = getcolumns(tree) | |
1197 | rows = len(tree) |
|
1198 | rows = len(tree) | |
1198 | canvasheight = (rows + 1) * bg_height - 27 |
|
1199 | canvasheight = (rows + 1) * bg_height - 27 | |
1199 |
|
1200 | |||
1200 | return tmpl('graph', rev=rev, symrev=symrev, revcount=revcount, |
|
1201 | return tmpl('graph', rev=rev, symrev=symrev, revcount=revcount, | |
1201 | uprev=uprev, |
|
1202 | uprev=uprev, | |
1202 | lessvars=lessvars, morevars=morevars, downrev=downrev, |
|
1203 | lessvars=lessvars, morevars=morevars, downrev=downrev, | |
1203 | cols=cols, rows=rows, |
|
1204 | cols=cols, rows=rows, | |
1204 | canvaswidth=(cols + 1) * bg_height, |
|
1205 | canvaswidth=(cols + 1) * bg_height, | |
1205 | truecanvasheight=rows * bg_height, |
|
1206 | truecanvasheight=rows * bg_height, | |
1206 | canvasheight=canvasheight, bg_height=bg_height, |
|
1207 | canvasheight=canvasheight, bg_height=bg_height, | |
1207 | # {jsdata} will be passed to |json, so it must be in utf-8 |
|
1208 | # {jsdata} will be passed to |json, so it must be in utf-8 | |
1208 | jsdata=lambda **x: graphdata(True, encoding.fromlocal), |
|
1209 | jsdata=lambda **x: graphdata(True, encoding.fromlocal), | |
1209 | nodes=lambda **x: graphdata(False, str), |
|
1210 | nodes=lambda **x: graphdata(False, str), | |
1210 | node=ctx.hex(), changenav=changenav) |
|
1211 | node=ctx.hex(), changenav=changenav) | |
1211 |
|
1212 | |||
1212 | def _getdoc(e): |
|
1213 | def _getdoc(e): | |
1213 | doc = e[0].__doc__ |
|
1214 | doc = e[0].__doc__ | |
1214 | if doc: |
|
1215 | if doc: | |
1215 | doc = _(doc).partition('\n')[0] |
|
1216 | doc = _(doc).partition('\n')[0] | |
1216 | else: |
|
1217 | else: | |
1217 | doc = _('(no help text available)') |
|
1218 | doc = _('(no help text available)') | |
1218 | return doc |
|
1219 | return doc | |
1219 |
|
1220 | |||
1220 | @webcommand('help') |
|
1221 | @webcommand('help') | |
1221 | def help(web, req, tmpl): |
|
1222 | def help(web, req, tmpl): | |
1222 | """ |
|
1223 | """ | |
1223 | /help[/{topic}] |
|
1224 | /help[/{topic}] | |
1224 | --------------- |
|
1225 | --------------- | |
1225 |
|
1226 | |||
1226 | Render help documentation. |
|
1227 | Render help documentation. | |
1227 |
|
1228 | |||
1228 | This web command is roughly equivalent to :hg:`help`. If a ``topic`` |
|
1229 | This web command is roughly equivalent to :hg:`help`. If a ``topic`` | |
1229 | is defined, that help topic will be rendered. If not, an index of |
|
1230 | is defined, that help topic will be rendered. If not, an index of | |
1230 | available help topics will be rendered. |
|
1231 | available help topics will be rendered. | |
1231 |
|
1232 | |||
1232 | The ``help`` template will be rendered when requesting help for a topic. |
|
1233 | The ``help`` template will be rendered when requesting help for a topic. | |
1233 | ``helptopics`` will be rendered for the index of help topics. |
|
1234 | ``helptopics`` will be rendered for the index of help topics. | |
1234 | """ |
|
1235 | """ | |
1235 | from .. import commands, help as helpmod # avoid cycle |
|
1236 | from .. import commands, help as helpmod # avoid cycle | |
1236 |
|
1237 | |||
1237 | topicname = req.form.get('node', [None])[0] |
|
1238 | topicname = req.form.get('node', [None])[0] | |
1238 | if not topicname: |
|
1239 | if not topicname: | |
1239 | def topics(**map): |
|
1240 | def topics(**map): | |
1240 | for entries, summary, _doc in helpmod.helptable: |
|
1241 | for entries, summary, _doc in helpmod.helptable: | |
1241 | yield {'topic': entries[0], 'summary': summary} |
|
1242 | yield {'topic': entries[0], 'summary': summary} | |
1242 |
|
1243 | |||
1243 | early, other = [], [] |
|
1244 | early, other = [], [] | |
1244 | primary = lambda s: s.partition('|')[0] |
|
1245 | primary = lambda s: s.partition('|')[0] | |
1245 | for c, e in commands.table.iteritems(): |
|
1246 | for c, e in commands.table.iteritems(): | |
1246 | doc = _getdoc(e) |
|
1247 | doc = _getdoc(e) | |
1247 | if 'DEPRECATED' in doc or c.startswith('debug'): |
|
1248 | if 'DEPRECATED' in doc or c.startswith('debug'): | |
1248 | continue |
|
1249 | continue | |
1249 | cmd = primary(c) |
|
1250 | cmd = primary(c) | |
1250 | if cmd.startswith('^'): |
|
1251 | if cmd.startswith('^'): | |
1251 | early.append((cmd[1:], doc)) |
|
1252 | early.append((cmd[1:], doc)) | |
1252 | else: |
|
1253 | else: | |
1253 | other.append((cmd, doc)) |
|
1254 | other.append((cmd, doc)) | |
1254 |
|
1255 | |||
1255 | early.sort() |
|
1256 | early.sort() | |
1256 | other.sort() |
|
1257 | other.sort() | |
1257 |
|
1258 | |||
1258 | def earlycommands(**map): |
|
1259 | def earlycommands(**map): | |
1259 | for c, doc in early: |
|
1260 | for c, doc in early: | |
1260 | yield {'topic': c, 'summary': doc} |
|
1261 | yield {'topic': c, 'summary': doc} | |
1261 |
|
1262 | |||
1262 | def othercommands(**map): |
|
1263 | def othercommands(**map): | |
1263 | for c, doc in other: |
|
1264 | for c, doc in other: | |
1264 | yield {'topic': c, 'summary': doc} |
|
1265 | yield {'topic': c, 'summary': doc} | |
1265 |
|
1266 | |||
1266 | return tmpl('helptopics', topics=topics, earlycommands=earlycommands, |
|
1267 | return tmpl('helptopics', topics=topics, earlycommands=earlycommands, | |
1267 | othercommands=othercommands, title='Index') |
|
1268 | othercommands=othercommands, title='Index') | |
1268 |
|
1269 | |||
1269 | # Render an index of sub-topics. |
|
1270 | # Render an index of sub-topics. | |
1270 | if topicname in helpmod.subtopics: |
|
1271 | if topicname in helpmod.subtopics: | |
1271 | topics = [] |
|
1272 | topics = [] | |
1272 | for entries, summary, _doc in helpmod.subtopics[topicname]: |
|
1273 | for entries, summary, _doc in helpmod.subtopics[topicname]: | |
1273 | topics.append({ |
|
1274 | topics.append({ | |
1274 | 'topic': '%s.%s' % (topicname, entries[0]), |
|
1275 | 'topic': '%s.%s' % (topicname, entries[0]), | |
1275 | 'basename': entries[0], |
|
1276 | 'basename': entries[0], | |
1276 | 'summary': summary, |
|
1277 | 'summary': summary, | |
1277 | }) |
|
1278 | }) | |
1278 |
|
1279 | |||
1279 | return tmpl('helptopics', topics=topics, title=topicname, |
|
1280 | return tmpl('helptopics', topics=topics, title=topicname, | |
1280 | subindex=True) |
|
1281 | subindex=True) | |
1281 |
|
1282 | |||
1282 | u = webutil.wsgiui() |
|
1283 | u = webutil.wsgiui() | |
1283 | u.verbose = True |
|
1284 | u.verbose = True | |
1284 |
|
1285 | |||
1285 | # Render a page from a sub-topic. |
|
1286 | # Render a page from a sub-topic. | |
1286 | if '.' in topicname: |
|
1287 | if '.' in topicname: | |
1287 | # TODO implement support for rendering sections, like |
|
1288 | # TODO implement support for rendering sections, like | |
1288 | # `hg help` works. |
|
1289 | # `hg help` works. | |
1289 | topic, subtopic = topicname.split('.', 1) |
|
1290 | topic, subtopic = topicname.split('.', 1) | |
1290 | if topic not in helpmod.subtopics: |
|
1291 | if topic not in helpmod.subtopics: | |
1291 | raise ErrorResponse(HTTP_NOT_FOUND) |
|
1292 | raise ErrorResponse(HTTP_NOT_FOUND) | |
1292 | else: |
|
1293 | else: | |
1293 | topic = topicname |
|
1294 | topic = topicname | |
1294 | subtopic = None |
|
1295 | subtopic = None | |
1295 |
|
1296 | |||
1296 | try: |
|
1297 | try: | |
1297 | doc = helpmod.help_(u, topic, subtopic=subtopic) |
|
1298 | doc = helpmod.help_(u, topic, subtopic=subtopic) | |
1298 | except error.UnknownCommand: |
|
1299 | except error.UnknownCommand: | |
1299 | raise ErrorResponse(HTTP_NOT_FOUND) |
|
1300 | raise ErrorResponse(HTTP_NOT_FOUND) | |
1300 | return tmpl('help', topic=topicname, doc=doc) |
|
1301 | return tmpl('help', topic=topicname, doc=doc) | |
1301 |
|
1302 | |||
1302 | # tell hggettext to extract docstrings from these functions: |
|
1303 | # tell hggettext to extract docstrings from these functions: | |
1303 | i18nfunctions = commands.values() |
|
1304 | i18nfunctions = commands.values() |
@@ -1,224 +1,226 b'' | |||||
1 | mimetype = 'application/json' |
|
1 | mimetype = 'application/json' | |
2 | filerevision = '\{ |
|
2 | filerevision = '\{ | |
3 | "node": {node|json}, |
|
3 | "node": {node|json}, | |
4 | "path": {file|json}, |
|
4 | "path": {file|json}, | |
5 | "date": {date|json}, |
|
5 | "date": {date|json}, | |
6 | "desc": {desc|utf8|json}, |
|
6 | "desc": {desc|utf8|json}, | |
7 | "branch": {if(branch, branch%changesetbranch, "default"|json)}, |
|
7 | "branch": {if(branch, branch%changesetbranch, "default"|json)}, | |
8 | "bookmarks": [{join(bookmarks%changelistentryname, ", ")}], |
|
8 | "bookmarks": [{join(bookmarks%changelistentryname, ", ")}], | |
9 | "tags": [{join(tags%changelistentryname, ", ")}], |
|
9 | "tags": [{join(tags%changelistentryname, ", ")}], | |
10 | "user": {author|utf8|json}, |
|
10 | "user": {author|utf8|json}, | |
11 | "parents": [{join(parent%changesetparent, ", ")}], |
|
11 | "parents": [{join(parent%changesetparent, ", ")}], | |
12 | "phase": {phase|json}, |
|
12 | "phase": {phase|json}, | |
13 | "lines": [{join(text%lineentry, ", ")}] |
|
13 | "lines": [{join(text%lineentry, ", ")}] | |
14 | }' |
|
14 | }' | |
15 | lineentry = '\{ |
|
15 | lineentry = '\{ | |
16 | "line": {line|json} |
|
16 | "line": {line|json} | |
17 | }' |
|
17 | }' | |
18 | search = '\{ |
|
18 | search = '\{ | |
19 | "node": {node|json}, |
|
19 | "node": {node|json}, | |
20 | "query": {query|json}, |
|
20 | "query": {query|json}, | |
21 | "entries": [{join(entries%searchentry, ", ")}] |
|
21 | "entries": [{join(entries%searchentry, ", ")}] | |
22 | }' |
|
22 | }' | |
23 | searchentry = '{changelistentry}' |
|
23 | searchentry = '{changelistentry}' | |
24 | # changelog and shortlog are the same web API but with different |
|
24 | # changelog and shortlog are the same web API but with different | |
25 | # number of entries. |
|
25 | # number of entries. | |
26 | changelog = changelist.tmpl |
|
26 | changelog = changelist.tmpl | |
27 | shortlog = changelist.tmpl |
|
27 | shortlog = changelist.tmpl | |
28 | changelistentry = '\{ |
|
28 | changelistentry = '\{ | |
29 | "node": {node|json}, |
|
29 | "node": {node|json}, | |
30 | "date": {date|json}, |
|
30 | "date": {date|json}, | |
31 | "desc": {desc|utf8|json}, |
|
31 | "desc": {desc|utf8|json}, | |
32 | "branch": {if(branch, branch%changesetbranch, "default"|json)}, |
|
32 | "branch": {if(branch, branch%changesetbranch, "default"|json)}, | |
33 | "bookmarks": [{join(bookmarks%changelistentryname, ", ")}], |
|
33 | "bookmarks": [{join(bookmarks%changelistentryname, ", ")}], | |
34 | "tags": [{join(tags%changelistentryname, ", ")}], |
|
34 | "tags": [{join(tags%changelistentryname, ", ")}], | |
35 | "user": {author|utf8|json}, |
|
35 | "user": {author|utf8|json}, | |
36 | "phase": {phase|json}, |
|
36 | "phase": {phase|json}, | |
37 | "parents": [{if(allparents, join(allparents%changesetparent, ", "), |
|
37 | "parents": [{if(allparents, join(allparents%changesetparent, ", "), | |
38 | join(parent%changesetparent, ", "))}] |
|
38 | join(parent%changesetparent, ", "))}] | |
39 | }' |
|
39 | }' | |
40 | changelistentryname = '{name|utf8|json}' |
|
40 | changelistentryname = '{name|utf8|json}' | |
41 | changeset = '\{ |
|
41 | changeset = '\{ | |
42 | "node": {node|json}, |
|
42 | "node": {node|json}, | |
43 | "date": {date|json}, |
|
43 | "date": {date|json}, | |
44 | "desc": {desc|utf8|json}, |
|
44 | "desc": {desc|utf8|json}, | |
45 | "branch": {if(branch, branch%changesetbranch, "default"|json)}, |
|
45 | "branch": {if(branch, branch%changesetbranch, "default"|json)}, | |
46 | "bookmarks": [{join(changesetbookmark, ", ")}], |
|
46 | "bookmarks": [{join(changesetbookmark, ", ")}], | |
47 | "tags": [{join(changesettag, ", ")}], |
|
47 | "tags": [{join(changesettag, ", ")}], | |
48 | "user": {author|utf8|json}, |
|
48 | "user": {author|utf8|json}, | |
49 | "parents": [{join(parent%changesetparent, ", ")}], |
|
49 | "parents": [{join(parent%changesetparent, ", ")}], | |
50 | "phase": {phase|json} |
|
50 | "phase": {phase|json} | |
51 | }' |
|
51 | }' | |
52 | changesetbranch = '{name|utf8|json}' |
|
52 | changesetbranch = '{name|utf8|json}' | |
53 | changesetbookmark = '{bookmark|utf8|json}' |
|
53 | changesetbookmark = '{bookmark|utf8|json}' | |
54 | changesettag = '{tag|utf8|json}' |
|
54 | changesettag = '{tag|utf8|json}' | |
55 | changesetparent = '{node|json}' |
|
55 | changesetparent = '{node|json}' | |
56 | manifest = '\{ |
|
56 | manifest = '\{ | |
57 | "node": {node|json}, |
|
57 | "node": {node|json}, | |
58 | "abspath": {path|json}, |
|
58 | "abspath": {path|json}, | |
59 | "directories": [{join(dentries%direntry, ", ")}], |
|
59 | "directories": [{join(dentries%direntry, ", ")}], | |
60 | "files": [{join(fentries%fileentry, ", ")}], |
|
60 | "files": [{join(fentries%fileentry, ", ")}], | |
61 | "bookmarks": [{join(bookmarks%name, ", ")}], |
|
61 | "bookmarks": [{join(bookmarks%name, ", ")}], | |
62 | "tags": [{join(tags%name, ", ")}] |
|
62 | "tags": [{join(tags%name, ", ")}] | |
63 | }' |
|
63 | }' | |
64 | name = '{name|utf8|json}' |
|
64 | name = '{name|utf8|json}' | |
65 | direntry = '\{ |
|
65 | direntry = '\{ | |
66 | "abspath": {path|json}, |
|
66 | "abspath": {path|json}, | |
67 | "basename": {basename|json}, |
|
67 | "basename": {basename|json}, | |
68 | "emptydirs": {emptydirs|json} |
|
68 | "emptydirs": {emptydirs|json} | |
69 | }' |
|
69 | }' | |
70 | fileentry = '\{ |
|
70 | fileentry = '\{ | |
71 | "abspath": {file|json}, |
|
71 | "abspath": {file|json}, | |
72 | "basename": {basename|json}, |
|
72 | "basename": {basename|json}, | |
73 | "date": {date|json}, |
|
73 | "date": {date|json}, | |
74 | "size": {size|json}, |
|
74 | "size": {size|json}, | |
75 | "flags": {permissions|json} |
|
75 | "flags": {permissions|json} | |
76 | }' |
|
76 | }' | |
77 | tags = '\{ |
|
77 | tags = '\{ | |
78 | "node": {node|json}, |
|
78 | "node": {node|json}, | |
79 | "tags": [{join(entriesnotip%tagentry, ", ")}] |
|
79 | "tags": [{join(entriesnotip%tagentry, ", ")}] | |
80 | }' |
|
80 | }' | |
81 | tagentry = '\{ |
|
81 | tagentry = '\{ | |
82 | "tag": {tag|utf8|json}, |
|
82 | "tag": {tag|utf8|json}, | |
83 | "node": {node|json}, |
|
83 | "node": {node|json}, | |
84 | "date": {date|json} |
|
84 | "date": {date|json} | |
85 | }' |
|
85 | }' | |
86 | bookmarks = '\{ |
|
86 | bookmarks = '\{ | |
87 | "node": {node|json}, |
|
87 | "node": {node|json}, | |
88 | "bookmarks": [{join(entries%bookmarkentry, ", ")}] |
|
88 | "bookmarks": [{join(entries%bookmarkentry, ", ")}] | |
89 | }' |
|
89 | }' | |
90 | bookmarkentry = '\{ |
|
90 | bookmarkentry = '\{ | |
91 | "bookmark": {bookmark|utf8|json}, |
|
91 | "bookmark": {bookmark|utf8|json}, | |
92 | "node": {node|json}, |
|
92 | "node": {node|json}, | |
93 | "date": {date|json} |
|
93 | "date": {date|json} | |
94 | }' |
|
94 | }' | |
95 | branches = '\{ |
|
95 | branches = '\{ | |
96 | "branches": [{join(entries%branchentry, ", ")}] |
|
96 | "branches": [{join(entries%branchentry, ", ")}] | |
97 | }' |
|
97 | }' | |
98 | branchentry = '\{ |
|
98 | branchentry = '\{ | |
99 | "branch": {branch|utf8|json}, |
|
99 | "branch": {branch|utf8|json}, | |
100 | "node": {node|json}, |
|
100 | "node": {node|json}, | |
101 | "date": {date|json}, |
|
101 | "date": {date|json}, | |
102 | "status": {status|json} |
|
102 | "status": {status|json} | |
103 | }' |
|
103 | }' | |
104 | shortlogentry = '{changelistentry}' |
|
104 | shortlogentry = '{changelistentry}' | |
105 | summary = '\{ |
|
105 | summary = '\{ | |
106 | "node": {node|json}, |
|
106 | "node": {node|json}, | |
107 | "lastchange": {lastchange|json}, |
|
107 | "lastchange": {lastchange|json}, | |
108 | "bookmarks": [{join(bookmarks%bookmarkentry, ", ")}], |
|
108 | "bookmarks": [{join(bookmarks%bookmarkentry, ", ")}], | |
109 | "branches": [{join(branches%branchentry, ", ")}], |
|
109 | "branches": [{join(branches%branchentry, ", ")}], | |
110 | "shortlog": [{join(shortlog%shortlogentry, ", ")}], |
|
110 | "shortlog": [{join(shortlog%shortlogentry, ", ")}], | |
111 | "tags": [{join(tags%tagentry, ", ")}], |
|
111 | "tags": [{join(tags%tagentry, ", ")}], | |
112 | "archives": [{join(archives%archiveentry, ", ")}] |
|
112 | "archives": [{join(archives%archiveentry, ", ")}], | |
|
113 | "labels": {labels|json} | |||
113 | }' |
|
114 | }' | |
114 | archiveentry = '\{ |
|
115 | archiveentry = '\{ | |
115 | "node": {node|json}, |
|
116 | "node": {node|json}, | |
116 | "extension": {extension|json}, |
|
117 | "extension": {extension|json}, | |
117 | "type": {type|json}, |
|
118 | "type": {type|json}, | |
118 | "url": {"{urlbase}{url}archive/{node}{extension}"|json} |
|
119 | "url": {"{urlbase}{url}archive/{node}{extension}"|json} | |
119 | }' |
|
120 | }' | |
120 | filediff = '\{ |
|
121 | filediff = '\{ | |
121 | "path": {file|json}, |
|
122 | "path": {file|json}, | |
122 | "node": {node|json}, |
|
123 | "node": {node|json}, | |
123 | "date": {date|json}, |
|
124 | "date": {date|json}, | |
124 | "desc": {desc|utf8|json}, |
|
125 | "desc": {desc|utf8|json}, | |
125 | "author": {author|utf8|json}, |
|
126 | "author": {author|utf8|json}, | |
126 | "parents": [{join(parent%changesetparent, ", ")}], |
|
127 | "parents": [{join(parent%changesetparent, ", ")}], | |
127 | "children": [{join(child%changesetparent, ", ")}], |
|
128 | "children": [{join(child%changesetparent, ", ")}], | |
128 | "diff": [{join(diff%diffblock, ", ")}] |
|
129 | "diff": [{join(diff%diffblock, ", ")}] | |
129 | }' |
|
130 | }' | |
130 | diffblock = '\{ |
|
131 | diffblock = '\{ | |
131 | "blockno": {blockno|json}, |
|
132 | "blockno": {blockno|json}, | |
132 | "lines": [{join(lines, ", ")}] |
|
133 | "lines": [{join(lines, ", ")}] | |
133 | }' |
|
134 | }' | |
134 | difflineplus = '\{ |
|
135 | difflineplus = '\{ | |
135 | "t": "+", |
|
136 | "t": "+", | |
136 | "n": {lineno|json}, |
|
137 | "n": {lineno|json}, | |
137 | "l": {line|json} |
|
138 | "l": {line|json} | |
138 | }' |
|
139 | }' | |
139 | difflineminus = '\{ |
|
140 | difflineminus = '\{ | |
140 | "t": "-", |
|
141 | "t": "-", | |
141 | "n": {lineno|json}, |
|
142 | "n": {lineno|json}, | |
142 | "l": {line|json} |
|
143 | "l": {line|json} | |
143 | }' |
|
144 | }' | |
144 | difflineat = '\{ |
|
145 | difflineat = '\{ | |
145 | "t": "@", |
|
146 | "t": "@", | |
146 | "n": {lineno|json}, |
|
147 | "n": {lineno|json}, | |
147 | "l": {line|json} |
|
148 | "l": {line|json} | |
148 | }' |
|
149 | }' | |
149 | diffline = '\{ |
|
150 | diffline = '\{ | |
150 | "t": "", |
|
151 | "t": "", | |
151 | "n": {lineno|json}, |
|
152 | "n": {lineno|json}, | |
152 | "l": {line|json} |
|
153 | "l": {line|json} | |
153 | }' |
|
154 | }' | |
154 | filecomparison = '\{ |
|
155 | filecomparison = '\{ | |
155 | "path": {file|json}, |
|
156 | "path": {file|json}, | |
156 | "node": {node|json}, |
|
157 | "node": {node|json}, | |
157 | "date": {date|json}, |
|
158 | "date": {date|json}, | |
158 | "desc": {desc|utf8|json}, |
|
159 | "desc": {desc|utf8|json}, | |
159 | "author": {author|utf8|json}, |
|
160 | "author": {author|utf8|json}, | |
160 | "parents": [{join(parent%changesetparent, ", ")}], |
|
161 | "parents": [{join(parent%changesetparent, ", ")}], | |
161 | "children": [{join(child%changesetparent, ", ")}], |
|
162 | "children": [{join(child%changesetparent, ", ")}], | |
162 | "leftnode": {leftnode|json}, |
|
163 | "leftnode": {leftnode|json}, | |
163 | "rightnode": {rightnode|json}, |
|
164 | "rightnode": {rightnode|json}, | |
164 | "comparison": [{join(comparison, ", ")}] |
|
165 | "comparison": [{join(comparison, ", ")}] | |
165 | }' |
|
166 | }' | |
166 | comparisonblock = '\{ |
|
167 | comparisonblock = '\{ | |
167 | "lines": [{join(lines, ", ")}] |
|
168 | "lines": [{join(lines, ", ")}] | |
168 | }' |
|
169 | }' | |
169 | comparisonline = '\{ |
|
170 | comparisonline = '\{ | |
170 | "t": {type|json}, |
|
171 | "t": {type|json}, | |
171 | "ln": {leftlineno|json}, |
|
172 | "ln": {leftlineno|json}, | |
172 | "ll": {leftline|json}, |
|
173 | "ll": {leftline|json}, | |
173 | "rn": {rightlineno|json}, |
|
174 | "rn": {rightlineno|json}, | |
174 | "rl": {rightline|json} |
|
175 | "rl": {rightline|json} | |
175 | }' |
|
176 | }' | |
176 | fileannotate = '\{ |
|
177 | fileannotate = '\{ | |
177 | "abspath": {file|json}, |
|
178 | "abspath": {file|json}, | |
178 | "node": {node|json}, |
|
179 | "node": {node|json}, | |
179 | "author": {author|utf8|json}, |
|
180 | "author": {author|utf8|json}, | |
180 | "date": {date|json}, |
|
181 | "date": {date|json}, | |
181 | "desc": {desc|utf8|json}, |
|
182 | "desc": {desc|utf8|json}, | |
182 | "parents": [{join(parent%changesetparent, ", ")}], |
|
183 | "parents": [{join(parent%changesetparent, ", ")}], | |
183 | "children": [{join(child%changesetparent, ", ")}], |
|
184 | "children": [{join(child%changesetparent, ", ")}], | |
184 | "permissions": {permissions|json}, |
|
185 | "permissions": {permissions|json}, | |
185 | "annotate": [{join(annotate%fileannotation, ", ")}] |
|
186 | "annotate": [{join(annotate%fileannotation, ", ")}] | |
186 | }' |
|
187 | }' | |
187 | fileannotation = '\{ |
|
188 | fileannotation = '\{ | |
188 | "node": {node|json}, |
|
189 | "node": {node|json}, | |
189 | "author": {author|utf8|json}, |
|
190 | "author": {author|utf8|json}, | |
190 | "desc": {desc|utf8|json}, |
|
191 | "desc": {desc|utf8|json}, | |
191 | "abspath": {file|json}, |
|
192 | "abspath": {file|json}, | |
192 | "targetline": {targetline|json}, |
|
193 | "targetline": {targetline|json}, | |
193 | "line": {line|json}, |
|
194 | "line": {line|json}, | |
194 | "lineno": {lineno|json}, |
|
195 | "lineno": {lineno|json}, | |
195 | "revdate": {revdate|json} |
|
196 | "revdate": {revdate|json} | |
196 | }' |
|
197 | }' | |
197 | filelog = '\{ |
|
198 | filelog = '\{ | |
198 | "entries": [{join(entries%changelistentry, ", ")}] |
|
199 | "entries": [{join(entries%changelistentry, ", ")}] | |
199 | }' |
|
200 | }' | |
200 | graph = '"not yet implemented"' |
|
201 | graph = '"not yet implemented"' | |
201 | helptopics = '\{ |
|
202 | helptopics = '\{ | |
202 | "topics": [{join(topics%helptopicentry, ", ")}], |
|
203 | "topics": [{join(topics%helptopicentry, ", ")}], | |
203 | "earlycommands": [{join(earlycommands%helptopicentry, ", ")}], |
|
204 | "earlycommands": [{join(earlycommands%helptopicentry, ", ")}], | |
204 | "othercommands": [{join(othercommands%helptopicentry, ", ")}] |
|
205 | "othercommands": [{join(othercommands%helptopicentry, ", ")}] | |
205 | }' |
|
206 | }' | |
206 | helptopicentry = '\{ |
|
207 | helptopicentry = '\{ | |
207 | "topic": {topic|utf8|json}, |
|
208 | "topic": {topic|utf8|json}, | |
208 | "summary": {summary|utf8|json} |
|
209 | "summary": {summary|utf8|json} | |
209 | }' |
|
210 | }' | |
210 | help = '\{ |
|
211 | help = '\{ | |
211 | "topic": {topic|utf8|json}, |
|
212 | "topic": {topic|utf8|json}, | |
212 | "rawdoc": {doc|utf8|json} |
|
213 | "rawdoc": {doc|utf8|json} | |
213 | }' |
|
214 | }' | |
214 | filenodelink = '' |
|
215 | filenodelink = '' | |
215 | filenolink = '' |
|
216 | filenolink = '' | |
216 | index = '\{ |
|
217 | index = '\{ | |
217 | "entries": [{join(entries%indexentry, ", ")}] |
|
218 | "entries": [{join(entries%indexentry, ", ")}] | |
218 | }' |
|
219 | }' | |
219 | indexentry = '\{ |
|
220 | indexentry = '\{ | |
220 | "name": {name|utf8|json}, |
|
221 | "name": {name|utf8|json}, | |
221 | "description": {description|utf8|json}, |
|
222 | "description": {description|utf8|json}, | |
222 | "contact": {contact|utf8|json}, |
|
223 | "contact": {contact|utf8|json}, | |
223 | "lastchange": {lastchange|json} |
|
224 | "lastchange": {lastchange|json}, | |
|
225 | "labels": {labels|json} | |||
224 | }' |
|
226 | }' |
@@ -1,1641 +1,1642 b'' | |||||
1 | #require serve |
|
1 | #require serve | |
2 |
|
2 | |||
3 | $ request() { |
|
3 | $ request() { | |
4 | > get-with-headers.py --json localhost:$HGPORT "$1" |
|
4 | > get-with-headers.py --json localhost:$HGPORT "$1" | |
5 | > } |
|
5 | > } | |
6 |
|
6 | |||
7 | $ hg init test |
|
7 | $ hg init test | |
8 | $ cd test |
|
8 | $ cd test | |
9 | $ mkdir da |
|
9 | $ mkdir da | |
10 | $ echo foo > da/foo |
|
10 | $ echo foo > da/foo | |
11 | $ echo foo > foo |
|
11 | $ echo foo > foo | |
12 | $ hg -q ci -A -m initial |
|
12 | $ hg -q ci -A -m initial | |
13 | $ echo bar > foo |
|
13 | $ echo bar > foo | |
14 | $ hg ci -m 'modify foo' |
|
14 | $ hg ci -m 'modify foo' | |
15 | $ echo bar > da/foo |
|
15 | $ echo bar > da/foo | |
16 | $ hg ci -m 'modify da/foo' |
|
16 | $ hg ci -m 'modify da/foo' | |
17 | $ hg bookmark bookmark1 |
|
17 | $ hg bookmark bookmark1 | |
18 | $ hg up default |
|
18 | $ hg up default | |
19 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
19 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
20 | (leaving bookmark bookmark1) |
|
20 | (leaving bookmark bookmark1) | |
21 | $ hg mv foo foo-new |
|
21 | $ hg mv foo foo-new | |
22 | $ hg commit -m 'move foo' |
|
22 | $ hg commit -m 'move foo' | |
23 | $ hg tag -m 'create tag' tag1 |
|
23 | $ hg tag -m 'create tag' tag1 | |
24 | $ hg phase --public -r . |
|
24 | $ hg phase --public -r . | |
25 | $ echo baz > da/foo |
|
25 | $ echo baz > da/foo | |
26 | $ hg commit -m 'another commit to da/foo' |
|
26 | $ hg commit -m 'another commit to da/foo' | |
27 | $ hg tag -m 'create tag2' tag2 |
|
27 | $ hg tag -m 'create tag2' tag2 | |
28 | $ hg bookmark bookmark2 |
|
28 | $ hg bookmark bookmark2 | |
29 | $ hg -q up -r 0 |
|
29 | $ hg -q up -r 0 | |
30 | $ hg -q branch test-branch |
|
30 | $ hg -q branch test-branch | |
31 | $ echo branch > foo |
|
31 | $ echo branch > foo | |
32 | $ hg commit -m 'create test branch' |
|
32 | $ hg commit -m 'create test branch' | |
33 | $ echo branch_commit_2 > foo |
|
33 | $ echo branch_commit_2 > foo | |
34 | $ hg commit -m 'another commit in test-branch' |
|
34 | $ hg commit -m 'another commit in test-branch' | |
35 | $ hg -q up default |
|
35 | $ hg -q up default | |
36 | $ hg merge --tool :local test-branch |
|
36 | $ hg merge --tool :local test-branch | |
37 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
37 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |
38 | (branch merge, don't forget to commit) |
|
38 | (branch merge, don't forget to commit) | |
39 | $ hg commit -m 'merge test-branch into default' |
|
39 | $ hg commit -m 'merge test-branch into default' | |
40 |
|
40 | |||
41 | $ hg log -G |
|
41 | $ hg log -G | |
42 | @ changeset: 9:cc725e08502a |
|
42 | @ changeset: 9:cc725e08502a | |
43 | |\ tag: tip |
|
43 | |\ tag: tip | |
44 | | | parent: 6:ceed296fe500 |
|
44 | | | parent: 6:ceed296fe500 | |
45 | | | parent: 8:ed66c30e87eb |
|
45 | | | parent: 8:ed66c30e87eb | |
46 | | | user: test |
|
46 | | | user: test | |
47 | | | date: Thu Jan 01 00:00:00 1970 +0000 |
|
47 | | | date: Thu Jan 01 00:00:00 1970 +0000 | |
48 | | | summary: merge test-branch into default |
|
48 | | | summary: merge test-branch into default | |
49 | | | |
|
49 | | | | |
50 | | o changeset: 8:ed66c30e87eb |
|
50 | | o changeset: 8:ed66c30e87eb | |
51 | | | branch: test-branch |
|
51 | | | branch: test-branch | |
52 | | | user: test |
|
52 | | | user: test | |
53 | | | date: Thu Jan 01 00:00:00 1970 +0000 |
|
53 | | | date: Thu Jan 01 00:00:00 1970 +0000 | |
54 | | | summary: another commit in test-branch |
|
54 | | | summary: another commit in test-branch | |
55 | | | |
|
55 | | | | |
56 | | o changeset: 7:6ab967a8ab34 |
|
56 | | o changeset: 7:6ab967a8ab34 | |
57 | | | branch: test-branch |
|
57 | | | branch: test-branch | |
58 | | | parent: 0:06e557f3edf6 |
|
58 | | | parent: 0:06e557f3edf6 | |
59 | | | user: test |
|
59 | | | user: test | |
60 | | | date: Thu Jan 01 00:00:00 1970 +0000 |
|
60 | | | date: Thu Jan 01 00:00:00 1970 +0000 | |
61 | | | summary: create test branch |
|
61 | | | summary: create test branch | |
62 | | | |
|
62 | | | | |
63 | o | changeset: 6:ceed296fe500 |
|
63 | o | changeset: 6:ceed296fe500 | |
64 | | | bookmark: bookmark2 |
|
64 | | | bookmark: bookmark2 | |
65 | | | user: test |
|
65 | | | user: test | |
66 | | | date: Thu Jan 01 00:00:00 1970 +0000 |
|
66 | | | date: Thu Jan 01 00:00:00 1970 +0000 | |
67 | | | summary: create tag2 |
|
67 | | | summary: create tag2 | |
68 | | | |
|
68 | | | | |
69 | o | changeset: 5:f2890a05fea4 |
|
69 | o | changeset: 5:f2890a05fea4 | |
70 | | | tag: tag2 |
|
70 | | | tag: tag2 | |
71 | | | user: test |
|
71 | | | user: test | |
72 | | | date: Thu Jan 01 00:00:00 1970 +0000 |
|
72 | | | date: Thu Jan 01 00:00:00 1970 +0000 | |
73 | | | summary: another commit to da/foo |
|
73 | | | summary: another commit to da/foo | |
74 | | | |
|
74 | | | | |
75 | o | changeset: 4:93a8ce14f891 |
|
75 | o | changeset: 4:93a8ce14f891 | |
76 | | | user: test |
|
76 | | | user: test | |
77 | | | date: Thu Jan 01 00:00:00 1970 +0000 |
|
77 | | | date: Thu Jan 01 00:00:00 1970 +0000 | |
78 | | | summary: create tag |
|
78 | | | summary: create tag | |
79 | | | |
|
79 | | | | |
80 | o | changeset: 3:78896eb0e102 |
|
80 | o | changeset: 3:78896eb0e102 | |
81 | | | tag: tag1 |
|
81 | | | tag: tag1 | |
82 | | | user: test |
|
82 | | | user: test | |
83 | | | date: Thu Jan 01 00:00:00 1970 +0000 |
|
83 | | | date: Thu Jan 01 00:00:00 1970 +0000 | |
84 | | | summary: move foo |
|
84 | | | summary: move foo | |
85 | | | |
|
85 | | | | |
86 | o | changeset: 2:8d7c456572ac |
|
86 | o | changeset: 2:8d7c456572ac | |
87 | | | bookmark: bookmark1 |
|
87 | | | bookmark: bookmark1 | |
88 | | | user: test |
|
88 | | | user: test | |
89 | | | date: Thu Jan 01 00:00:00 1970 +0000 |
|
89 | | | date: Thu Jan 01 00:00:00 1970 +0000 | |
90 | | | summary: modify da/foo |
|
90 | | | summary: modify da/foo | |
91 | | | |
|
91 | | | | |
92 | o | changeset: 1:f8bbb9024b10 |
|
92 | o | changeset: 1:f8bbb9024b10 | |
93 | |/ user: test |
|
93 | |/ user: test | |
94 | | date: Thu Jan 01 00:00:00 1970 +0000 |
|
94 | | date: Thu Jan 01 00:00:00 1970 +0000 | |
95 | | summary: modify foo |
|
95 | | summary: modify foo | |
96 | | |
|
96 | | | |
97 | o changeset: 0:06e557f3edf6 |
|
97 | o changeset: 0:06e557f3edf6 | |
98 | user: test |
|
98 | user: test | |
99 | date: Thu Jan 01 00:00:00 1970 +0000 |
|
99 | date: Thu Jan 01 00:00:00 1970 +0000 | |
100 | summary: initial |
|
100 | summary: initial | |
101 |
|
101 | |||
102 |
|
102 | |||
103 | $ echo '[web]' >> .hg/hgrc |
|
103 | $ echo '[web]' >> .hg/hgrc | |
104 | $ echo 'allow_archive = bz2' >> .hg/hgrc |
|
104 | $ echo 'allow_archive = bz2' >> .hg/hgrc | |
105 | $ hg serve -p $HGPORT -d --pid-file=hg.pid -A access.log -E error.log |
|
105 | $ hg serve -p $HGPORT -d --pid-file=hg.pid -A access.log -E error.log | |
106 | $ cat hg.pid >> $DAEMON_PIDS |
|
106 | $ cat hg.pid >> $DAEMON_PIDS | |
107 |
|
107 | |||
108 | (Try to keep these in roughly the order they are defined in webcommands.py) |
|
108 | (Try to keep these in roughly the order they are defined in webcommands.py) | |
109 |
|
109 | |||
110 | (log is handled by filelog/ and changelog/ - ignore it) |
|
110 | (log is handled by filelog/ and changelog/ - ignore it) | |
111 |
|
111 | |||
112 | (rawfile/ doesn't use templating - nothing to test) |
|
112 | (rawfile/ doesn't use templating - nothing to test) | |
113 |
|
113 | |||
114 | file/{revision}/{path} shows file revision |
|
114 | file/{revision}/{path} shows file revision | |
115 |
|
115 | |||
116 | $ request json-file/78896eb0e102/foo-new |
|
116 | $ request json-file/78896eb0e102/foo-new | |
117 | 200 Script output follows |
|
117 | 200 Script output follows | |
118 |
|
118 | |||
119 | { |
|
119 | { | |
120 | "bookmarks": [], |
|
120 | "bookmarks": [], | |
121 | "branch": "default", |
|
121 | "branch": "default", | |
122 | "date": [ |
|
122 | "date": [ | |
123 | 0.0, |
|
123 | 0.0, | |
124 | 0 |
|
124 | 0 | |
125 | ], |
|
125 | ], | |
126 | "desc": "move foo", |
|
126 | "desc": "move foo", | |
127 | "lines": [ |
|
127 | "lines": [ | |
128 | { |
|
128 | { | |
129 | "line": "bar\n" |
|
129 | "line": "bar\n" | |
130 | } |
|
130 | } | |
131 | ], |
|
131 | ], | |
132 | "node": "78896eb0e102174ce9278438a95e12543e4367a7", |
|
132 | "node": "78896eb0e102174ce9278438a95e12543e4367a7", | |
133 | "parents": [ |
|
133 | "parents": [ | |
134 | "f8bbb9024b10f93cdbb8d940337398291d40dea8" |
|
134 | "f8bbb9024b10f93cdbb8d940337398291d40dea8" | |
135 | ], |
|
135 | ], | |
136 | "path": "foo-new", |
|
136 | "path": "foo-new", | |
137 | "phase": "public", |
|
137 | "phase": "public", | |
138 | "tags": [ |
|
138 | "tags": [ | |
139 | "tag1" |
|
139 | "tag1" | |
140 | ], |
|
140 | ], | |
141 | "user": "test" |
|
141 | "user": "test" | |
142 | } |
|
142 | } | |
143 |
|
143 | |||
144 | file/{revision} shows root directory info |
|
144 | file/{revision} shows root directory info | |
145 |
|
145 | |||
146 | $ request json-file/cc725e08502a |
|
146 | $ request json-file/cc725e08502a | |
147 | 200 Script output follows |
|
147 | 200 Script output follows | |
148 |
|
148 | |||
149 | { |
|
149 | { | |
150 | "abspath": "/", |
|
150 | "abspath": "/", | |
151 | "bookmarks": [], |
|
151 | "bookmarks": [], | |
152 | "directories": [ |
|
152 | "directories": [ | |
153 | { |
|
153 | { | |
154 | "abspath": "/da", |
|
154 | "abspath": "/da", | |
155 | "basename": "da", |
|
155 | "basename": "da", | |
156 | "emptydirs": "" |
|
156 | "emptydirs": "" | |
157 | } |
|
157 | } | |
158 | ], |
|
158 | ], | |
159 | "files": [ |
|
159 | "files": [ | |
160 | { |
|
160 | { | |
161 | "abspath": ".hgtags", |
|
161 | "abspath": ".hgtags", | |
162 | "basename": ".hgtags", |
|
162 | "basename": ".hgtags", | |
163 | "date": [ |
|
163 | "date": [ | |
164 | 0.0, |
|
164 | 0.0, | |
165 | 0 |
|
165 | 0 | |
166 | ], |
|
166 | ], | |
167 | "flags": "", |
|
167 | "flags": "", | |
168 | "size": 92 |
|
168 | "size": 92 | |
169 | }, |
|
169 | }, | |
170 | { |
|
170 | { | |
171 | "abspath": "foo-new", |
|
171 | "abspath": "foo-new", | |
172 | "basename": "foo-new", |
|
172 | "basename": "foo-new", | |
173 | "date": [ |
|
173 | "date": [ | |
174 | 0.0, |
|
174 | 0.0, | |
175 | 0 |
|
175 | 0 | |
176 | ], |
|
176 | ], | |
177 | "flags": "", |
|
177 | "flags": "", | |
178 | "size": 4 |
|
178 | "size": 4 | |
179 | } |
|
179 | } | |
180 | ], |
|
180 | ], | |
181 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7", |
|
181 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7", | |
182 | "tags": [ |
|
182 | "tags": [ | |
183 | "tip" |
|
183 | "tip" | |
184 | ] |
|
184 | ] | |
185 | } |
|
185 | } | |
186 |
|
186 | |||
187 | changelog/ shows information about several changesets |
|
187 | changelog/ shows information about several changesets | |
188 |
|
188 | |||
189 | $ request json-changelog |
|
189 | $ request json-changelog | |
190 | 200 Script output follows |
|
190 | 200 Script output follows | |
191 |
|
191 | |||
192 | { |
|
192 | { | |
193 | "changeset_count": 10, |
|
193 | "changeset_count": 10, | |
194 | "changesets": [ |
|
194 | "changesets": [ | |
195 | { |
|
195 | { | |
196 | "bookmarks": [], |
|
196 | "bookmarks": [], | |
197 | "branch": "default", |
|
197 | "branch": "default", | |
198 | "date": [ |
|
198 | "date": [ | |
199 | 0.0, |
|
199 | 0.0, | |
200 | 0 |
|
200 | 0 | |
201 | ], |
|
201 | ], | |
202 | "desc": "merge test-branch into default", |
|
202 | "desc": "merge test-branch into default", | |
203 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7", |
|
203 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7", | |
204 | "parents": [ |
|
204 | "parents": [ | |
205 | "ceed296fe500c3fac9541e31dad860cb49c89e45", |
|
205 | "ceed296fe500c3fac9541e31dad860cb49c89e45", | |
206 | "ed66c30e87eb65337c05a4229efaa5f1d5285a90" |
|
206 | "ed66c30e87eb65337c05a4229efaa5f1d5285a90" | |
207 | ], |
|
207 | ], | |
208 | "phase": "draft", |
|
208 | "phase": "draft", | |
209 | "tags": [ |
|
209 | "tags": [ | |
210 | "tip" |
|
210 | "tip" | |
211 | ], |
|
211 | ], | |
212 | "user": "test" |
|
212 | "user": "test" | |
213 | }, |
|
213 | }, | |
214 | { |
|
214 | { | |
215 | "bookmarks": [], |
|
215 | "bookmarks": [], | |
216 | "branch": "test-branch", |
|
216 | "branch": "test-branch", | |
217 | "date": [ |
|
217 | "date": [ | |
218 | 0.0, |
|
218 | 0.0, | |
219 | 0 |
|
219 | 0 | |
220 | ], |
|
220 | ], | |
221 | "desc": "another commit in test-branch", |
|
221 | "desc": "another commit in test-branch", | |
222 | "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90", |
|
222 | "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90", | |
223 | "parents": [ |
|
223 | "parents": [ | |
224 | "6ab967a8ab3489227a83f80e920faa039a71819f" |
|
224 | "6ab967a8ab3489227a83f80e920faa039a71819f" | |
225 | ], |
|
225 | ], | |
226 | "phase": "draft", |
|
226 | "phase": "draft", | |
227 | "tags": [], |
|
227 | "tags": [], | |
228 | "user": "test" |
|
228 | "user": "test" | |
229 | }, |
|
229 | }, | |
230 | { |
|
230 | { | |
231 | "bookmarks": [], |
|
231 | "bookmarks": [], | |
232 | "branch": "test-branch", |
|
232 | "branch": "test-branch", | |
233 | "date": [ |
|
233 | "date": [ | |
234 | 0.0, |
|
234 | 0.0, | |
235 | 0 |
|
235 | 0 | |
236 | ], |
|
236 | ], | |
237 | "desc": "create test branch", |
|
237 | "desc": "create test branch", | |
238 | "node": "6ab967a8ab3489227a83f80e920faa039a71819f", |
|
238 | "node": "6ab967a8ab3489227a83f80e920faa039a71819f", | |
239 | "parents": [ |
|
239 | "parents": [ | |
240 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" |
|
240 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" | |
241 | ], |
|
241 | ], | |
242 | "phase": "draft", |
|
242 | "phase": "draft", | |
243 | "tags": [], |
|
243 | "tags": [], | |
244 | "user": "test" |
|
244 | "user": "test" | |
245 | }, |
|
245 | }, | |
246 | { |
|
246 | { | |
247 | "bookmarks": [ |
|
247 | "bookmarks": [ | |
248 | "bookmark2" |
|
248 | "bookmark2" | |
249 | ], |
|
249 | ], | |
250 | "branch": "default", |
|
250 | "branch": "default", | |
251 | "date": [ |
|
251 | "date": [ | |
252 | 0.0, |
|
252 | 0.0, | |
253 | 0 |
|
253 | 0 | |
254 | ], |
|
254 | ], | |
255 | "desc": "create tag2", |
|
255 | "desc": "create tag2", | |
256 | "node": "ceed296fe500c3fac9541e31dad860cb49c89e45", |
|
256 | "node": "ceed296fe500c3fac9541e31dad860cb49c89e45", | |
257 | "parents": [ |
|
257 | "parents": [ | |
258 | "f2890a05fea49bfaf9fb27ed5490894eba32da78" |
|
258 | "f2890a05fea49bfaf9fb27ed5490894eba32da78" | |
259 | ], |
|
259 | ], | |
260 | "phase": "draft", |
|
260 | "phase": "draft", | |
261 | "tags": [], |
|
261 | "tags": [], | |
262 | "user": "test" |
|
262 | "user": "test" | |
263 | }, |
|
263 | }, | |
264 | { |
|
264 | { | |
265 | "bookmarks": [], |
|
265 | "bookmarks": [], | |
266 | "branch": "default", |
|
266 | "branch": "default", | |
267 | "date": [ |
|
267 | "date": [ | |
268 | 0.0, |
|
268 | 0.0, | |
269 | 0 |
|
269 | 0 | |
270 | ], |
|
270 | ], | |
271 | "desc": "another commit to da/foo", |
|
271 | "desc": "another commit to da/foo", | |
272 | "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78", |
|
272 | "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78", | |
273 | "parents": [ |
|
273 | "parents": [ | |
274 | "93a8ce14f89156426b7fa981af8042da53f03aa0" |
|
274 | "93a8ce14f89156426b7fa981af8042da53f03aa0" | |
275 | ], |
|
275 | ], | |
276 | "phase": "draft", |
|
276 | "phase": "draft", | |
277 | "tags": [ |
|
277 | "tags": [ | |
278 | "tag2" |
|
278 | "tag2" | |
279 | ], |
|
279 | ], | |
280 | "user": "test" |
|
280 | "user": "test" | |
281 | }, |
|
281 | }, | |
282 | { |
|
282 | { | |
283 | "bookmarks": [], |
|
283 | "bookmarks": [], | |
284 | "branch": "default", |
|
284 | "branch": "default", | |
285 | "date": [ |
|
285 | "date": [ | |
286 | 0.0, |
|
286 | 0.0, | |
287 | 0 |
|
287 | 0 | |
288 | ], |
|
288 | ], | |
289 | "desc": "create tag", |
|
289 | "desc": "create tag", | |
290 | "node": "93a8ce14f89156426b7fa981af8042da53f03aa0", |
|
290 | "node": "93a8ce14f89156426b7fa981af8042da53f03aa0", | |
291 | "parents": [ |
|
291 | "parents": [ | |
292 | "78896eb0e102174ce9278438a95e12543e4367a7" |
|
292 | "78896eb0e102174ce9278438a95e12543e4367a7" | |
293 | ], |
|
293 | ], | |
294 | "phase": "public", |
|
294 | "phase": "public", | |
295 | "tags": [], |
|
295 | "tags": [], | |
296 | "user": "test" |
|
296 | "user": "test" | |
297 | }, |
|
297 | }, | |
298 | { |
|
298 | { | |
299 | "bookmarks": [], |
|
299 | "bookmarks": [], | |
300 | "branch": "default", |
|
300 | "branch": "default", | |
301 | "date": [ |
|
301 | "date": [ | |
302 | 0.0, |
|
302 | 0.0, | |
303 | 0 |
|
303 | 0 | |
304 | ], |
|
304 | ], | |
305 | "desc": "move foo", |
|
305 | "desc": "move foo", | |
306 | "node": "78896eb0e102174ce9278438a95e12543e4367a7", |
|
306 | "node": "78896eb0e102174ce9278438a95e12543e4367a7", | |
307 | "parents": [ |
|
307 | "parents": [ | |
308 | "8d7c456572acf3557e8ed8a07286b10c408bcec5" |
|
308 | "8d7c456572acf3557e8ed8a07286b10c408bcec5" | |
309 | ], |
|
309 | ], | |
310 | "phase": "public", |
|
310 | "phase": "public", | |
311 | "tags": [ |
|
311 | "tags": [ | |
312 | "tag1" |
|
312 | "tag1" | |
313 | ], |
|
313 | ], | |
314 | "user": "test" |
|
314 | "user": "test" | |
315 | }, |
|
315 | }, | |
316 | { |
|
316 | { | |
317 | "bookmarks": [ |
|
317 | "bookmarks": [ | |
318 | "bookmark1" |
|
318 | "bookmark1" | |
319 | ], |
|
319 | ], | |
320 | "branch": "default", |
|
320 | "branch": "default", | |
321 | "date": [ |
|
321 | "date": [ | |
322 | 0.0, |
|
322 | 0.0, | |
323 | 0 |
|
323 | 0 | |
324 | ], |
|
324 | ], | |
325 | "desc": "modify da/foo", |
|
325 | "desc": "modify da/foo", | |
326 | "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5", |
|
326 | "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5", | |
327 | "parents": [ |
|
327 | "parents": [ | |
328 | "f8bbb9024b10f93cdbb8d940337398291d40dea8" |
|
328 | "f8bbb9024b10f93cdbb8d940337398291d40dea8" | |
329 | ], |
|
329 | ], | |
330 | "phase": "public", |
|
330 | "phase": "public", | |
331 | "tags": [], |
|
331 | "tags": [], | |
332 | "user": "test" |
|
332 | "user": "test" | |
333 | }, |
|
333 | }, | |
334 | { |
|
334 | { | |
335 | "bookmarks": [], |
|
335 | "bookmarks": [], | |
336 | "branch": "default", |
|
336 | "branch": "default", | |
337 | "date": [ |
|
337 | "date": [ | |
338 | 0.0, |
|
338 | 0.0, | |
339 | 0 |
|
339 | 0 | |
340 | ], |
|
340 | ], | |
341 | "desc": "modify foo", |
|
341 | "desc": "modify foo", | |
342 | "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8", |
|
342 | "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8", | |
343 | "parents": [ |
|
343 | "parents": [ | |
344 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" |
|
344 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" | |
345 | ], |
|
345 | ], | |
346 | "phase": "public", |
|
346 | "phase": "public", | |
347 | "tags": [], |
|
347 | "tags": [], | |
348 | "user": "test" |
|
348 | "user": "test" | |
349 | }, |
|
349 | }, | |
350 | { |
|
350 | { | |
351 | "bookmarks": [], |
|
351 | "bookmarks": [], | |
352 | "branch": "default", |
|
352 | "branch": "default", | |
353 | "date": [ |
|
353 | "date": [ | |
354 | 0.0, |
|
354 | 0.0, | |
355 | 0 |
|
355 | 0 | |
356 | ], |
|
356 | ], | |
357 | "desc": "initial", |
|
357 | "desc": "initial", | |
358 | "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e", |
|
358 | "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e", | |
359 | "parents": [], |
|
359 | "parents": [], | |
360 | "phase": "public", |
|
360 | "phase": "public", | |
361 | "tags": [], |
|
361 | "tags": [], | |
362 | "user": "test" |
|
362 | "user": "test" | |
363 | } |
|
363 | } | |
364 | ], |
|
364 | ], | |
365 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7" |
|
365 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7" | |
366 | } |
|
366 | } | |
367 |
|
367 | |||
368 | changelog/{revision} shows information starting at a specific changeset |
|
368 | changelog/{revision} shows information starting at a specific changeset | |
369 |
|
369 | |||
370 | $ request json-changelog/f8bbb9024b10 |
|
370 | $ request json-changelog/f8bbb9024b10 | |
371 | 200 Script output follows |
|
371 | 200 Script output follows | |
372 |
|
372 | |||
373 | { |
|
373 | { | |
374 | "changeset_count": 10, |
|
374 | "changeset_count": 10, | |
375 | "changesets": [ |
|
375 | "changesets": [ | |
376 | { |
|
376 | { | |
377 | "bookmarks": [], |
|
377 | "bookmarks": [], | |
378 | "branch": "default", |
|
378 | "branch": "default", | |
379 | "date": [ |
|
379 | "date": [ | |
380 | 0.0, |
|
380 | 0.0, | |
381 | 0 |
|
381 | 0 | |
382 | ], |
|
382 | ], | |
383 | "desc": "modify foo", |
|
383 | "desc": "modify foo", | |
384 | "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8", |
|
384 | "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8", | |
385 | "parents": [ |
|
385 | "parents": [ | |
386 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" |
|
386 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" | |
387 | ], |
|
387 | ], | |
388 | "phase": "public", |
|
388 | "phase": "public", | |
389 | "tags": [], |
|
389 | "tags": [], | |
390 | "user": "test" |
|
390 | "user": "test" | |
391 | }, |
|
391 | }, | |
392 | { |
|
392 | { | |
393 | "bookmarks": [], |
|
393 | "bookmarks": [], | |
394 | "branch": "default", |
|
394 | "branch": "default", | |
395 | "date": [ |
|
395 | "date": [ | |
396 | 0.0, |
|
396 | 0.0, | |
397 | 0 |
|
397 | 0 | |
398 | ], |
|
398 | ], | |
399 | "desc": "initial", |
|
399 | "desc": "initial", | |
400 | "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e", |
|
400 | "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e", | |
401 | "parents": [], |
|
401 | "parents": [], | |
402 | "phase": "public", |
|
402 | "phase": "public", | |
403 | "tags": [], |
|
403 | "tags": [], | |
404 | "user": "test" |
|
404 | "user": "test" | |
405 | } |
|
405 | } | |
406 | ], |
|
406 | ], | |
407 | "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8" |
|
407 | "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8" | |
408 | } |
|
408 | } | |
409 |
|
409 | |||
410 | shortlog/ shows information about a set of changesets |
|
410 | shortlog/ shows information about a set of changesets | |
411 |
|
411 | |||
412 | $ request json-shortlog |
|
412 | $ request json-shortlog | |
413 | 200 Script output follows |
|
413 | 200 Script output follows | |
414 |
|
414 | |||
415 | { |
|
415 | { | |
416 | "changeset_count": 10, |
|
416 | "changeset_count": 10, | |
417 | "changesets": [ |
|
417 | "changesets": [ | |
418 | { |
|
418 | { | |
419 | "bookmarks": [], |
|
419 | "bookmarks": [], | |
420 | "branch": "default", |
|
420 | "branch": "default", | |
421 | "date": [ |
|
421 | "date": [ | |
422 | 0.0, |
|
422 | 0.0, | |
423 | 0 |
|
423 | 0 | |
424 | ], |
|
424 | ], | |
425 | "desc": "merge test-branch into default", |
|
425 | "desc": "merge test-branch into default", | |
426 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7", |
|
426 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7", | |
427 | "parents": [ |
|
427 | "parents": [ | |
428 | "ceed296fe500c3fac9541e31dad860cb49c89e45", |
|
428 | "ceed296fe500c3fac9541e31dad860cb49c89e45", | |
429 | "ed66c30e87eb65337c05a4229efaa5f1d5285a90" |
|
429 | "ed66c30e87eb65337c05a4229efaa5f1d5285a90" | |
430 | ], |
|
430 | ], | |
431 | "phase": "draft", |
|
431 | "phase": "draft", | |
432 | "tags": [ |
|
432 | "tags": [ | |
433 | "tip" |
|
433 | "tip" | |
434 | ], |
|
434 | ], | |
435 | "user": "test" |
|
435 | "user": "test" | |
436 | }, |
|
436 | }, | |
437 | { |
|
437 | { | |
438 | "bookmarks": [], |
|
438 | "bookmarks": [], | |
439 | "branch": "test-branch", |
|
439 | "branch": "test-branch", | |
440 | "date": [ |
|
440 | "date": [ | |
441 | 0.0, |
|
441 | 0.0, | |
442 | 0 |
|
442 | 0 | |
443 | ], |
|
443 | ], | |
444 | "desc": "another commit in test-branch", |
|
444 | "desc": "another commit in test-branch", | |
445 | "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90", |
|
445 | "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90", | |
446 | "parents": [ |
|
446 | "parents": [ | |
447 | "6ab967a8ab3489227a83f80e920faa039a71819f" |
|
447 | "6ab967a8ab3489227a83f80e920faa039a71819f" | |
448 | ], |
|
448 | ], | |
449 | "phase": "draft", |
|
449 | "phase": "draft", | |
450 | "tags": [], |
|
450 | "tags": [], | |
451 | "user": "test" |
|
451 | "user": "test" | |
452 | }, |
|
452 | }, | |
453 | { |
|
453 | { | |
454 | "bookmarks": [], |
|
454 | "bookmarks": [], | |
455 | "branch": "test-branch", |
|
455 | "branch": "test-branch", | |
456 | "date": [ |
|
456 | "date": [ | |
457 | 0.0, |
|
457 | 0.0, | |
458 | 0 |
|
458 | 0 | |
459 | ], |
|
459 | ], | |
460 | "desc": "create test branch", |
|
460 | "desc": "create test branch", | |
461 | "node": "6ab967a8ab3489227a83f80e920faa039a71819f", |
|
461 | "node": "6ab967a8ab3489227a83f80e920faa039a71819f", | |
462 | "parents": [ |
|
462 | "parents": [ | |
463 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" |
|
463 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" | |
464 | ], |
|
464 | ], | |
465 | "phase": "draft", |
|
465 | "phase": "draft", | |
466 | "tags": [], |
|
466 | "tags": [], | |
467 | "user": "test" |
|
467 | "user": "test" | |
468 | }, |
|
468 | }, | |
469 | { |
|
469 | { | |
470 | "bookmarks": [ |
|
470 | "bookmarks": [ | |
471 | "bookmark2" |
|
471 | "bookmark2" | |
472 | ], |
|
472 | ], | |
473 | "branch": "default", |
|
473 | "branch": "default", | |
474 | "date": [ |
|
474 | "date": [ | |
475 | 0.0, |
|
475 | 0.0, | |
476 | 0 |
|
476 | 0 | |
477 | ], |
|
477 | ], | |
478 | "desc": "create tag2", |
|
478 | "desc": "create tag2", | |
479 | "node": "ceed296fe500c3fac9541e31dad860cb49c89e45", |
|
479 | "node": "ceed296fe500c3fac9541e31dad860cb49c89e45", | |
480 | "parents": [ |
|
480 | "parents": [ | |
481 | "f2890a05fea49bfaf9fb27ed5490894eba32da78" |
|
481 | "f2890a05fea49bfaf9fb27ed5490894eba32da78" | |
482 | ], |
|
482 | ], | |
483 | "phase": "draft", |
|
483 | "phase": "draft", | |
484 | "tags": [], |
|
484 | "tags": [], | |
485 | "user": "test" |
|
485 | "user": "test" | |
486 | }, |
|
486 | }, | |
487 | { |
|
487 | { | |
488 | "bookmarks": [], |
|
488 | "bookmarks": [], | |
489 | "branch": "default", |
|
489 | "branch": "default", | |
490 | "date": [ |
|
490 | "date": [ | |
491 | 0.0, |
|
491 | 0.0, | |
492 | 0 |
|
492 | 0 | |
493 | ], |
|
493 | ], | |
494 | "desc": "another commit to da/foo", |
|
494 | "desc": "another commit to da/foo", | |
495 | "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78", |
|
495 | "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78", | |
496 | "parents": [ |
|
496 | "parents": [ | |
497 | "93a8ce14f89156426b7fa981af8042da53f03aa0" |
|
497 | "93a8ce14f89156426b7fa981af8042da53f03aa0" | |
498 | ], |
|
498 | ], | |
499 | "phase": "draft", |
|
499 | "phase": "draft", | |
500 | "tags": [ |
|
500 | "tags": [ | |
501 | "tag2" |
|
501 | "tag2" | |
502 | ], |
|
502 | ], | |
503 | "user": "test" |
|
503 | "user": "test" | |
504 | }, |
|
504 | }, | |
505 | { |
|
505 | { | |
506 | "bookmarks": [], |
|
506 | "bookmarks": [], | |
507 | "branch": "default", |
|
507 | "branch": "default", | |
508 | "date": [ |
|
508 | "date": [ | |
509 | 0.0, |
|
509 | 0.0, | |
510 | 0 |
|
510 | 0 | |
511 | ], |
|
511 | ], | |
512 | "desc": "create tag", |
|
512 | "desc": "create tag", | |
513 | "node": "93a8ce14f89156426b7fa981af8042da53f03aa0", |
|
513 | "node": "93a8ce14f89156426b7fa981af8042da53f03aa0", | |
514 | "parents": [ |
|
514 | "parents": [ | |
515 | "78896eb0e102174ce9278438a95e12543e4367a7" |
|
515 | "78896eb0e102174ce9278438a95e12543e4367a7" | |
516 | ], |
|
516 | ], | |
517 | "phase": "public", |
|
517 | "phase": "public", | |
518 | "tags": [], |
|
518 | "tags": [], | |
519 | "user": "test" |
|
519 | "user": "test" | |
520 | }, |
|
520 | }, | |
521 | { |
|
521 | { | |
522 | "bookmarks": [], |
|
522 | "bookmarks": [], | |
523 | "branch": "default", |
|
523 | "branch": "default", | |
524 | "date": [ |
|
524 | "date": [ | |
525 | 0.0, |
|
525 | 0.0, | |
526 | 0 |
|
526 | 0 | |
527 | ], |
|
527 | ], | |
528 | "desc": "move foo", |
|
528 | "desc": "move foo", | |
529 | "node": "78896eb0e102174ce9278438a95e12543e4367a7", |
|
529 | "node": "78896eb0e102174ce9278438a95e12543e4367a7", | |
530 | "parents": [ |
|
530 | "parents": [ | |
531 | "8d7c456572acf3557e8ed8a07286b10c408bcec5" |
|
531 | "8d7c456572acf3557e8ed8a07286b10c408bcec5" | |
532 | ], |
|
532 | ], | |
533 | "phase": "public", |
|
533 | "phase": "public", | |
534 | "tags": [ |
|
534 | "tags": [ | |
535 | "tag1" |
|
535 | "tag1" | |
536 | ], |
|
536 | ], | |
537 | "user": "test" |
|
537 | "user": "test" | |
538 | }, |
|
538 | }, | |
539 | { |
|
539 | { | |
540 | "bookmarks": [ |
|
540 | "bookmarks": [ | |
541 | "bookmark1" |
|
541 | "bookmark1" | |
542 | ], |
|
542 | ], | |
543 | "branch": "default", |
|
543 | "branch": "default", | |
544 | "date": [ |
|
544 | "date": [ | |
545 | 0.0, |
|
545 | 0.0, | |
546 | 0 |
|
546 | 0 | |
547 | ], |
|
547 | ], | |
548 | "desc": "modify da/foo", |
|
548 | "desc": "modify da/foo", | |
549 | "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5", |
|
549 | "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5", | |
550 | "parents": [ |
|
550 | "parents": [ | |
551 | "f8bbb9024b10f93cdbb8d940337398291d40dea8" |
|
551 | "f8bbb9024b10f93cdbb8d940337398291d40dea8" | |
552 | ], |
|
552 | ], | |
553 | "phase": "public", |
|
553 | "phase": "public", | |
554 | "tags": [], |
|
554 | "tags": [], | |
555 | "user": "test" |
|
555 | "user": "test" | |
556 | }, |
|
556 | }, | |
557 | { |
|
557 | { | |
558 | "bookmarks": [], |
|
558 | "bookmarks": [], | |
559 | "branch": "default", |
|
559 | "branch": "default", | |
560 | "date": [ |
|
560 | "date": [ | |
561 | 0.0, |
|
561 | 0.0, | |
562 | 0 |
|
562 | 0 | |
563 | ], |
|
563 | ], | |
564 | "desc": "modify foo", |
|
564 | "desc": "modify foo", | |
565 | "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8", |
|
565 | "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8", | |
566 | "parents": [ |
|
566 | "parents": [ | |
567 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" |
|
567 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" | |
568 | ], |
|
568 | ], | |
569 | "phase": "public", |
|
569 | "phase": "public", | |
570 | "tags": [], |
|
570 | "tags": [], | |
571 | "user": "test" |
|
571 | "user": "test" | |
572 | }, |
|
572 | }, | |
573 | { |
|
573 | { | |
574 | "bookmarks": [], |
|
574 | "bookmarks": [], | |
575 | "branch": "default", |
|
575 | "branch": "default", | |
576 | "date": [ |
|
576 | "date": [ | |
577 | 0.0, |
|
577 | 0.0, | |
578 | 0 |
|
578 | 0 | |
579 | ], |
|
579 | ], | |
580 | "desc": "initial", |
|
580 | "desc": "initial", | |
581 | "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e", |
|
581 | "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e", | |
582 | "parents": [], |
|
582 | "parents": [], | |
583 | "phase": "public", |
|
583 | "phase": "public", | |
584 | "tags": [], |
|
584 | "tags": [], | |
585 | "user": "test" |
|
585 | "user": "test" | |
586 | } |
|
586 | } | |
587 | ], |
|
587 | ], | |
588 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7" |
|
588 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7" | |
589 | } |
|
589 | } | |
590 |
|
590 | |||
591 | changeset/ renders the tip changeset |
|
591 | changeset/ renders the tip changeset | |
592 |
|
592 | |||
593 | $ request json-rev |
|
593 | $ request json-rev | |
594 | 200 Script output follows |
|
594 | 200 Script output follows | |
595 |
|
595 | |||
596 | { |
|
596 | { | |
597 | "bookmarks": [], |
|
597 | "bookmarks": [], | |
598 | "branch": "default", |
|
598 | "branch": "default", | |
599 | "date": [ |
|
599 | "date": [ | |
600 | 0.0, |
|
600 | 0.0, | |
601 | 0 |
|
601 | 0 | |
602 | ], |
|
602 | ], | |
603 | "desc": "merge test-branch into default", |
|
603 | "desc": "merge test-branch into default", | |
604 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7", |
|
604 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7", | |
605 | "parents": [ |
|
605 | "parents": [ | |
606 | "ceed296fe500c3fac9541e31dad860cb49c89e45", |
|
606 | "ceed296fe500c3fac9541e31dad860cb49c89e45", | |
607 | "ed66c30e87eb65337c05a4229efaa5f1d5285a90" |
|
607 | "ed66c30e87eb65337c05a4229efaa5f1d5285a90" | |
608 | ], |
|
608 | ], | |
609 | "phase": "draft", |
|
609 | "phase": "draft", | |
610 | "tags": [ |
|
610 | "tags": [ | |
611 | "tip" |
|
611 | "tip" | |
612 | ], |
|
612 | ], | |
613 | "user": "test" |
|
613 | "user": "test" | |
614 | } |
|
614 | } | |
615 |
|
615 | |||
616 | changeset/{revision} shows tags |
|
616 | changeset/{revision} shows tags | |
617 |
|
617 | |||
618 | $ request json-rev/78896eb0e102 |
|
618 | $ request json-rev/78896eb0e102 | |
619 | 200 Script output follows |
|
619 | 200 Script output follows | |
620 |
|
620 | |||
621 | { |
|
621 | { | |
622 | "bookmarks": [], |
|
622 | "bookmarks": [], | |
623 | "branch": "default", |
|
623 | "branch": "default", | |
624 | "date": [ |
|
624 | "date": [ | |
625 | 0.0, |
|
625 | 0.0, | |
626 | 0 |
|
626 | 0 | |
627 | ], |
|
627 | ], | |
628 | "desc": "move foo", |
|
628 | "desc": "move foo", | |
629 | "node": "78896eb0e102174ce9278438a95e12543e4367a7", |
|
629 | "node": "78896eb0e102174ce9278438a95e12543e4367a7", | |
630 | "parents": [ |
|
630 | "parents": [ | |
631 | "8d7c456572acf3557e8ed8a07286b10c408bcec5" |
|
631 | "8d7c456572acf3557e8ed8a07286b10c408bcec5" | |
632 | ], |
|
632 | ], | |
633 | "phase": "public", |
|
633 | "phase": "public", | |
634 | "tags": [ |
|
634 | "tags": [ | |
635 | "tag1" |
|
635 | "tag1" | |
636 | ], |
|
636 | ], | |
637 | "user": "test" |
|
637 | "user": "test" | |
638 | } |
|
638 | } | |
639 |
|
639 | |||
640 | changeset/{revision} shows bookmarks |
|
640 | changeset/{revision} shows bookmarks | |
641 |
|
641 | |||
642 | $ request json-rev/8d7c456572ac |
|
642 | $ request json-rev/8d7c456572ac | |
643 | 200 Script output follows |
|
643 | 200 Script output follows | |
644 |
|
644 | |||
645 | { |
|
645 | { | |
646 | "bookmarks": [ |
|
646 | "bookmarks": [ | |
647 | "bookmark1" |
|
647 | "bookmark1" | |
648 | ], |
|
648 | ], | |
649 | "branch": "default", |
|
649 | "branch": "default", | |
650 | "date": [ |
|
650 | "date": [ | |
651 | 0.0, |
|
651 | 0.0, | |
652 | 0 |
|
652 | 0 | |
653 | ], |
|
653 | ], | |
654 | "desc": "modify da/foo", |
|
654 | "desc": "modify da/foo", | |
655 | "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5", |
|
655 | "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5", | |
656 | "parents": [ |
|
656 | "parents": [ | |
657 | "f8bbb9024b10f93cdbb8d940337398291d40dea8" |
|
657 | "f8bbb9024b10f93cdbb8d940337398291d40dea8" | |
658 | ], |
|
658 | ], | |
659 | "phase": "public", |
|
659 | "phase": "public", | |
660 | "tags": [], |
|
660 | "tags": [], | |
661 | "user": "test" |
|
661 | "user": "test" | |
662 | } |
|
662 | } | |
663 |
|
663 | |||
664 | changeset/{revision} shows branches |
|
664 | changeset/{revision} shows branches | |
665 |
|
665 | |||
666 | $ request json-rev/6ab967a8ab34 |
|
666 | $ request json-rev/6ab967a8ab34 | |
667 | 200 Script output follows |
|
667 | 200 Script output follows | |
668 |
|
668 | |||
669 | { |
|
669 | { | |
670 | "bookmarks": [], |
|
670 | "bookmarks": [], | |
671 | "branch": "test-branch", |
|
671 | "branch": "test-branch", | |
672 | "date": [ |
|
672 | "date": [ | |
673 | 0.0, |
|
673 | 0.0, | |
674 | 0 |
|
674 | 0 | |
675 | ], |
|
675 | ], | |
676 | "desc": "create test branch", |
|
676 | "desc": "create test branch", | |
677 | "node": "6ab967a8ab3489227a83f80e920faa039a71819f", |
|
677 | "node": "6ab967a8ab3489227a83f80e920faa039a71819f", | |
678 | "parents": [ |
|
678 | "parents": [ | |
679 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" |
|
679 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" | |
680 | ], |
|
680 | ], | |
681 | "phase": "draft", |
|
681 | "phase": "draft", | |
682 | "tags": [], |
|
682 | "tags": [], | |
683 | "user": "test" |
|
683 | "user": "test" | |
684 | } |
|
684 | } | |
685 |
|
685 | |||
686 | manifest/{revision}/{path} shows info about a directory at a revision |
|
686 | manifest/{revision}/{path} shows info about a directory at a revision | |
687 |
|
687 | |||
688 | $ request json-manifest/06e557f3edf6/ |
|
688 | $ request json-manifest/06e557f3edf6/ | |
689 | 200 Script output follows |
|
689 | 200 Script output follows | |
690 |
|
690 | |||
691 | { |
|
691 | { | |
692 | "abspath": "/", |
|
692 | "abspath": "/", | |
693 | "bookmarks": [], |
|
693 | "bookmarks": [], | |
694 | "directories": [ |
|
694 | "directories": [ | |
695 | { |
|
695 | { | |
696 | "abspath": "/da", |
|
696 | "abspath": "/da", | |
697 | "basename": "da", |
|
697 | "basename": "da", | |
698 | "emptydirs": "" |
|
698 | "emptydirs": "" | |
699 | } |
|
699 | } | |
700 | ], |
|
700 | ], | |
701 | "files": [ |
|
701 | "files": [ | |
702 | { |
|
702 | { | |
703 | "abspath": "foo", |
|
703 | "abspath": "foo", | |
704 | "basename": "foo", |
|
704 | "basename": "foo", | |
705 | "date": [ |
|
705 | "date": [ | |
706 | 0.0, |
|
706 | 0.0, | |
707 | 0 |
|
707 | 0 | |
708 | ], |
|
708 | ], | |
709 | "flags": "", |
|
709 | "flags": "", | |
710 | "size": 4 |
|
710 | "size": 4 | |
711 | } |
|
711 | } | |
712 | ], |
|
712 | ], | |
713 | "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e", |
|
713 | "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e", | |
714 | "tags": [] |
|
714 | "tags": [] | |
715 | } |
|
715 | } | |
716 |
|
716 | |||
717 | tags/ shows tags info |
|
717 | tags/ shows tags info | |
718 |
|
718 | |||
719 | $ request json-tags |
|
719 | $ request json-tags | |
720 | 200 Script output follows |
|
720 | 200 Script output follows | |
721 |
|
721 | |||
722 | { |
|
722 | { | |
723 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7", |
|
723 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7", | |
724 | "tags": [ |
|
724 | "tags": [ | |
725 | { |
|
725 | { | |
726 | "date": [ |
|
726 | "date": [ | |
727 | 0.0, |
|
727 | 0.0, | |
728 | 0 |
|
728 | 0 | |
729 | ], |
|
729 | ], | |
730 | "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78", |
|
730 | "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78", | |
731 | "tag": "tag2" |
|
731 | "tag": "tag2" | |
732 | }, |
|
732 | }, | |
733 | { |
|
733 | { | |
734 | "date": [ |
|
734 | "date": [ | |
735 | 0.0, |
|
735 | 0.0, | |
736 | 0 |
|
736 | 0 | |
737 | ], |
|
737 | ], | |
738 | "node": "78896eb0e102174ce9278438a95e12543e4367a7", |
|
738 | "node": "78896eb0e102174ce9278438a95e12543e4367a7", | |
739 | "tag": "tag1" |
|
739 | "tag": "tag1" | |
740 | } |
|
740 | } | |
741 | ] |
|
741 | ] | |
742 | } |
|
742 | } | |
743 |
|
743 | |||
744 | bookmarks/ shows bookmarks info |
|
744 | bookmarks/ shows bookmarks info | |
745 |
|
745 | |||
746 | $ request json-bookmarks |
|
746 | $ request json-bookmarks | |
747 | 200 Script output follows |
|
747 | 200 Script output follows | |
748 |
|
748 | |||
749 | { |
|
749 | { | |
750 | "bookmarks": [ |
|
750 | "bookmarks": [ | |
751 | { |
|
751 | { | |
752 | "bookmark": "bookmark2", |
|
752 | "bookmark": "bookmark2", | |
753 | "date": [ |
|
753 | "date": [ | |
754 | 0.0, |
|
754 | 0.0, | |
755 | 0 |
|
755 | 0 | |
756 | ], |
|
756 | ], | |
757 | "node": "ceed296fe500c3fac9541e31dad860cb49c89e45" |
|
757 | "node": "ceed296fe500c3fac9541e31dad860cb49c89e45" | |
758 | }, |
|
758 | }, | |
759 | { |
|
759 | { | |
760 | "bookmark": "bookmark1", |
|
760 | "bookmark": "bookmark1", | |
761 | "date": [ |
|
761 | "date": [ | |
762 | 0.0, |
|
762 | 0.0, | |
763 | 0 |
|
763 | 0 | |
764 | ], |
|
764 | ], | |
765 | "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5" |
|
765 | "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5" | |
766 | } |
|
766 | } | |
767 | ], |
|
767 | ], | |
768 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7" |
|
768 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7" | |
769 | } |
|
769 | } | |
770 |
|
770 | |||
771 | branches/ shows branches info |
|
771 | branches/ shows branches info | |
772 |
|
772 | |||
773 | $ request json-branches |
|
773 | $ request json-branches | |
774 | 200 Script output follows |
|
774 | 200 Script output follows | |
775 |
|
775 | |||
776 | { |
|
776 | { | |
777 | "branches": [ |
|
777 | "branches": [ | |
778 | { |
|
778 | { | |
779 | "branch": "default", |
|
779 | "branch": "default", | |
780 | "date": [ |
|
780 | "date": [ | |
781 | 0.0, |
|
781 | 0.0, | |
782 | 0 |
|
782 | 0 | |
783 | ], |
|
783 | ], | |
784 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7", |
|
784 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7", | |
785 | "status": "open" |
|
785 | "status": "open" | |
786 | }, |
|
786 | }, | |
787 | { |
|
787 | { | |
788 | "branch": "test-branch", |
|
788 | "branch": "test-branch", | |
789 | "date": [ |
|
789 | "date": [ | |
790 | 0.0, |
|
790 | 0.0, | |
791 | 0 |
|
791 | 0 | |
792 | ], |
|
792 | ], | |
793 | "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90", |
|
793 | "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90", | |
794 | "status": "inactive" |
|
794 | "status": "inactive" | |
795 | } |
|
795 | } | |
796 | ] |
|
796 | ] | |
797 | } |
|
797 | } | |
798 |
|
798 | |||
799 | summary/ shows a summary of repository state |
|
799 | summary/ shows a summary of repository state | |
800 |
|
800 | |||
801 | $ request json-summary |
|
801 | $ request json-summary | |
802 | 200 Script output follows |
|
802 | 200 Script output follows | |
803 |
|
803 | |||
804 | { |
|
804 | { | |
805 | "archives": [ |
|
805 | "archives": [ | |
806 | { |
|
806 | { | |
807 | "extension": ".tar.bz2", |
|
807 | "extension": ".tar.bz2", | |
808 | "node": "tip", |
|
808 | "node": "tip", | |
809 | "type": "bz2", |
|
809 | "type": "bz2", | |
810 | "url": "http://*:$HGPORT/archive/tip.tar.bz2" (glob) |
|
810 | "url": "http://*:$HGPORT/archive/tip.tar.bz2" (glob) | |
811 | } |
|
811 | } | |
812 | ], |
|
812 | ], | |
813 | "bookmarks": [ |
|
813 | "bookmarks": [ | |
814 | { |
|
814 | { | |
815 | "bookmark": "bookmark2", |
|
815 | "bookmark": "bookmark2", | |
816 | "date": [ |
|
816 | "date": [ | |
817 | 0.0, |
|
817 | 0.0, | |
818 | 0 |
|
818 | 0 | |
819 | ], |
|
819 | ], | |
820 | "node": "ceed296fe500c3fac9541e31dad860cb49c89e45" |
|
820 | "node": "ceed296fe500c3fac9541e31dad860cb49c89e45" | |
821 | }, |
|
821 | }, | |
822 | { |
|
822 | { | |
823 | "bookmark": "bookmark1", |
|
823 | "bookmark": "bookmark1", | |
824 | "date": [ |
|
824 | "date": [ | |
825 | 0.0, |
|
825 | 0.0, | |
826 | 0 |
|
826 | 0 | |
827 | ], |
|
827 | ], | |
828 | "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5" |
|
828 | "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5" | |
829 | } |
|
829 | } | |
830 | ], |
|
830 | ], | |
831 | "branches": [ |
|
831 | "branches": [ | |
832 | { |
|
832 | { | |
833 | "branch": "default", |
|
833 | "branch": "default", | |
834 | "date": [ |
|
834 | "date": [ | |
835 | 0.0, |
|
835 | 0.0, | |
836 | 0 |
|
836 | 0 | |
837 | ], |
|
837 | ], | |
838 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7", |
|
838 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7", | |
839 | "status": "open" |
|
839 | "status": "open" | |
840 | }, |
|
840 | }, | |
841 | { |
|
841 | { | |
842 | "branch": "test-branch", |
|
842 | "branch": "test-branch", | |
843 | "date": [ |
|
843 | "date": [ | |
844 | 0.0, |
|
844 | 0.0, | |
845 | 0 |
|
845 | 0 | |
846 | ], |
|
846 | ], | |
847 | "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90", |
|
847 | "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90", | |
848 | "status": "inactive" |
|
848 | "status": "inactive" | |
849 | } |
|
849 | } | |
850 | ], |
|
850 | ], | |
|
851 | "labels": [], | |||
851 | "lastchange": [ |
|
852 | "lastchange": [ | |
852 | 0.0, |
|
853 | 0.0, | |
853 | 0 |
|
854 | 0 | |
854 | ], |
|
855 | ], | |
855 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7", |
|
856 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7", | |
856 | "shortlog": [ |
|
857 | "shortlog": [ | |
857 | { |
|
858 | { | |
858 | "bookmarks": [], |
|
859 | "bookmarks": [], | |
859 | "branch": "default", |
|
860 | "branch": "default", | |
860 | "date": [ |
|
861 | "date": [ | |
861 | 0.0, |
|
862 | 0.0, | |
862 | 0 |
|
863 | 0 | |
863 | ], |
|
864 | ], | |
864 | "desc": "merge test-branch into default", |
|
865 | "desc": "merge test-branch into default", | |
865 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7", |
|
866 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7", | |
866 | "parents": [ |
|
867 | "parents": [ | |
867 | "ceed296fe500c3fac9541e31dad860cb49c89e45", |
|
868 | "ceed296fe500c3fac9541e31dad860cb49c89e45", | |
868 | "ed66c30e87eb65337c05a4229efaa5f1d5285a90" |
|
869 | "ed66c30e87eb65337c05a4229efaa5f1d5285a90" | |
869 | ], |
|
870 | ], | |
870 | "phase": "draft", |
|
871 | "phase": "draft", | |
871 | "tags": [ |
|
872 | "tags": [ | |
872 | "tip" |
|
873 | "tip" | |
873 | ], |
|
874 | ], | |
874 | "user": "test" |
|
875 | "user": "test" | |
875 | }, |
|
876 | }, | |
876 | { |
|
877 | { | |
877 | "bookmarks": [], |
|
878 | "bookmarks": [], | |
878 | "branch": "test-branch", |
|
879 | "branch": "test-branch", | |
879 | "date": [ |
|
880 | "date": [ | |
880 | 0.0, |
|
881 | 0.0, | |
881 | 0 |
|
882 | 0 | |
882 | ], |
|
883 | ], | |
883 | "desc": "another commit in test-branch", |
|
884 | "desc": "another commit in test-branch", | |
884 | "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90", |
|
885 | "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90", | |
885 | "parents": [ |
|
886 | "parents": [ | |
886 | "6ab967a8ab3489227a83f80e920faa039a71819f" |
|
887 | "6ab967a8ab3489227a83f80e920faa039a71819f" | |
887 | ], |
|
888 | ], | |
888 | "phase": "draft", |
|
889 | "phase": "draft", | |
889 | "tags": [], |
|
890 | "tags": [], | |
890 | "user": "test" |
|
891 | "user": "test" | |
891 | }, |
|
892 | }, | |
892 | { |
|
893 | { | |
893 | "bookmarks": [], |
|
894 | "bookmarks": [], | |
894 | "branch": "test-branch", |
|
895 | "branch": "test-branch", | |
895 | "date": [ |
|
896 | "date": [ | |
896 | 0.0, |
|
897 | 0.0, | |
897 | 0 |
|
898 | 0 | |
898 | ], |
|
899 | ], | |
899 | "desc": "create test branch", |
|
900 | "desc": "create test branch", | |
900 | "node": "6ab967a8ab3489227a83f80e920faa039a71819f", |
|
901 | "node": "6ab967a8ab3489227a83f80e920faa039a71819f", | |
901 | "parents": [ |
|
902 | "parents": [ | |
902 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" |
|
903 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" | |
903 | ], |
|
904 | ], | |
904 | "phase": "draft", |
|
905 | "phase": "draft", | |
905 | "tags": [], |
|
906 | "tags": [], | |
906 | "user": "test" |
|
907 | "user": "test" | |
907 | }, |
|
908 | }, | |
908 | { |
|
909 | { | |
909 | "bookmarks": [ |
|
910 | "bookmarks": [ | |
910 | "bookmark2" |
|
911 | "bookmark2" | |
911 | ], |
|
912 | ], | |
912 | "branch": "default", |
|
913 | "branch": "default", | |
913 | "date": [ |
|
914 | "date": [ | |
914 | 0.0, |
|
915 | 0.0, | |
915 | 0 |
|
916 | 0 | |
916 | ], |
|
917 | ], | |
917 | "desc": "create tag2", |
|
918 | "desc": "create tag2", | |
918 | "node": "ceed296fe500c3fac9541e31dad860cb49c89e45", |
|
919 | "node": "ceed296fe500c3fac9541e31dad860cb49c89e45", | |
919 | "parents": [ |
|
920 | "parents": [ | |
920 | "f2890a05fea49bfaf9fb27ed5490894eba32da78" |
|
921 | "f2890a05fea49bfaf9fb27ed5490894eba32da78" | |
921 | ], |
|
922 | ], | |
922 | "phase": "draft", |
|
923 | "phase": "draft", | |
923 | "tags": [], |
|
924 | "tags": [], | |
924 | "user": "test" |
|
925 | "user": "test" | |
925 | }, |
|
926 | }, | |
926 | { |
|
927 | { | |
927 | "bookmarks": [], |
|
928 | "bookmarks": [], | |
928 | "branch": "default", |
|
929 | "branch": "default", | |
929 | "date": [ |
|
930 | "date": [ | |
930 | 0.0, |
|
931 | 0.0, | |
931 | 0 |
|
932 | 0 | |
932 | ], |
|
933 | ], | |
933 | "desc": "another commit to da/foo", |
|
934 | "desc": "another commit to da/foo", | |
934 | "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78", |
|
935 | "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78", | |
935 | "parents": [ |
|
936 | "parents": [ | |
936 | "93a8ce14f89156426b7fa981af8042da53f03aa0" |
|
937 | "93a8ce14f89156426b7fa981af8042da53f03aa0" | |
937 | ], |
|
938 | ], | |
938 | "phase": "draft", |
|
939 | "phase": "draft", | |
939 | "tags": [ |
|
940 | "tags": [ | |
940 | "tag2" |
|
941 | "tag2" | |
941 | ], |
|
942 | ], | |
942 | "user": "test" |
|
943 | "user": "test" | |
943 | }, |
|
944 | }, | |
944 | { |
|
945 | { | |
945 | "bookmarks": [], |
|
946 | "bookmarks": [], | |
946 | "branch": "default", |
|
947 | "branch": "default", | |
947 | "date": [ |
|
948 | "date": [ | |
948 | 0.0, |
|
949 | 0.0, | |
949 | 0 |
|
950 | 0 | |
950 | ], |
|
951 | ], | |
951 | "desc": "create tag", |
|
952 | "desc": "create tag", | |
952 | "node": "93a8ce14f89156426b7fa981af8042da53f03aa0", |
|
953 | "node": "93a8ce14f89156426b7fa981af8042da53f03aa0", | |
953 | "parents": [ |
|
954 | "parents": [ | |
954 | "78896eb0e102174ce9278438a95e12543e4367a7" |
|
955 | "78896eb0e102174ce9278438a95e12543e4367a7" | |
955 | ], |
|
956 | ], | |
956 | "phase": "public", |
|
957 | "phase": "public", | |
957 | "tags": [], |
|
958 | "tags": [], | |
958 | "user": "test" |
|
959 | "user": "test" | |
959 | }, |
|
960 | }, | |
960 | { |
|
961 | { | |
961 | "bookmarks": [], |
|
962 | "bookmarks": [], | |
962 | "branch": "default", |
|
963 | "branch": "default", | |
963 | "date": [ |
|
964 | "date": [ | |
964 | 0.0, |
|
965 | 0.0, | |
965 | 0 |
|
966 | 0 | |
966 | ], |
|
967 | ], | |
967 | "desc": "move foo", |
|
968 | "desc": "move foo", | |
968 | "node": "78896eb0e102174ce9278438a95e12543e4367a7", |
|
969 | "node": "78896eb0e102174ce9278438a95e12543e4367a7", | |
969 | "parents": [ |
|
970 | "parents": [ | |
970 | "8d7c456572acf3557e8ed8a07286b10c408bcec5" |
|
971 | "8d7c456572acf3557e8ed8a07286b10c408bcec5" | |
971 | ], |
|
972 | ], | |
972 | "phase": "public", |
|
973 | "phase": "public", | |
973 | "tags": [ |
|
974 | "tags": [ | |
974 | "tag1" |
|
975 | "tag1" | |
975 | ], |
|
976 | ], | |
976 | "user": "test" |
|
977 | "user": "test" | |
977 | }, |
|
978 | }, | |
978 | { |
|
979 | { | |
979 | "bookmarks": [ |
|
980 | "bookmarks": [ | |
980 | "bookmark1" |
|
981 | "bookmark1" | |
981 | ], |
|
982 | ], | |
982 | "branch": "default", |
|
983 | "branch": "default", | |
983 | "date": [ |
|
984 | "date": [ | |
984 | 0.0, |
|
985 | 0.0, | |
985 | 0 |
|
986 | 0 | |
986 | ], |
|
987 | ], | |
987 | "desc": "modify da/foo", |
|
988 | "desc": "modify da/foo", | |
988 | "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5", |
|
989 | "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5", | |
989 | "parents": [ |
|
990 | "parents": [ | |
990 | "f8bbb9024b10f93cdbb8d940337398291d40dea8" |
|
991 | "f8bbb9024b10f93cdbb8d940337398291d40dea8" | |
991 | ], |
|
992 | ], | |
992 | "phase": "public", |
|
993 | "phase": "public", | |
993 | "tags": [], |
|
994 | "tags": [], | |
994 | "user": "test" |
|
995 | "user": "test" | |
995 | }, |
|
996 | }, | |
996 | { |
|
997 | { | |
997 | "bookmarks": [], |
|
998 | "bookmarks": [], | |
998 | "branch": "default", |
|
999 | "branch": "default", | |
999 | "date": [ |
|
1000 | "date": [ | |
1000 | 0.0, |
|
1001 | 0.0, | |
1001 | 0 |
|
1002 | 0 | |
1002 | ], |
|
1003 | ], | |
1003 | "desc": "modify foo", |
|
1004 | "desc": "modify foo", | |
1004 | "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8", |
|
1005 | "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8", | |
1005 | "parents": [ |
|
1006 | "parents": [ | |
1006 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" |
|
1007 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" | |
1007 | ], |
|
1008 | ], | |
1008 | "phase": "public", |
|
1009 | "phase": "public", | |
1009 | "tags": [], |
|
1010 | "tags": [], | |
1010 | "user": "test" |
|
1011 | "user": "test" | |
1011 | }, |
|
1012 | }, | |
1012 | { |
|
1013 | { | |
1013 | "bookmarks": [], |
|
1014 | "bookmarks": [], | |
1014 | "branch": "default", |
|
1015 | "branch": "default", | |
1015 | "date": [ |
|
1016 | "date": [ | |
1016 | 0.0, |
|
1017 | 0.0, | |
1017 | 0 |
|
1018 | 0 | |
1018 | ], |
|
1019 | ], | |
1019 | "desc": "initial", |
|
1020 | "desc": "initial", | |
1020 | "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e", |
|
1021 | "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e", | |
1021 | "parents": [], |
|
1022 | "parents": [], | |
1022 | "phase": "public", |
|
1023 | "phase": "public", | |
1023 | "tags": [], |
|
1024 | "tags": [], | |
1024 | "user": "test" |
|
1025 | "user": "test" | |
1025 | } |
|
1026 | } | |
1026 | ], |
|
1027 | ], | |
1027 | "tags": [ |
|
1028 | "tags": [ | |
1028 | { |
|
1029 | { | |
1029 | "date": [ |
|
1030 | "date": [ | |
1030 | 0.0, |
|
1031 | 0.0, | |
1031 | 0 |
|
1032 | 0 | |
1032 | ], |
|
1033 | ], | |
1033 | "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78", |
|
1034 | "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78", | |
1034 | "tag": "tag2" |
|
1035 | "tag": "tag2" | |
1035 | }, |
|
1036 | }, | |
1036 | { |
|
1037 | { | |
1037 | "date": [ |
|
1038 | "date": [ | |
1038 | 0.0, |
|
1039 | 0.0, | |
1039 | 0 |
|
1040 | 0 | |
1040 | ], |
|
1041 | ], | |
1041 | "node": "78896eb0e102174ce9278438a95e12543e4367a7", |
|
1042 | "node": "78896eb0e102174ce9278438a95e12543e4367a7", | |
1042 | "tag": "tag1" |
|
1043 | "tag": "tag1" | |
1043 | } |
|
1044 | } | |
1044 | ] |
|
1045 | ] | |
1045 | } |
|
1046 | } | |
1046 |
|
1047 | |||
1047 | $ request json-changelog?rev=create |
|
1048 | $ request json-changelog?rev=create | |
1048 | 200 Script output follows |
|
1049 | 200 Script output follows | |
1049 |
|
1050 | |||
1050 | { |
|
1051 | { | |
1051 | "entries": [ |
|
1052 | "entries": [ | |
1052 | { |
|
1053 | { | |
1053 | "bookmarks": [], |
|
1054 | "bookmarks": [], | |
1054 | "branch": "test-branch", |
|
1055 | "branch": "test-branch", | |
1055 | "date": [ |
|
1056 | "date": [ | |
1056 | 0.0, |
|
1057 | 0.0, | |
1057 | 0 |
|
1058 | 0 | |
1058 | ], |
|
1059 | ], | |
1059 | "desc": "create test branch", |
|
1060 | "desc": "create test branch", | |
1060 | "node": "6ab967a8ab3489227a83f80e920faa039a71819f", |
|
1061 | "node": "6ab967a8ab3489227a83f80e920faa039a71819f", | |
1061 | "parents": [ |
|
1062 | "parents": [ | |
1062 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" |
|
1063 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" | |
1063 | ], |
|
1064 | ], | |
1064 | "phase": "draft", |
|
1065 | "phase": "draft", | |
1065 | "tags": [], |
|
1066 | "tags": [], | |
1066 | "user": "test" |
|
1067 | "user": "test" | |
1067 | }, |
|
1068 | }, | |
1068 | { |
|
1069 | { | |
1069 | "bookmarks": [ |
|
1070 | "bookmarks": [ | |
1070 | "bookmark2" |
|
1071 | "bookmark2" | |
1071 | ], |
|
1072 | ], | |
1072 | "branch": "default", |
|
1073 | "branch": "default", | |
1073 | "date": [ |
|
1074 | "date": [ | |
1074 | 0.0, |
|
1075 | 0.0, | |
1075 | 0 |
|
1076 | 0 | |
1076 | ], |
|
1077 | ], | |
1077 | "desc": "create tag2", |
|
1078 | "desc": "create tag2", | |
1078 | "node": "ceed296fe500c3fac9541e31dad860cb49c89e45", |
|
1079 | "node": "ceed296fe500c3fac9541e31dad860cb49c89e45", | |
1079 | "parents": [ |
|
1080 | "parents": [ | |
1080 | "f2890a05fea49bfaf9fb27ed5490894eba32da78" |
|
1081 | "f2890a05fea49bfaf9fb27ed5490894eba32da78" | |
1081 | ], |
|
1082 | ], | |
1082 | "phase": "draft", |
|
1083 | "phase": "draft", | |
1083 | "tags": [], |
|
1084 | "tags": [], | |
1084 | "user": "test" |
|
1085 | "user": "test" | |
1085 | }, |
|
1086 | }, | |
1086 | { |
|
1087 | { | |
1087 | "bookmarks": [], |
|
1088 | "bookmarks": [], | |
1088 | "branch": "default", |
|
1089 | "branch": "default", | |
1089 | "date": [ |
|
1090 | "date": [ | |
1090 | 0.0, |
|
1091 | 0.0, | |
1091 | 0 |
|
1092 | 0 | |
1092 | ], |
|
1093 | ], | |
1093 | "desc": "create tag", |
|
1094 | "desc": "create tag", | |
1094 | "node": "93a8ce14f89156426b7fa981af8042da53f03aa0", |
|
1095 | "node": "93a8ce14f89156426b7fa981af8042da53f03aa0", | |
1095 | "parents": [ |
|
1096 | "parents": [ | |
1096 | "78896eb0e102174ce9278438a95e12543e4367a7" |
|
1097 | "78896eb0e102174ce9278438a95e12543e4367a7" | |
1097 | ], |
|
1098 | ], | |
1098 | "phase": "public", |
|
1099 | "phase": "public", | |
1099 | "tags": [], |
|
1100 | "tags": [], | |
1100 | "user": "test" |
|
1101 | "user": "test" | |
1101 | } |
|
1102 | } | |
1102 | ], |
|
1103 | ], | |
1103 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7", |
|
1104 | "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7", | |
1104 | "query": "create" |
|
1105 | "query": "create" | |
1105 | } |
|
1106 | } | |
1106 |
|
1107 | |||
1107 | filediff/{revision}/{path} shows changes to a file in a revision |
|
1108 | filediff/{revision}/{path} shows changes to a file in a revision | |
1108 |
|
1109 | |||
1109 | $ request json-diff/f8bbb9024b10/foo |
|
1110 | $ request json-diff/f8bbb9024b10/foo | |
1110 | 200 Script output follows |
|
1111 | 200 Script output follows | |
1111 |
|
1112 | |||
1112 | { |
|
1113 | { | |
1113 | "author": "test", |
|
1114 | "author": "test", | |
1114 | "children": [], |
|
1115 | "children": [], | |
1115 | "date": [ |
|
1116 | "date": [ | |
1116 | 0.0, |
|
1117 | 0.0, | |
1117 | 0 |
|
1118 | 0 | |
1118 | ], |
|
1119 | ], | |
1119 | "desc": "modify foo", |
|
1120 | "desc": "modify foo", | |
1120 | "diff": [ |
|
1121 | "diff": [ | |
1121 | { |
|
1122 | { | |
1122 | "blockno": 1, |
|
1123 | "blockno": 1, | |
1123 | "lines": [ |
|
1124 | "lines": [ | |
1124 | { |
|
1125 | { | |
1125 | "l": "--- a/foo\tThu Jan 01 00:00:00 1970 +0000\n", |
|
1126 | "l": "--- a/foo\tThu Jan 01 00:00:00 1970 +0000\n", | |
1126 | "n": 1, |
|
1127 | "n": 1, | |
1127 | "t": "-" |
|
1128 | "t": "-" | |
1128 | }, |
|
1129 | }, | |
1129 | { |
|
1130 | { | |
1130 | "l": "+++ b/foo\tThu Jan 01 00:00:00 1970 +0000\n", |
|
1131 | "l": "+++ b/foo\tThu Jan 01 00:00:00 1970 +0000\n", | |
1131 | "n": 2, |
|
1132 | "n": 2, | |
1132 | "t": "+" |
|
1133 | "t": "+" | |
1133 | }, |
|
1134 | }, | |
1134 | { |
|
1135 | { | |
1135 | "l": "@@ -1,1 +1,1 @@\n", |
|
1136 | "l": "@@ -1,1 +1,1 @@\n", | |
1136 | "n": 3, |
|
1137 | "n": 3, | |
1137 | "t": "@" |
|
1138 | "t": "@" | |
1138 | }, |
|
1139 | }, | |
1139 | { |
|
1140 | { | |
1140 | "l": "-foo\n", |
|
1141 | "l": "-foo\n", | |
1141 | "n": 4, |
|
1142 | "n": 4, | |
1142 | "t": "-" |
|
1143 | "t": "-" | |
1143 | }, |
|
1144 | }, | |
1144 | { |
|
1145 | { | |
1145 | "l": "+bar\n", |
|
1146 | "l": "+bar\n", | |
1146 | "n": 5, |
|
1147 | "n": 5, | |
1147 | "t": "+" |
|
1148 | "t": "+" | |
1148 | } |
|
1149 | } | |
1149 | ] |
|
1150 | ] | |
1150 | } |
|
1151 | } | |
1151 | ], |
|
1152 | ], | |
1152 | "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8", |
|
1153 | "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8", | |
1153 | "parents": [ |
|
1154 | "parents": [ | |
1154 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" |
|
1155 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" | |
1155 | ], |
|
1156 | ], | |
1156 | "path": "foo" |
|
1157 | "path": "foo" | |
1157 | } |
|
1158 | } | |
1158 |
|
1159 | |||
1159 | comparison/{revision}/{path} shows information about before and after for a file |
|
1160 | comparison/{revision}/{path} shows information about before and after for a file | |
1160 |
|
1161 | |||
1161 | $ request json-comparison/f8bbb9024b10/foo |
|
1162 | $ request json-comparison/f8bbb9024b10/foo | |
1162 | 200 Script output follows |
|
1163 | 200 Script output follows | |
1163 |
|
1164 | |||
1164 | { |
|
1165 | { | |
1165 | "author": "test", |
|
1166 | "author": "test", | |
1166 | "children": [], |
|
1167 | "children": [], | |
1167 | "comparison": [ |
|
1168 | "comparison": [ | |
1168 | { |
|
1169 | { | |
1169 | "lines": [ |
|
1170 | "lines": [ | |
1170 | { |
|
1171 | { | |
1171 | "ll": "foo", |
|
1172 | "ll": "foo", | |
1172 | "ln": 1, |
|
1173 | "ln": 1, | |
1173 | "rl": "bar", |
|
1174 | "rl": "bar", | |
1174 | "rn": 1, |
|
1175 | "rn": 1, | |
1175 | "t": "replace" |
|
1176 | "t": "replace" | |
1176 | } |
|
1177 | } | |
1177 | ] |
|
1178 | ] | |
1178 | } |
|
1179 | } | |
1179 | ], |
|
1180 | ], | |
1180 | "date": [ |
|
1181 | "date": [ | |
1181 | 0.0, |
|
1182 | 0.0, | |
1182 | 0 |
|
1183 | 0 | |
1183 | ], |
|
1184 | ], | |
1184 | "desc": "modify foo", |
|
1185 | "desc": "modify foo", | |
1185 | "leftnode": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e", |
|
1186 | "leftnode": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e", | |
1186 | "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8", |
|
1187 | "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8", | |
1187 | "parents": [ |
|
1188 | "parents": [ | |
1188 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" |
|
1189 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" | |
1189 | ], |
|
1190 | ], | |
1190 | "path": "foo", |
|
1191 | "path": "foo", | |
1191 | "rightnode": "f8bbb9024b10f93cdbb8d940337398291d40dea8" |
|
1192 | "rightnode": "f8bbb9024b10f93cdbb8d940337398291d40dea8" | |
1192 | } |
|
1193 | } | |
1193 |
|
1194 | |||
1194 | annotate/{revision}/{path} shows annotations for each line |
|
1195 | annotate/{revision}/{path} shows annotations for each line | |
1195 |
|
1196 | |||
1196 | $ request json-annotate/f8bbb9024b10/foo |
|
1197 | $ request json-annotate/f8bbb9024b10/foo | |
1197 | 200 Script output follows |
|
1198 | 200 Script output follows | |
1198 |
|
1199 | |||
1199 | { |
|
1200 | { | |
1200 | "abspath": "foo", |
|
1201 | "abspath": "foo", | |
1201 | "annotate": [ |
|
1202 | "annotate": [ | |
1202 | { |
|
1203 | { | |
1203 | "abspath": "foo", |
|
1204 | "abspath": "foo", | |
1204 | "author": "test", |
|
1205 | "author": "test", | |
1205 | "desc": "modify foo", |
|
1206 | "desc": "modify foo", | |
1206 | "line": "bar\n", |
|
1207 | "line": "bar\n", | |
1207 | "lineno": 1, |
|
1208 | "lineno": 1, | |
1208 | "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8", |
|
1209 | "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8", | |
1209 | "revdate": [ |
|
1210 | "revdate": [ | |
1210 | 0.0, |
|
1211 | 0.0, | |
1211 | 0 |
|
1212 | 0 | |
1212 | ], |
|
1213 | ], | |
1213 | "targetline": 1 |
|
1214 | "targetline": 1 | |
1214 | } |
|
1215 | } | |
1215 | ], |
|
1216 | ], | |
1216 | "author": "test", |
|
1217 | "author": "test", | |
1217 | "children": [], |
|
1218 | "children": [], | |
1218 | "date": [ |
|
1219 | "date": [ | |
1219 | 0.0, |
|
1220 | 0.0, | |
1220 | 0 |
|
1221 | 0 | |
1221 | ], |
|
1222 | ], | |
1222 | "desc": "modify foo", |
|
1223 | "desc": "modify foo", | |
1223 | "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8", |
|
1224 | "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8", | |
1224 | "parents": [ |
|
1225 | "parents": [ | |
1225 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" |
|
1226 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" | |
1226 | ], |
|
1227 | ], | |
1227 | "permissions": "" |
|
1228 | "permissions": "" | |
1228 | } |
|
1229 | } | |
1229 |
|
1230 | |||
1230 | filelog/{revision}/{path} shows history of a single file |
|
1231 | filelog/{revision}/{path} shows history of a single file | |
1231 |
|
1232 | |||
1232 | $ request json-filelog/f8bbb9024b10/foo |
|
1233 | $ request json-filelog/f8bbb9024b10/foo | |
1233 | 200 Script output follows |
|
1234 | 200 Script output follows | |
1234 |
|
1235 | |||
1235 | { |
|
1236 | { | |
1236 | "entries": [ |
|
1237 | "entries": [ | |
1237 | { |
|
1238 | { | |
1238 | "bookmarks": [], |
|
1239 | "bookmarks": [], | |
1239 | "branch": "default", |
|
1240 | "branch": "default", | |
1240 | "date": [ |
|
1241 | "date": [ | |
1241 | 0.0, |
|
1242 | 0.0, | |
1242 | 0 |
|
1243 | 0 | |
1243 | ], |
|
1244 | ], | |
1244 | "desc": "modify foo", |
|
1245 | "desc": "modify foo", | |
1245 | "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8", |
|
1246 | "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8", | |
1246 | "parents": [ |
|
1247 | "parents": [ | |
1247 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" |
|
1248 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" | |
1248 | ], |
|
1249 | ], | |
1249 | "phase": "public", |
|
1250 | "phase": "public", | |
1250 | "tags": [], |
|
1251 | "tags": [], | |
1251 | "user": "test" |
|
1252 | "user": "test" | |
1252 | }, |
|
1253 | }, | |
1253 | { |
|
1254 | { | |
1254 | "bookmarks": [], |
|
1255 | "bookmarks": [], | |
1255 | "branch": "default", |
|
1256 | "branch": "default", | |
1256 | "date": [ |
|
1257 | "date": [ | |
1257 | 0.0, |
|
1258 | 0.0, | |
1258 | 0 |
|
1259 | 0 | |
1259 | ], |
|
1260 | ], | |
1260 | "desc": "initial", |
|
1261 | "desc": "initial", | |
1261 | "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e", |
|
1262 | "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e", | |
1262 | "parents": [], |
|
1263 | "parents": [], | |
1263 | "phase": "public", |
|
1264 | "phase": "public", | |
1264 | "tags": [], |
|
1265 | "tags": [], | |
1265 | "user": "test" |
|
1266 | "user": "test" | |
1266 | } |
|
1267 | } | |
1267 | ] |
|
1268 | ] | |
1268 | } |
|
1269 | } | |
1269 |
|
1270 | |||
1270 | $ request json-filelog/cc725e08502a/da/foo |
|
1271 | $ request json-filelog/cc725e08502a/da/foo | |
1271 | 200 Script output follows |
|
1272 | 200 Script output follows | |
1272 |
|
1273 | |||
1273 | { |
|
1274 | { | |
1274 | "entries": [ |
|
1275 | "entries": [ | |
1275 | { |
|
1276 | { | |
1276 | "bookmarks": [], |
|
1277 | "bookmarks": [], | |
1277 | "branch": "default", |
|
1278 | "branch": "default", | |
1278 | "date": [ |
|
1279 | "date": [ | |
1279 | 0.0, |
|
1280 | 0.0, | |
1280 | 0 |
|
1281 | 0 | |
1281 | ], |
|
1282 | ], | |
1282 | "desc": "another commit to da/foo", |
|
1283 | "desc": "another commit to da/foo", | |
1283 | "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78", |
|
1284 | "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78", | |
1284 | "parents": [ |
|
1285 | "parents": [ | |
1285 | "8d7c456572acf3557e8ed8a07286b10c408bcec5" |
|
1286 | "8d7c456572acf3557e8ed8a07286b10c408bcec5" | |
1286 | ], |
|
1287 | ], | |
1287 | "phase": "draft", |
|
1288 | "phase": "draft", | |
1288 | "tags": [ |
|
1289 | "tags": [ | |
1289 | "tag2" |
|
1290 | "tag2" | |
1290 | ], |
|
1291 | ], | |
1291 | "user": "test" |
|
1292 | "user": "test" | |
1292 | }, |
|
1293 | }, | |
1293 | { |
|
1294 | { | |
1294 | "bookmarks": [ |
|
1295 | "bookmarks": [ | |
1295 | "bookmark1" |
|
1296 | "bookmark1" | |
1296 | ], |
|
1297 | ], | |
1297 | "branch": "default", |
|
1298 | "branch": "default", | |
1298 | "date": [ |
|
1299 | "date": [ | |
1299 | 0.0, |
|
1300 | 0.0, | |
1300 | 0 |
|
1301 | 0 | |
1301 | ], |
|
1302 | ], | |
1302 | "desc": "modify da/foo", |
|
1303 | "desc": "modify da/foo", | |
1303 | "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5", |
|
1304 | "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5", | |
1304 | "parents": [ |
|
1305 | "parents": [ | |
1305 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" |
|
1306 | "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e" | |
1306 | ], |
|
1307 | ], | |
1307 | "phase": "public", |
|
1308 | "phase": "public", | |
1308 | "tags": [], |
|
1309 | "tags": [], | |
1309 | "user": "test" |
|
1310 | "user": "test" | |
1310 | }, |
|
1311 | }, | |
1311 | { |
|
1312 | { | |
1312 | "bookmarks": [], |
|
1313 | "bookmarks": [], | |
1313 | "branch": "default", |
|
1314 | "branch": "default", | |
1314 | "date": [ |
|
1315 | "date": [ | |
1315 | 0.0, |
|
1316 | 0.0, | |
1316 | 0 |
|
1317 | 0 | |
1317 | ], |
|
1318 | ], | |
1318 | "desc": "initial", |
|
1319 | "desc": "initial", | |
1319 | "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e", |
|
1320 | "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e", | |
1320 | "parents": [], |
|
1321 | "parents": [], | |
1321 | "phase": "public", |
|
1322 | "phase": "public", | |
1322 | "tags": [], |
|
1323 | "tags": [], | |
1323 | "user": "test" |
|
1324 | "user": "test" | |
1324 | } |
|
1325 | } | |
1325 | ] |
|
1326 | ] | |
1326 | } |
|
1327 | } | |
1327 |
|
1328 | |||
1328 | (archive/ doesn't use templating, so ignore it) |
|
1329 | (archive/ doesn't use templating, so ignore it) | |
1329 |
|
1330 | |||
1330 | (static/ doesn't use templating, so ignore it) |
|
1331 | (static/ doesn't use templating, so ignore it) | |
1331 |
|
1332 | |||
1332 | graph/ shows information that can be used to render a graph of the DAG |
|
1333 | graph/ shows information that can be used to render a graph of the DAG | |
1333 |
|
1334 | |||
1334 | $ request json-graph |
|
1335 | $ request json-graph | |
1335 | 200 Script output follows |
|
1336 | 200 Script output follows | |
1336 |
|
1337 | |||
1337 | "not yet implemented" |
|
1338 | "not yet implemented" | |
1338 |
|
1339 | |||
1339 | help/ shows help topics |
|
1340 | help/ shows help topics | |
1340 |
|
1341 | |||
1341 | $ request json-help |
|
1342 | $ request json-help | |
1342 | 200 Script output follows |
|
1343 | 200 Script output follows | |
1343 |
|
1344 | |||
1344 | { |
|
1345 | { | |
1345 | "earlycommands": [ |
|
1346 | "earlycommands": [ | |
1346 | { |
|
1347 | { | |
1347 | "summary": "add the specified files on the next commit", |
|
1348 | "summary": "add the specified files on the next commit", | |
1348 | "topic": "add" |
|
1349 | "topic": "add" | |
1349 | }, |
|
1350 | }, | |
1350 | { |
|
1351 | { | |
1351 | "summary": "show changeset information by line for each file", |
|
1352 | "summary": "show changeset information by line for each file", | |
1352 | "topic": "annotate" |
|
1353 | "topic": "annotate" | |
1353 | }, |
|
1354 | }, | |
1354 | { |
|
1355 | { | |
1355 | "summary": "make a copy of an existing repository", |
|
1356 | "summary": "make a copy of an existing repository", | |
1356 | "topic": "clone" |
|
1357 | "topic": "clone" | |
1357 | }, |
|
1358 | }, | |
1358 | { |
|
1359 | { | |
1359 | "summary": "commit the specified files or all outstanding changes", |
|
1360 | "summary": "commit the specified files or all outstanding changes", | |
1360 | "topic": "commit" |
|
1361 | "topic": "commit" | |
1361 | }, |
|
1362 | }, | |
1362 | { |
|
1363 | { | |
1363 | "summary": "diff repository (or selected files)", |
|
1364 | "summary": "diff repository (or selected files)", | |
1364 | "topic": "diff" |
|
1365 | "topic": "diff" | |
1365 | }, |
|
1366 | }, | |
1366 | { |
|
1367 | { | |
1367 | "summary": "dump the header and diffs for one or more changesets", |
|
1368 | "summary": "dump the header and diffs for one or more changesets", | |
1368 | "topic": "export" |
|
1369 | "topic": "export" | |
1369 | }, |
|
1370 | }, | |
1370 | { |
|
1371 | { | |
1371 | "summary": "forget the specified files on the next commit", |
|
1372 | "summary": "forget the specified files on the next commit", | |
1372 | "topic": "forget" |
|
1373 | "topic": "forget" | |
1373 | }, |
|
1374 | }, | |
1374 | { |
|
1375 | { | |
1375 | "summary": "create a new repository in the given directory", |
|
1376 | "summary": "create a new repository in the given directory", | |
1376 | "topic": "init" |
|
1377 | "topic": "init" | |
1377 | }, |
|
1378 | }, | |
1378 | { |
|
1379 | { | |
1379 | "summary": "show revision history of entire repository or files", |
|
1380 | "summary": "show revision history of entire repository or files", | |
1380 | "topic": "log" |
|
1381 | "topic": "log" | |
1381 | }, |
|
1382 | }, | |
1382 | { |
|
1383 | { | |
1383 | "summary": "merge another revision into working directory", |
|
1384 | "summary": "merge another revision into working directory", | |
1384 | "topic": "merge" |
|
1385 | "topic": "merge" | |
1385 | }, |
|
1386 | }, | |
1386 | { |
|
1387 | { | |
1387 | "summary": "pull changes from the specified source", |
|
1388 | "summary": "pull changes from the specified source", | |
1388 | "topic": "pull" |
|
1389 | "topic": "pull" | |
1389 | }, |
|
1390 | }, | |
1390 | { |
|
1391 | { | |
1391 | "summary": "push changes to the specified destination", |
|
1392 | "summary": "push changes to the specified destination", | |
1392 | "topic": "push" |
|
1393 | "topic": "push" | |
1393 | }, |
|
1394 | }, | |
1394 | { |
|
1395 | { | |
1395 | "summary": "remove the specified files on the next commit", |
|
1396 | "summary": "remove the specified files on the next commit", | |
1396 | "topic": "remove" |
|
1397 | "topic": "remove" | |
1397 | }, |
|
1398 | }, | |
1398 | { |
|
1399 | { | |
1399 | "summary": "start stand-alone webserver", |
|
1400 | "summary": "start stand-alone webserver", | |
1400 | "topic": "serve" |
|
1401 | "topic": "serve" | |
1401 | }, |
|
1402 | }, | |
1402 | { |
|
1403 | { | |
1403 | "summary": "show changed files in the working directory", |
|
1404 | "summary": "show changed files in the working directory", | |
1404 | "topic": "status" |
|
1405 | "topic": "status" | |
1405 | }, |
|
1406 | }, | |
1406 | { |
|
1407 | { | |
1407 | "summary": "summarize working directory state", |
|
1408 | "summary": "summarize working directory state", | |
1408 | "topic": "summary" |
|
1409 | "topic": "summary" | |
1409 | }, |
|
1410 | }, | |
1410 | { |
|
1411 | { | |
1411 | "summary": "update working directory (or switch revisions)", |
|
1412 | "summary": "update working directory (or switch revisions)", | |
1412 | "topic": "update" |
|
1413 | "topic": "update" | |
1413 | } |
|
1414 | } | |
1414 | ], |
|
1415 | ], | |
1415 | "othercommands": [ |
|
1416 | "othercommands": [ | |
1416 | { |
|
1417 | { | |
1417 | "summary": "add all new files, delete all missing files", |
|
1418 | "summary": "add all new files, delete all missing files", | |
1418 | "topic": "addremove" |
|
1419 | "topic": "addremove" | |
1419 | }, |
|
1420 | }, | |
1420 | { |
|
1421 | { | |
1421 | "summary": "create an unversioned archive of a repository revision", |
|
1422 | "summary": "create an unversioned archive of a repository revision", | |
1422 | "topic": "archive" |
|
1423 | "topic": "archive" | |
1423 | }, |
|
1424 | }, | |
1424 | { |
|
1425 | { | |
1425 | "summary": "reverse effect of earlier changeset", |
|
1426 | "summary": "reverse effect of earlier changeset", | |
1426 | "topic": "backout" |
|
1427 | "topic": "backout" | |
1427 | }, |
|
1428 | }, | |
1428 | { |
|
1429 | { | |
1429 | "summary": "subdivision search of changesets", |
|
1430 | "summary": "subdivision search of changesets", | |
1430 | "topic": "bisect" |
|
1431 | "topic": "bisect" | |
1431 | }, |
|
1432 | }, | |
1432 | { |
|
1433 | { | |
1433 | "summary": "create a new bookmark or list existing bookmarks", |
|
1434 | "summary": "create a new bookmark or list existing bookmarks", | |
1434 | "topic": "bookmarks" |
|
1435 | "topic": "bookmarks" | |
1435 | }, |
|
1436 | }, | |
1436 | { |
|
1437 | { | |
1437 | "summary": "set or show the current branch name", |
|
1438 | "summary": "set or show the current branch name", | |
1438 | "topic": "branch" |
|
1439 | "topic": "branch" | |
1439 | }, |
|
1440 | }, | |
1440 | { |
|
1441 | { | |
1441 | "summary": "list repository named branches", |
|
1442 | "summary": "list repository named branches", | |
1442 | "topic": "branches" |
|
1443 | "topic": "branches" | |
1443 | }, |
|
1444 | }, | |
1444 | { |
|
1445 | { | |
1445 | "summary": "create a changegroup file", |
|
1446 | "summary": "create a changegroup file", | |
1446 | "topic": "bundle" |
|
1447 | "topic": "bundle" | |
1447 | }, |
|
1448 | }, | |
1448 | { |
|
1449 | { | |
1449 | "summary": "output the current or given revision of files", |
|
1450 | "summary": "output the current or given revision of files", | |
1450 | "topic": "cat" |
|
1451 | "topic": "cat" | |
1451 | }, |
|
1452 | }, | |
1452 | { |
|
1453 | { | |
1453 | "summary": "show combined config settings from all hgrc files", |
|
1454 | "summary": "show combined config settings from all hgrc files", | |
1454 | "topic": "config" |
|
1455 | "topic": "config" | |
1455 | }, |
|
1456 | }, | |
1456 | { |
|
1457 | { | |
1457 | "summary": "mark files as copied for the next commit", |
|
1458 | "summary": "mark files as copied for the next commit", | |
1458 | "topic": "copy" |
|
1459 | "topic": "copy" | |
1459 | }, |
|
1460 | }, | |
1460 | { |
|
1461 | { | |
1461 | "summary": "list tracked files", |
|
1462 | "summary": "list tracked files", | |
1462 | "topic": "files" |
|
1463 | "topic": "files" | |
1463 | }, |
|
1464 | }, | |
1464 | { |
|
1465 | { | |
1465 | "summary": "copy changes from other branches onto the current branch", |
|
1466 | "summary": "copy changes from other branches onto the current branch", | |
1466 | "topic": "graft" |
|
1467 | "topic": "graft" | |
1467 | }, |
|
1468 | }, | |
1468 | { |
|
1469 | { | |
1469 | "summary": "search for a pattern in specified files and revisions", |
|
1470 | "summary": "search for a pattern in specified files and revisions", | |
1470 | "topic": "grep" |
|
1471 | "topic": "grep" | |
1471 | }, |
|
1472 | }, | |
1472 | { |
|
1473 | { | |
1473 | "summary": "show branch heads", |
|
1474 | "summary": "show branch heads", | |
1474 | "topic": "heads" |
|
1475 | "topic": "heads" | |
1475 | }, |
|
1476 | }, | |
1476 | { |
|
1477 | { | |
1477 | "summary": "show help for a given topic or a help overview", |
|
1478 | "summary": "show help for a given topic or a help overview", | |
1478 | "topic": "help" |
|
1479 | "topic": "help" | |
1479 | }, |
|
1480 | }, | |
1480 | { |
|
1481 | { | |
1481 | "summary": "identify the working directory or specified revision", |
|
1482 | "summary": "identify the working directory or specified revision", | |
1482 | "topic": "identify" |
|
1483 | "topic": "identify" | |
1483 | }, |
|
1484 | }, | |
1484 | { |
|
1485 | { | |
1485 | "summary": "import an ordered set of patches", |
|
1486 | "summary": "import an ordered set of patches", | |
1486 | "topic": "import" |
|
1487 | "topic": "import" | |
1487 | }, |
|
1488 | }, | |
1488 | { |
|
1489 | { | |
1489 | "summary": "show new changesets found in source", |
|
1490 | "summary": "show new changesets found in source", | |
1490 | "topic": "incoming" |
|
1491 | "topic": "incoming" | |
1491 | }, |
|
1492 | }, | |
1492 | { |
|
1493 | { | |
1493 | "summary": "output the current or given revision of the project manifest", |
|
1494 | "summary": "output the current or given revision of the project manifest", | |
1494 | "topic": "manifest" |
|
1495 | "topic": "manifest" | |
1495 | }, |
|
1496 | }, | |
1496 | { |
|
1497 | { | |
1497 | "summary": "show changesets not found in the destination", |
|
1498 | "summary": "show changesets not found in the destination", | |
1498 | "topic": "outgoing" |
|
1499 | "topic": "outgoing" | |
1499 | }, |
|
1500 | }, | |
1500 | { |
|
1501 | { | |
1501 | "summary": "show aliases for remote repositories", |
|
1502 | "summary": "show aliases for remote repositories", | |
1502 | "topic": "paths" |
|
1503 | "topic": "paths" | |
1503 | }, |
|
1504 | }, | |
1504 | { |
|
1505 | { | |
1505 | "summary": "set or show the current phase name", |
|
1506 | "summary": "set or show the current phase name", | |
1506 | "topic": "phase" |
|
1507 | "topic": "phase" | |
1507 | }, |
|
1508 | }, | |
1508 | { |
|
1509 | { | |
1509 | "summary": "roll back an interrupted transaction", |
|
1510 | "summary": "roll back an interrupted transaction", | |
1510 | "topic": "recover" |
|
1511 | "topic": "recover" | |
1511 | }, |
|
1512 | }, | |
1512 | { |
|
1513 | { | |
1513 | "summary": "rename files; equivalent of copy + remove", |
|
1514 | "summary": "rename files; equivalent of copy + remove", | |
1514 | "topic": "rename" |
|
1515 | "topic": "rename" | |
1515 | }, |
|
1516 | }, | |
1516 | { |
|
1517 | { | |
1517 | "summary": "redo merges or set/view the merge status of files", |
|
1518 | "summary": "redo merges or set/view the merge status of files", | |
1518 | "topic": "resolve" |
|
1519 | "topic": "resolve" | |
1519 | }, |
|
1520 | }, | |
1520 | { |
|
1521 | { | |
1521 | "summary": "restore files to their checkout state", |
|
1522 | "summary": "restore files to their checkout state", | |
1522 | "topic": "revert" |
|
1523 | "topic": "revert" | |
1523 | }, |
|
1524 | }, | |
1524 | { |
|
1525 | { | |
1525 | "summary": "print the root (top) of the current working directory", |
|
1526 | "summary": "print the root (top) of the current working directory", | |
1526 | "topic": "root" |
|
1527 | "topic": "root" | |
1527 | }, |
|
1528 | }, | |
1528 | { |
|
1529 | { | |
1529 | "summary": "add one or more tags for the current or given revision", |
|
1530 | "summary": "add one or more tags for the current or given revision", | |
1530 | "topic": "tag" |
|
1531 | "topic": "tag" | |
1531 | }, |
|
1532 | }, | |
1532 | { |
|
1533 | { | |
1533 | "summary": "list repository tags", |
|
1534 | "summary": "list repository tags", | |
1534 | "topic": "tags" |
|
1535 | "topic": "tags" | |
1535 | }, |
|
1536 | }, | |
1536 | { |
|
1537 | { | |
1537 | "summary": "apply one or more changegroup files", |
|
1538 | "summary": "apply one or more changegroup files", | |
1538 | "topic": "unbundle" |
|
1539 | "topic": "unbundle" | |
1539 | }, |
|
1540 | }, | |
1540 | { |
|
1541 | { | |
1541 | "summary": "verify the integrity of the repository", |
|
1542 | "summary": "verify the integrity of the repository", | |
1542 | "topic": "verify" |
|
1543 | "topic": "verify" | |
1543 | }, |
|
1544 | }, | |
1544 | { |
|
1545 | { | |
1545 | "summary": "output version and copyright information", |
|
1546 | "summary": "output version and copyright information", | |
1546 | "topic": "version" |
|
1547 | "topic": "version" | |
1547 | } |
|
1548 | } | |
1548 | ], |
|
1549 | ], | |
1549 | "topics": [ |
|
1550 | "topics": [ | |
1550 | { |
|
1551 | { | |
1551 | "summary": "Configuration Files", |
|
1552 | "summary": "Configuration Files", | |
1552 | "topic": "config" |
|
1553 | "topic": "config" | |
1553 | }, |
|
1554 | }, | |
1554 | { |
|
1555 | { | |
1555 | "summary": "Date Formats", |
|
1556 | "summary": "Date Formats", | |
1556 | "topic": "dates" |
|
1557 | "topic": "dates" | |
1557 | }, |
|
1558 | }, | |
1558 | { |
|
1559 | { | |
1559 | "summary": "Diff Formats", |
|
1560 | "summary": "Diff Formats", | |
1560 | "topic": "diffs" |
|
1561 | "topic": "diffs" | |
1561 | }, |
|
1562 | }, | |
1562 | { |
|
1563 | { | |
1563 | "summary": "Environment Variables", |
|
1564 | "summary": "Environment Variables", | |
1564 | "topic": "environment" |
|
1565 | "topic": "environment" | |
1565 | }, |
|
1566 | }, | |
1566 | { |
|
1567 | { | |
1567 | "summary": "Using Additional Features", |
|
1568 | "summary": "Using Additional Features", | |
1568 | "topic": "extensions" |
|
1569 | "topic": "extensions" | |
1569 | }, |
|
1570 | }, | |
1570 | { |
|
1571 | { | |
1571 | "summary": "Specifying File Sets", |
|
1572 | "summary": "Specifying File Sets", | |
1572 | "topic": "filesets" |
|
1573 | "topic": "filesets" | |
1573 | }, |
|
1574 | }, | |
1574 | { |
|
1575 | { | |
1575 | "summary": "Glossary", |
|
1576 | "summary": "Glossary", | |
1576 | "topic": "glossary" |
|
1577 | "topic": "glossary" | |
1577 | }, |
|
1578 | }, | |
1578 | { |
|
1579 | { | |
1579 | "summary": "Syntax for Mercurial Ignore Files", |
|
1580 | "summary": "Syntax for Mercurial Ignore Files", | |
1580 | "topic": "hgignore" |
|
1581 | "topic": "hgignore" | |
1581 | }, |
|
1582 | }, | |
1582 | { |
|
1583 | { | |
1583 | "summary": "Configuring hgweb", |
|
1584 | "summary": "Configuring hgweb", | |
1584 | "topic": "hgweb" |
|
1585 | "topic": "hgweb" | |
1585 | }, |
|
1586 | }, | |
1586 | { |
|
1587 | { | |
1587 | "summary": "Technical implementation topics", |
|
1588 | "summary": "Technical implementation topics", | |
1588 | "topic": "internals" |
|
1589 | "topic": "internals" | |
1589 | }, |
|
1590 | }, | |
1590 | { |
|
1591 | { | |
1591 | "summary": "Merge Tools", |
|
1592 | "summary": "Merge Tools", | |
1592 | "topic": "merge-tools" |
|
1593 | "topic": "merge-tools" | |
1593 | }, |
|
1594 | }, | |
1594 | { |
|
1595 | { | |
1595 | "summary": "Specifying Multiple Revisions", |
|
1596 | "summary": "Specifying Multiple Revisions", | |
1596 | "topic": "multirevs" |
|
1597 | "topic": "multirevs" | |
1597 | }, |
|
1598 | }, | |
1598 | { |
|
1599 | { | |
1599 | "summary": "File Name Patterns", |
|
1600 | "summary": "File Name Patterns", | |
1600 | "topic": "patterns" |
|
1601 | "topic": "patterns" | |
1601 | }, |
|
1602 | }, | |
1602 | { |
|
1603 | { | |
1603 | "summary": "Working with Phases", |
|
1604 | "summary": "Working with Phases", | |
1604 | "topic": "phases" |
|
1605 | "topic": "phases" | |
1605 | }, |
|
1606 | }, | |
1606 | { |
|
1607 | { | |
1607 | "summary": "Specifying Single Revisions", |
|
1608 | "summary": "Specifying Single Revisions", | |
1608 | "topic": "revisions" |
|
1609 | "topic": "revisions" | |
1609 | }, |
|
1610 | }, | |
1610 | { |
|
1611 | { | |
1611 | "summary": "Specifying Revision Sets", |
|
1612 | "summary": "Specifying Revision Sets", | |
1612 | "topic": "revsets" |
|
1613 | "topic": "revsets" | |
1613 | }, |
|
1614 | }, | |
1614 | { |
|
1615 | { | |
1615 | "summary": "Using Mercurial from scripts and automation", |
|
1616 | "summary": "Using Mercurial from scripts and automation", | |
1616 | "topic": "scripting" |
|
1617 | "topic": "scripting" | |
1617 | }, |
|
1618 | }, | |
1618 | { |
|
1619 | { | |
1619 | "summary": "Subrepositories", |
|
1620 | "summary": "Subrepositories", | |
1620 | "topic": "subrepos" |
|
1621 | "topic": "subrepos" | |
1621 | }, |
|
1622 | }, | |
1622 | { |
|
1623 | { | |
1623 | "summary": "Template Usage", |
|
1624 | "summary": "Template Usage", | |
1624 | "topic": "templating" |
|
1625 | "topic": "templating" | |
1625 | }, |
|
1626 | }, | |
1626 | { |
|
1627 | { | |
1627 | "summary": "URL Paths", |
|
1628 | "summary": "URL Paths", | |
1628 | "topic": "urls" |
|
1629 | "topic": "urls" | |
1629 | } |
|
1630 | } | |
1630 | ] |
|
1631 | ] | |
1631 | } |
|
1632 | } | |
1632 |
|
1633 | |||
1633 | help/{topic} shows an individual help topic |
|
1634 | help/{topic} shows an individual help topic | |
1634 |
|
1635 | |||
1635 | $ request json-help/phases |
|
1636 | $ request json-help/phases | |
1636 | 200 Script output follows |
|
1637 | 200 Script output follows | |
1637 |
|
1638 | |||
1638 | { |
|
1639 | { | |
1639 | "rawdoc": "Working with Phases\n*", (glob) |
|
1640 | "rawdoc": "Working with Phases\n*", (glob) | |
1640 | "topic": "phases" |
|
1641 | "topic": "phases" | |
1641 | } |
|
1642 | } |
@@ -1,1404 +1,1619 b'' | |||||
1 | #require serve |
|
1 | #require serve | |
2 |
|
2 | |||
3 | hide outer repo and work in dir without '.hg' |
|
3 | hide outer repo and work in dir without '.hg' | |
4 | $ hg init |
|
4 | $ hg init | |
5 | $ mkdir dir |
|
5 | $ mkdir dir | |
6 | $ cd dir |
|
6 | $ cd dir | |
7 |
|
7 | |||
8 | Tests some basic hgwebdir functionality. Tests setting up paths and |
|
8 | Tests some basic hgwebdir functionality. Tests setting up paths and | |
9 | collection, different forms of 404s and the subdirectory support. |
|
9 | collection, different forms of 404s and the subdirectory support. | |
10 |
|
10 | |||
11 | $ mkdir webdir |
|
11 | $ mkdir webdir | |
12 | $ cd webdir |
|
12 | $ cd webdir | |
13 | $ hg init a |
|
13 | $ hg init a | |
14 | $ echo a > a/a |
|
14 | $ echo a > a/a | |
15 | $ hg --cwd a ci -Ama -d'1 0' |
|
15 | $ hg --cwd a ci -Ama -d'1 0' | |
16 | adding a |
|
16 | adding a | |
17 |
|
17 | |||
18 | create a mercurial queue repository |
|
18 | create a mercurial queue repository | |
19 |
|
19 | |||
20 | $ hg --cwd a qinit --config extensions.hgext.mq= -c |
|
20 | $ hg --cwd a qinit --config extensions.hgext.mq= -c | |
21 | $ hg init b |
|
21 | $ hg init b | |
22 | $ echo b > b/b |
|
22 | $ echo b > b/b | |
23 | $ hg --cwd b ci -Amb -d'2 0' |
|
23 | $ hg --cwd b ci -Amb -d'2 0' | |
24 | adding b |
|
24 | adding b | |
25 |
|
25 | |||
26 | create a nested repository |
|
26 | create a nested repository | |
27 |
|
27 | |||
28 | $ cd b |
|
28 | $ cd b | |
29 | $ hg init d |
|
29 | $ hg init d | |
30 | $ echo d > d/d |
|
30 | $ echo d > d/d | |
31 | $ hg --cwd d ci -Amd -d'3 0' |
|
31 | $ hg --cwd d ci -Amd -d'3 0' | |
32 | adding d |
|
32 | adding d | |
33 | $ cd .. |
|
33 | $ cd .. | |
34 | $ hg init c |
|
34 | $ hg init c | |
35 | $ echo c > c/c |
|
35 | $ echo c > c/c | |
36 | $ hg --cwd c ci -Amc -d'3 0' |
|
36 | $ hg --cwd c ci -Amc -d'3 0' | |
37 | adding c |
|
37 | adding c | |
38 |
|
38 | |||
39 | create a subdirectory containing repositories and subrepositories |
|
39 | create a subdirectory containing repositories and subrepositories | |
40 |
|
40 | |||
41 | $ mkdir notrepo |
|
41 | $ mkdir notrepo | |
42 | $ cd notrepo |
|
42 | $ cd notrepo | |
43 | $ hg init e |
|
43 | $ hg init e | |
44 | $ echo e > e/e |
|
44 | $ echo e > e/e | |
45 | $ hg --cwd e ci -Ame -d'4 0' |
|
45 | $ hg --cwd e ci -Ame -d'4 0' | |
46 | adding e |
|
46 | adding e | |
47 | $ hg init e/e2 |
|
47 | $ hg init e/e2 | |
48 | $ echo e2 > e/e2/e2 |
|
48 | $ echo e2 > e/e2/e2 | |
49 | $ hg --cwd e/e2 ci -Ame2 -d '4 0' |
|
49 | $ hg --cwd e/e2 ci -Ame2 -d '4 0' | |
50 | adding e2 |
|
50 | adding e2 | |
51 | $ hg init f |
|
51 | $ hg init f | |
52 | $ echo f > f/f |
|
52 | $ echo f > f/f | |
53 | $ hg --cwd f ci -Amf -d'4 0' |
|
53 | $ hg --cwd f ci -Amf -d'4 0' | |
54 | adding f |
|
54 | adding f | |
55 | $ hg init f/f2 |
|
55 | $ hg init f/f2 | |
56 | $ echo f2 > f/f2/f2 |
|
56 | $ echo f2 > f/f2/f2 | |
57 | $ hg --cwd f/f2 ci -Amf2 -d '4 0' |
|
57 | $ hg --cwd f/f2 ci -Amf2 -d '4 0' | |
58 | adding f2 |
|
58 | adding f2 | |
59 | $ echo 'f2 = f2' > f/.hgsub |
|
59 | $ echo 'f2 = f2' > f/.hgsub | |
60 | $ hg -R f ci -Am 'add subrepo' -d'4 0' |
|
60 | $ hg -R f ci -Am 'add subrepo' -d'4 0' | |
61 | adding .hgsub |
|
61 | adding .hgsub | |
62 | $ cat >> f/.hg/hgrc << EOF |
|
62 | $ cat >> f/.hg/hgrc << EOF | |
63 | > [web] |
|
63 | > [web] | |
64 | > name = fancy name for repo f |
|
64 | > name = fancy name for repo f | |
|
65 | > labels = foo, bar | |||
65 | > EOF |
|
66 | > EOF | |
66 | $ cd .. |
|
67 | $ cd .. | |
67 |
|
68 | |||
68 | create repository without .hg/store |
|
69 | create repository without .hg/store | |
69 |
|
70 | |||
70 | $ hg init nostore |
|
71 | $ hg init nostore | |
71 | $ rm -R nostore/.hg/store |
|
72 | $ rm -R nostore/.hg/store | |
72 | $ root=`pwd` |
|
73 | $ root=`pwd` | |
73 | $ cd .. |
|
74 | $ cd .. | |
74 |
|
75 | |||
75 | serve |
|
76 | serve | |
76 | $ cat > paths.conf <<EOF |
|
77 | $ cat > paths.conf <<EOF | |
77 | > [paths] |
|
78 | > [paths] | |
78 | > a=$root/a |
|
79 | > a=$root/a | |
79 | > b=$root/b |
|
80 | > b=$root/b | |
80 | > EOF |
|
81 | > EOF | |
81 | $ hg serve -p $HGPORT -d --pid-file=hg.pid --webdir-conf paths.conf \ |
|
82 | $ hg serve -p $HGPORT -d --pid-file=hg.pid --webdir-conf paths.conf \ | |
82 | > -A access-paths.log -E error-paths-1.log |
|
83 | > -A access-paths.log -E error-paths-1.log | |
83 | $ cat hg.pid >> $DAEMON_PIDS |
|
84 | $ cat hg.pid >> $DAEMON_PIDS | |
84 |
|
85 | |||
85 | should give a 404 - file does not exist |
|
86 | should give a 404 - file does not exist | |
86 |
|
87 | |||
87 | $ get-with-headers.py localhost:$HGPORT 'a/file/tip/bork?style=raw' |
|
88 | $ get-with-headers.py localhost:$HGPORT 'a/file/tip/bork?style=raw' | |
88 | 404 Not Found |
|
89 | 404 Not Found | |
89 |
|
90 | |||
90 |
|
91 | |||
91 | error: bork@8580ff50825a: not found in manifest |
|
92 | error: bork@8580ff50825a: not found in manifest | |
92 | [1] |
|
93 | [1] | |
93 |
|
94 | |||
94 | should succeed |
|
95 | should succeed | |
95 |
|
96 | |||
96 | $ get-with-headers.py localhost:$HGPORT '?style=raw' |
|
97 | $ get-with-headers.py localhost:$HGPORT '?style=raw' | |
97 | 200 Script output follows |
|
98 | 200 Script output follows | |
98 |
|
99 | |||
99 |
|
100 | |||
100 | /a/ |
|
101 | /a/ | |
101 | /b/ |
|
102 | /b/ | |
102 |
|
103 | |||
103 | $ get-with-headers.py localhost:$HGPORT '?style=json' |
|
104 | $ get-with-headers.py localhost:$HGPORT '?style=json' | |
104 | 200 Script output follows |
|
105 | 200 Script output follows | |
105 |
|
106 | |||
106 | { |
|
107 | { | |
107 | "entries": [{ |
|
108 | "entries": [{ | |
108 | "name": "a", |
|
109 | "name": "a", | |
109 | "description": "unknown", |
|
110 | "description": "unknown", | |
110 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", |
|
111 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |
111 | "lastchange": [*, *] (glob) |
|
112 | "lastchange": [*, *], (glob) | |
|
113 | "labels": [] | |||
112 | }, { |
|
114 | }, { | |
113 | "name": "b", |
|
115 | "name": "b", | |
114 | "description": "unknown", |
|
116 | "description": "unknown", | |
115 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", |
|
117 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |
116 | "lastchange": [*, *] (glob) |
|
118 | "lastchange": [*, *], (glob) | |
|
119 | "labels": [] | |||
117 | }] |
|
120 | }] | |
118 | } (no-eol) |
|
121 | } (no-eol) | |
119 |
|
122 | |||
120 | $ get-with-headers.py localhost:$HGPORT 'a/file/tip/a?style=raw' |
|
123 | $ get-with-headers.py localhost:$HGPORT 'a/file/tip/a?style=raw' | |
121 | 200 Script output follows |
|
124 | 200 Script output follows | |
122 |
|
125 | |||
123 | a |
|
126 | a | |
124 | $ get-with-headers.py localhost:$HGPORT 'b/file/tip/b?style=raw' |
|
127 | $ get-with-headers.py localhost:$HGPORT 'b/file/tip/b?style=raw' | |
125 | 200 Script output follows |
|
128 | 200 Script output follows | |
126 |
|
129 | |||
127 | b |
|
130 | b | |
128 |
|
131 | |||
129 | should give a 404 - repo is not published |
|
132 | should give a 404 - repo is not published | |
130 |
|
133 | |||
131 | $ get-with-headers.py localhost:$HGPORT 'c/file/tip/c?style=raw' |
|
134 | $ get-with-headers.py localhost:$HGPORT 'c/file/tip/c?style=raw' | |
132 | 404 Not Found |
|
135 | 404 Not Found | |
133 |
|
136 | |||
134 |
|
137 | |||
135 | error: repository c/file/tip/c not found |
|
138 | error: repository c/file/tip/c not found | |
136 | [1] |
|
139 | [1] | |
137 |
|
140 | |||
138 | atom-log without basedir |
|
141 | atom-log without basedir | |
139 |
|
142 | |||
140 | $ get-with-headers.py localhost:$HGPORT 'a/atom-log' | grep '<link' |
|
143 | $ get-with-headers.py localhost:$HGPORT 'a/atom-log' | grep '<link' | |
141 | <link rel="self" href="http://*:$HGPORT/a/atom-log"/> (glob) |
|
144 | <link rel="self" href="http://*:$HGPORT/a/atom-log"/> (glob) | |
142 | <link rel="alternate" href="http://*:$HGPORT/a/"/> (glob) |
|
145 | <link rel="alternate" href="http://*:$HGPORT/a/"/> (glob) | |
143 | <link href="http://*:$HGPORT/a/rev/8580ff50825a"/> (glob) |
|
146 | <link href="http://*:$HGPORT/a/rev/8580ff50825a"/> (glob) | |
144 |
|
147 | |||
145 | rss-log without basedir |
|
148 | rss-log without basedir | |
146 |
|
149 | |||
147 | $ get-with-headers.py localhost:$HGPORT 'a/rss-log' | grep '<guid' |
|
150 | $ get-with-headers.py localhost:$HGPORT 'a/rss-log' | grep '<guid' | |
148 | <guid isPermaLink="true">http://*:$HGPORT/a/rev/8580ff50825a</guid> (glob) |
|
151 | <guid isPermaLink="true">http://*:$HGPORT/a/rev/8580ff50825a</guid> (glob) | |
149 | $ cat > paths.conf <<EOF |
|
152 | $ cat > paths.conf <<EOF | |
150 | > [paths] |
|
153 | > [paths] | |
151 | > t/a/=$root/a |
|
154 | > t/a/=$root/a | |
152 | > b=$root/b |
|
155 | > b=$root/b | |
153 | > coll=$root/* |
|
156 | > coll=$root/* | |
154 | > rcoll=$root/** |
|
157 | > rcoll=$root/** | |
155 | > star=* |
|
158 | > star=* | |
156 | > starstar=** |
|
159 | > starstar=** | |
157 | > astar=webdir/a/* |
|
160 | > astar=webdir/a/* | |
158 | > EOF |
|
161 | > EOF | |
159 | $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \ |
|
162 | $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \ | |
160 | > -A access-paths.log -E error-paths-2.log |
|
163 | > -A access-paths.log -E error-paths-2.log | |
161 | $ cat hg.pid >> $DAEMON_PIDS |
|
164 | $ cat hg.pid >> $DAEMON_PIDS | |
162 |
|
165 | |||
163 | should succeed, slashy names |
|
166 | should succeed, slashy names | |
164 |
|
167 | |||
165 | $ get-with-headers.py localhost:$HGPORT1 '?style=raw' |
|
168 | $ get-with-headers.py localhost:$HGPORT1 '?style=raw' | |
166 | 200 Script output follows |
|
169 | 200 Script output follows | |
167 |
|
170 | |||
168 |
|
171 | |||
169 | /t/a/ |
|
172 | /t/a/ | |
170 | /b/ |
|
173 | /b/ | |
171 | /coll/a/ |
|
174 | /coll/a/ | |
172 | /coll/a/.hg/patches/ |
|
175 | /coll/a/.hg/patches/ | |
173 | /coll/b/ |
|
176 | /coll/b/ | |
174 | /coll/c/ |
|
177 | /coll/c/ | |
175 | /coll/notrepo/e/ |
|
178 | /coll/notrepo/e/ | |
176 | /coll/notrepo/f/ |
|
179 | /coll/notrepo/f/ | |
177 | /rcoll/a/ |
|
180 | /rcoll/a/ | |
178 | /rcoll/a/.hg/patches/ |
|
181 | /rcoll/a/.hg/patches/ | |
179 | /rcoll/b/ |
|
182 | /rcoll/b/ | |
180 | /rcoll/b/d/ |
|
183 | /rcoll/b/d/ | |
181 | /rcoll/c/ |
|
184 | /rcoll/c/ | |
182 | /rcoll/notrepo/e/ |
|
185 | /rcoll/notrepo/e/ | |
183 | /rcoll/notrepo/e/e2/ |
|
186 | /rcoll/notrepo/e/e2/ | |
184 | /rcoll/notrepo/f/ |
|
187 | /rcoll/notrepo/f/ | |
185 | /rcoll/notrepo/f/f2/ |
|
188 | /rcoll/notrepo/f/f2/ | |
186 | /star/webdir/a/ |
|
189 | /star/webdir/a/ | |
187 | /star/webdir/a/.hg/patches/ |
|
190 | /star/webdir/a/.hg/patches/ | |
188 | /star/webdir/b/ |
|
191 | /star/webdir/b/ | |
189 | /star/webdir/c/ |
|
192 | /star/webdir/c/ | |
190 | /star/webdir/notrepo/e/ |
|
193 | /star/webdir/notrepo/e/ | |
191 | /star/webdir/notrepo/f/ |
|
194 | /star/webdir/notrepo/f/ | |
192 | /starstar/webdir/a/ |
|
195 | /starstar/webdir/a/ | |
193 | /starstar/webdir/a/.hg/patches/ |
|
196 | /starstar/webdir/a/.hg/patches/ | |
194 | /starstar/webdir/b/ |
|
197 | /starstar/webdir/b/ | |
195 | /starstar/webdir/b/d/ |
|
198 | /starstar/webdir/b/d/ | |
196 | /starstar/webdir/c/ |
|
199 | /starstar/webdir/c/ | |
197 | /starstar/webdir/notrepo/e/ |
|
200 | /starstar/webdir/notrepo/e/ | |
198 | /starstar/webdir/notrepo/e/e2/ |
|
201 | /starstar/webdir/notrepo/e/e2/ | |
199 | /starstar/webdir/notrepo/f/ |
|
202 | /starstar/webdir/notrepo/f/ | |
200 | /starstar/webdir/notrepo/f/f2/ |
|
203 | /starstar/webdir/notrepo/f/f2/ | |
201 | /astar/ |
|
204 | /astar/ | |
202 | /astar/.hg/patches/ |
|
205 | /astar/.hg/patches/ | |
203 |
|
206 | |||
|
207 | ||||
|
208 | $ get-with-headers.py localhost:$HGPORT1 '?style=json' | |||
|
209 | 200 Script output follows | |||
|
210 | ||||
|
211 | { | |||
|
212 | "entries": [{ | |||
|
213 | "name": "t/a", | |||
|
214 | "description": "unknown", | |||
|
215 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
216 | "lastchange": [*, *], (glob) | |||
|
217 | "labels": [] | |||
|
218 | }, { | |||
|
219 | "name": "b", | |||
|
220 | "description": "unknown", | |||
|
221 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
222 | "lastchange": [*, *], (glob) | |||
|
223 | "labels": [] | |||
|
224 | }, { | |||
|
225 | "name": "coll/a", | |||
|
226 | "description": "unknown", | |||
|
227 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
228 | "lastchange": [*, *], (glob) | |||
|
229 | "labels": [] | |||
|
230 | }, { | |||
|
231 | "name": "coll/a/.hg/patches", | |||
|
232 | "description": "unknown", | |||
|
233 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
234 | "lastchange": [*, *], (glob) | |||
|
235 | "labels": [] | |||
|
236 | }, { | |||
|
237 | "name": "coll/b", | |||
|
238 | "description": "unknown", | |||
|
239 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
240 | "lastchange": [*, *], (glob) | |||
|
241 | "labels": [] | |||
|
242 | }, { | |||
|
243 | "name": "coll/c", | |||
|
244 | "description": "unknown", | |||
|
245 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
246 | "lastchange": [*, *], (glob) | |||
|
247 | "labels": [] | |||
|
248 | }, { | |||
|
249 | "name": "coll/notrepo/e", | |||
|
250 | "description": "unknown", | |||
|
251 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
252 | "lastchange": [*, *], (glob) | |||
|
253 | "labels": [] | |||
|
254 | }, { | |||
|
255 | "name": "fancy name for repo f", | |||
|
256 | "description": "unknown", | |||
|
257 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
258 | "lastchange": [*, *], (glob) | |||
|
259 | "labels": ["foo", "bar"] | |||
|
260 | }, { | |||
|
261 | "name": "rcoll/a", | |||
|
262 | "description": "unknown", | |||
|
263 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
264 | "lastchange": [*, *], (glob) | |||
|
265 | "labels": [] | |||
|
266 | }, { | |||
|
267 | "name": "rcoll/a/.hg/patches", | |||
|
268 | "description": "unknown", | |||
|
269 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
270 | "lastchange": [*, *], (glob) | |||
|
271 | "labels": [] | |||
|
272 | }, { | |||
|
273 | "name": "rcoll/b", | |||
|
274 | "description": "unknown", | |||
|
275 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
276 | "lastchange": [*, *], (glob) | |||
|
277 | "labels": [] | |||
|
278 | }, { | |||
|
279 | "name": "rcoll/b/d", | |||
|
280 | "description": "unknown", | |||
|
281 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
282 | "lastchange": [*, *], (glob) | |||
|
283 | "labels": [] | |||
|
284 | }, { | |||
|
285 | "name": "rcoll/c", | |||
|
286 | "description": "unknown", | |||
|
287 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
288 | "lastchange": [*, *], (glob) | |||
|
289 | "labels": [] | |||
|
290 | }, { | |||
|
291 | "name": "rcoll/notrepo/e", | |||
|
292 | "description": "unknown", | |||
|
293 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
294 | "lastchange": [*, *], (glob) | |||
|
295 | "labels": [] | |||
|
296 | }, { | |||
|
297 | "name": "rcoll/notrepo/e/e2", | |||
|
298 | "description": "unknown", | |||
|
299 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
300 | "lastchange": [*, *], (glob) | |||
|
301 | "labels": [] | |||
|
302 | }, { | |||
|
303 | "name": "fancy name for repo f", | |||
|
304 | "description": "unknown", | |||
|
305 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
306 | "lastchange": [*, *], (glob) | |||
|
307 | "labels": ["foo", "bar"] | |||
|
308 | }, { | |||
|
309 | "name": "rcoll/notrepo/f/f2", | |||
|
310 | "description": "unknown", | |||
|
311 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
312 | "lastchange": [*, *], (glob) | |||
|
313 | "labels": [] | |||
|
314 | }, { | |||
|
315 | "name": "star/webdir/a", | |||
|
316 | "description": "unknown", | |||
|
317 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
318 | "lastchange": [*, *], (glob) | |||
|
319 | "labels": [] | |||
|
320 | }, { | |||
|
321 | "name": "star/webdir/a/.hg/patches", | |||
|
322 | "description": "unknown", | |||
|
323 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
324 | "lastchange": [*, *], (glob) | |||
|
325 | "labels": [] | |||
|
326 | }, { | |||
|
327 | "name": "star/webdir/b", | |||
|
328 | "description": "unknown", | |||
|
329 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
330 | "lastchange": [*, *], (glob) | |||
|
331 | "labels": [] | |||
|
332 | }, { | |||
|
333 | "name": "star/webdir/c", | |||
|
334 | "description": "unknown", | |||
|
335 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
336 | "lastchange": [*, *], (glob) | |||
|
337 | "labels": [] | |||
|
338 | }, { | |||
|
339 | "name": "star/webdir/notrepo/e", | |||
|
340 | "description": "unknown", | |||
|
341 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
342 | "lastchange": [*, *], (glob) | |||
|
343 | "labels": [] | |||
|
344 | }, { | |||
|
345 | "name": "fancy name for repo f", | |||
|
346 | "description": "unknown", | |||
|
347 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
348 | "lastchange": [*, *], (glob) | |||
|
349 | "labels": ["foo", "bar"] | |||
|
350 | }, { | |||
|
351 | "name": "starstar/webdir/a", | |||
|
352 | "description": "unknown", | |||
|
353 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
354 | "lastchange": [*, *], (glob) | |||
|
355 | "labels": [] | |||
|
356 | }, { | |||
|
357 | "name": "starstar/webdir/a/.hg/patches", | |||
|
358 | "description": "unknown", | |||
|
359 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
360 | "lastchange": [*, *], (glob) | |||
|
361 | "labels": [] | |||
|
362 | }, { | |||
|
363 | "name": "starstar/webdir/b", | |||
|
364 | "description": "unknown", | |||
|
365 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
366 | "lastchange": [*, *], (glob) | |||
|
367 | "labels": [] | |||
|
368 | }, { | |||
|
369 | "name": "starstar/webdir/b/d", | |||
|
370 | "description": "unknown", | |||
|
371 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
372 | "lastchange": [*, *], (glob) | |||
|
373 | "labels": [] | |||
|
374 | }, { | |||
|
375 | "name": "starstar/webdir/c", | |||
|
376 | "description": "unknown", | |||
|
377 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
378 | "lastchange": [*, *], (glob) | |||
|
379 | "labels": [] | |||
|
380 | }, { | |||
|
381 | "name": "starstar/webdir/notrepo/e", | |||
|
382 | "description": "unknown", | |||
|
383 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
384 | "lastchange": [*, *], (glob) | |||
|
385 | "labels": [] | |||
|
386 | }, { | |||
|
387 | "name": "starstar/webdir/notrepo/e/e2", | |||
|
388 | "description": "unknown", | |||
|
389 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
390 | "lastchange": [*, *], (glob) | |||
|
391 | "labels": [] | |||
|
392 | }, { | |||
|
393 | "name": "fancy name for repo f", | |||
|
394 | "description": "unknown", | |||
|
395 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
396 | "lastchange": [*, *], (glob) | |||
|
397 | "labels": ["foo", "bar"] | |||
|
398 | }, { | |||
|
399 | "name": "starstar/webdir/notrepo/f/f2", | |||
|
400 | "description": "unknown", | |||
|
401 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
402 | "lastchange": [*, *], (glob) | |||
|
403 | "labels": [] | |||
|
404 | }, { | |||
|
405 | "name": "astar", | |||
|
406 | "description": "unknown", | |||
|
407 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
408 | "lastchange": [*, *], (glob) | |||
|
409 | "labels": [] | |||
|
410 | }, { | |||
|
411 | "name": "astar/.hg/patches", | |||
|
412 | "description": "unknown", | |||
|
413 | "contact": "Foo Bar \u003cfoo.bar@example.com\u003e", | |||
|
414 | "lastchange": [*, *], (glob) | |||
|
415 | "labels": [] | |||
|
416 | }] | |||
|
417 | } (no-eol) | |||
|
418 | ||||
204 | $ get-with-headers.py localhost:$HGPORT1 '?style=paper' |
|
419 | $ get-with-headers.py localhost:$HGPORT1 '?style=paper' | |
205 | 200 Script output follows |
|
420 | 200 Script output follows | |
206 |
|
421 | |||
207 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> |
|
422 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> | |
208 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US"> |
|
423 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US"> | |
209 | <head> |
|
424 | <head> | |
210 | <link rel="icon" href="/static/hgicon.png" type="image/png" /> |
|
425 | <link rel="icon" href="/static/hgicon.png" type="image/png" /> | |
211 | <meta name="robots" content="index, nofollow" /> |
|
426 | <meta name="robots" content="index, nofollow" /> | |
212 | <link rel="stylesheet" href="/static/style-paper.css" type="text/css" /> |
|
427 | <link rel="stylesheet" href="/static/style-paper.css" type="text/css" /> | |
213 | <script type="text/javascript" src="/static/mercurial.js"></script> |
|
428 | <script type="text/javascript" src="/static/mercurial.js"></script> | |
214 |
|
429 | |||
215 | <title>Mercurial repositories index</title> |
|
430 | <title>Mercurial repositories index</title> | |
216 | </head> |
|
431 | </head> | |
217 | <body> |
|
432 | <body> | |
218 |
|
433 | |||
219 | <div class="container"> |
|
434 | <div class="container"> | |
220 | <div class="menu"> |
|
435 | <div class="menu"> | |
221 | <a href="https://mercurial-scm.org/"> |
|
436 | <a href="https://mercurial-scm.org/"> | |
222 | <img src="/static/hglogo.png" width=75 height=90 border=0 alt="mercurial" /></a> |
|
437 | <img src="/static/hglogo.png" width=75 height=90 border=0 alt="mercurial" /></a> | |
223 | </div> |
|
438 | </div> | |
224 | <div class="main"> |
|
439 | <div class="main"> | |
225 | <h2 class="breadcrumb"><a href="/">Mercurial</a> </h2> |
|
440 | <h2 class="breadcrumb"><a href="/">Mercurial</a> </h2> | |
226 |
|
441 | |||
227 | <table class="bigtable"> |
|
442 | <table class="bigtable"> | |
228 | <thead> |
|
443 | <thead> | |
229 | <tr> |
|
444 | <tr> | |
230 | <th><a href="?sort=name">Name</a></th> |
|
445 | <th><a href="?sort=name">Name</a></th> | |
231 | <th><a href="?sort=description">Description</a></th> |
|
446 | <th><a href="?sort=description">Description</a></th> | |
232 | <th><a href="?sort=contact">Contact</a></th> |
|
447 | <th><a href="?sort=contact">Contact</a></th> | |
233 | <th><a href="?sort=lastchange">Last modified</a></th> |
|
448 | <th><a href="?sort=lastchange">Last modified</a></th> | |
234 | <th> </th> |
|
449 | <th> </th> | |
235 | <th> </th> |
|
450 | <th> </th> | |
236 | </tr> |
|
451 | </tr> | |
237 | </thead> |
|
452 | </thead> | |
238 | <tbody class="stripes2"> |
|
453 | <tbody class="stripes2"> | |
239 |
|
454 | |||
240 | <tr> |
|
455 | <tr> | |
241 | <td><a href="/t/a/?style=paper">t/a</a></td> |
|
456 | <td><a href="/t/a/?style=paper">t/a</a></td> | |
242 | <td>unknown</td> |
|
457 | <td>unknown</td> | |
243 | <td>Foo Bar <foo.bar@example.com></td> |
|
458 | <td>Foo Bar <foo.bar@example.com></td> | |
244 | <td class="age">*</td> (glob) |
|
459 | <td class="age">*</td> (glob) | |
245 | <td class="indexlinks"></td> |
|
460 | <td class="indexlinks"></td> | |
246 | <td> |
|
461 | <td> | |
247 | <a href="/t/a/atom-log" title="subscribe to repository atom feed"> |
|
462 | <a href="/t/a/atom-log" title="subscribe to repository atom feed"> | |
248 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
463 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
249 | </a> |
|
464 | </a> | |
250 | </td> |
|
465 | </td> | |
251 | </tr> |
|
466 | </tr> | |
252 |
|
467 | |||
253 | <tr> |
|
468 | <tr> | |
254 | <td><a href="/b/?style=paper">b</a></td> |
|
469 | <td><a href="/b/?style=paper">b</a></td> | |
255 | <td>unknown</td> |
|
470 | <td>unknown</td> | |
256 | <td>Foo Bar <foo.bar@example.com></td> |
|
471 | <td>Foo Bar <foo.bar@example.com></td> | |
257 | <td class="age">*</td> (glob) |
|
472 | <td class="age">*</td> (glob) | |
258 | <td class="indexlinks"></td> |
|
473 | <td class="indexlinks"></td> | |
259 | <td> |
|
474 | <td> | |
260 | <a href="/b/atom-log" title="subscribe to repository atom feed"> |
|
475 | <a href="/b/atom-log" title="subscribe to repository atom feed"> | |
261 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
476 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
262 | </a> |
|
477 | </a> | |
263 | </td> |
|
478 | </td> | |
264 | </tr> |
|
479 | </tr> | |
265 |
|
480 | |||
266 | <tr> |
|
481 | <tr> | |
267 | <td><a href="/coll/a/?style=paper">coll/a</a></td> |
|
482 | <td><a href="/coll/a/?style=paper">coll/a</a></td> | |
268 | <td>unknown</td> |
|
483 | <td>unknown</td> | |
269 | <td>Foo Bar <foo.bar@example.com></td> |
|
484 | <td>Foo Bar <foo.bar@example.com></td> | |
270 | <td class="age">*</td> (glob) |
|
485 | <td class="age">*</td> (glob) | |
271 | <td class="indexlinks"></td> |
|
486 | <td class="indexlinks"></td> | |
272 | <td> |
|
487 | <td> | |
273 | <a href="/coll/a/atom-log" title="subscribe to repository atom feed"> |
|
488 | <a href="/coll/a/atom-log" title="subscribe to repository atom feed"> | |
274 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
489 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
275 | </a> |
|
490 | </a> | |
276 | </td> |
|
491 | </td> | |
277 | </tr> |
|
492 | </tr> | |
278 |
|
493 | |||
279 | <tr> |
|
494 | <tr> | |
280 | <td><a href="/coll/a/.hg/patches/?style=paper">coll/a/.hg/patches</a></td> |
|
495 | <td><a href="/coll/a/.hg/patches/?style=paper">coll/a/.hg/patches</a></td> | |
281 | <td>unknown</td> |
|
496 | <td>unknown</td> | |
282 | <td>Foo Bar <foo.bar@example.com></td> |
|
497 | <td>Foo Bar <foo.bar@example.com></td> | |
283 | <td class="age">*</td> (glob) |
|
498 | <td class="age">*</td> (glob) | |
284 | <td class="indexlinks"></td> |
|
499 | <td class="indexlinks"></td> | |
285 | <td> |
|
500 | <td> | |
286 | <a href="/coll/a/.hg/patches/atom-log" title="subscribe to repository atom feed"> |
|
501 | <a href="/coll/a/.hg/patches/atom-log" title="subscribe to repository atom feed"> | |
287 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
502 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
288 | </a> |
|
503 | </a> | |
289 | </td> |
|
504 | </td> | |
290 | </tr> |
|
505 | </tr> | |
291 |
|
506 | |||
292 | <tr> |
|
507 | <tr> | |
293 | <td><a href="/coll/b/?style=paper">coll/b</a></td> |
|
508 | <td><a href="/coll/b/?style=paper">coll/b</a></td> | |
294 | <td>unknown</td> |
|
509 | <td>unknown</td> | |
295 | <td>Foo Bar <foo.bar@example.com></td> |
|
510 | <td>Foo Bar <foo.bar@example.com></td> | |
296 | <td class="age">*</td> (glob) |
|
511 | <td class="age">*</td> (glob) | |
297 | <td class="indexlinks"></td> |
|
512 | <td class="indexlinks"></td> | |
298 | <td> |
|
513 | <td> | |
299 | <a href="/coll/b/atom-log" title="subscribe to repository atom feed"> |
|
514 | <a href="/coll/b/atom-log" title="subscribe to repository atom feed"> | |
300 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
515 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
301 | </a> |
|
516 | </a> | |
302 | </td> |
|
517 | </td> | |
303 | </tr> |
|
518 | </tr> | |
304 |
|
519 | |||
305 | <tr> |
|
520 | <tr> | |
306 | <td><a href="/coll/c/?style=paper">coll/c</a></td> |
|
521 | <td><a href="/coll/c/?style=paper">coll/c</a></td> | |
307 | <td>unknown</td> |
|
522 | <td>unknown</td> | |
308 | <td>Foo Bar <foo.bar@example.com></td> |
|
523 | <td>Foo Bar <foo.bar@example.com></td> | |
309 | <td class="age">*</td> (glob) |
|
524 | <td class="age">*</td> (glob) | |
310 | <td class="indexlinks"></td> |
|
525 | <td class="indexlinks"></td> | |
311 | <td> |
|
526 | <td> | |
312 | <a href="/coll/c/atom-log" title="subscribe to repository atom feed"> |
|
527 | <a href="/coll/c/atom-log" title="subscribe to repository atom feed"> | |
313 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
528 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
314 | </a> |
|
529 | </a> | |
315 | </td> |
|
530 | </td> | |
316 | </tr> |
|
531 | </tr> | |
317 |
|
532 | |||
318 | <tr> |
|
533 | <tr> | |
319 | <td><a href="/coll/notrepo/e/?style=paper">coll/notrepo/e</a></td> |
|
534 | <td><a href="/coll/notrepo/e/?style=paper">coll/notrepo/e</a></td> | |
320 | <td>unknown</td> |
|
535 | <td>unknown</td> | |
321 | <td>Foo Bar <foo.bar@example.com></td> |
|
536 | <td>Foo Bar <foo.bar@example.com></td> | |
322 | <td class="age">*</td> (glob) |
|
537 | <td class="age">*</td> (glob) | |
323 | <td class="indexlinks"></td> |
|
538 | <td class="indexlinks"></td> | |
324 | <td> |
|
539 | <td> | |
325 | <a href="/coll/notrepo/e/atom-log" title="subscribe to repository atom feed"> |
|
540 | <a href="/coll/notrepo/e/atom-log" title="subscribe to repository atom feed"> | |
326 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
541 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
327 | </a> |
|
542 | </a> | |
328 | </td> |
|
543 | </td> | |
329 | </tr> |
|
544 | </tr> | |
330 |
|
545 | |||
331 | <tr> |
|
546 | <tr> | |
332 | <td><a href="/coll/notrepo/f/?style=paper">fancy name for repo f</a></td> |
|
547 | <td><a href="/coll/notrepo/f/?style=paper">fancy name for repo f</a></td> | |
333 | <td>unknown</td> |
|
548 | <td>unknown</td> | |
334 | <td>Foo Bar <foo.bar@example.com></td> |
|
549 | <td>Foo Bar <foo.bar@example.com></td> | |
335 | <td class="age">*</td> (glob) |
|
550 | <td class="age">*</td> (glob) | |
336 | <td class="indexlinks"></td> |
|
551 | <td class="indexlinks"></td> | |
337 | <td> |
|
552 | <td> | |
338 | <a href="/coll/notrepo/f/atom-log" title="subscribe to repository atom feed"> |
|
553 | <a href="/coll/notrepo/f/atom-log" title="subscribe to repository atom feed"> | |
339 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
554 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
340 | </a> |
|
555 | </a> | |
341 | </td> |
|
556 | </td> | |
342 | </tr> |
|
557 | </tr> | |
343 |
|
558 | |||
344 | <tr> |
|
559 | <tr> | |
345 | <td><a href="/rcoll/a/?style=paper">rcoll/a</a></td> |
|
560 | <td><a href="/rcoll/a/?style=paper">rcoll/a</a></td> | |
346 | <td>unknown</td> |
|
561 | <td>unknown</td> | |
347 | <td>Foo Bar <foo.bar@example.com></td> |
|
562 | <td>Foo Bar <foo.bar@example.com></td> | |
348 | <td class="age">*</td> (glob) |
|
563 | <td class="age">*</td> (glob) | |
349 | <td class="indexlinks"></td> |
|
564 | <td class="indexlinks"></td> | |
350 | <td> |
|
565 | <td> | |
351 | <a href="/rcoll/a/atom-log" title="subscribe to repository atom feed"> |
|
566 | <a href="/rcoll/a/atom-log" title="subscribe to repository atom feed"> | |
352 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
567 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
353 | </a> |
|
568 | </a> | |
354 | </td> |
|
569 | </td> | |
355 | </tr> |
|
570 | </tr> | |
356 |
|
571 | |||
357 | <tr> |
|
572 | <tr> | |
358 | <td><a href="/rcoll/a/.hg/patches/?style=paper">rcoll/a/.hg/patches</a></td> |
|
573 | <td><a href="/rcoll/a/.hg/patches/?style=paper">rcoll/a/.hg/patches</a></td> | |
359 | <td>unknown</td> |
|
574 | <td>unknown</td> | |
360 | <td>Foo Bar <foo.bar@example.com></td> |
|
575 | <td>Foo Bar <foo.bar@example.com></td> | |
361 | <td class="age">*</td> (glob) |
|
576 | <td class="age">*</td> (glob) | |
362 | <td class="indexlinks"></td> |
|
577 | <td class="indexlinks"></td> | |
363 | <td> |
|
578 | <td> | |
364 | <a href="/rcoll/a/.hg/patches/atom-log" title="subscribe to repository atom feed"> |
|
579 | <a href="/rcoll/a/.hg/patches/atom-log" title="subscribe to repository atom feed"> | |
365 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
580 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
366 | </a> |
|
581 | </a> | |
367 | </td> |
|
582 | </td> | |
368 | </tr> |
|
583 | </tr> | |
369 |
|
584 | |||
370 | <tr> |
|
585 | <tr> | |
371 | <td><a href="/rcoll/b/?style=paper">rcoll/b</a></td> |
|
586 | <td><a href="/rcoll/b/?style=paper">rcoll/b</a></td> | |
372 | <td>unknown</td> |
|
587 | <td>unknown</td> | |
373 | <td>Foo Bar <foo.bar@example.com></td> |
|
588 | <td>Foo Bar <foo.bar@example.com></td> | |
374 | <td class="age">*</td> (glob) |
|
589 | <td class="age">*</td> (glob) | |
375 | <td class="indexlinks"></td> |
|
590 | <td class="indexlinks"></td> | |
376 | <td> |
|
591 | <td> | |
377 | <a href="/rcoll/b/atom-log" title="subscribe to repository atom feed"> |
|
592 | <a href="/rcoll/b/atom-log" title="subscribe to repository atom feed"> | |
378 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
593 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
379 | </a> |
|
594 | </a> | |
380 | </td> |
|
595 | </td> | |
381 | </tr> |
|
596 | </tr> | |
382 |
|
597 | |||
383 | <tr> |
|
598 | <tr> | |
384 | <td><a href="/rcoll/b/d/?style=paper">rcoll/b/d</a></td> |
|
599 | <td><a href="/rcoll/b/d/?style=paper">rcoll/b/d</a></td> | |
385 | <td>unknown</td> |
|
600 | <td>unknown</td> | |
386 | <td>Foo Bar <foo.bar@example.com></td> |
|
601 | <td>Foo Bar <foo.bar@example.com></td> | |
387 | <td class="age">*</td> (glob) |
|
602 | <td class="age">*</td> (glob) | |
388 | <td class="indexlinks"></td> |
|
603 | <td class="indexlinks"></td> | |
389 | <td> |
|
604 | <td> | |
390 | <a href="/rcoll/b/d/atom-log" title="subscribe to repository atom feed"> |
|
605 | <a href="/rcoll/b/d/atom-log" title="subscribe to repository atom feed"> | |
391 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
606 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
392 | </a> |
|
607 | </a> | |
393 | </td> |
|
608 | </td> | |
394 | </tr> |
|
609 | </tr> | |
395 |
|
610 | |||
396 | <tr> |
|
611 | <tr> | |
397 | <td><a href="/rcoll/c/?style=paper">rcoll/c</a></td> |
|
612 | <td><a href="/rcoll/c/?style=paper">rcoll/c</a></td> | |
398 | <td>unknown</td> |
|
613 | <td>unknown</td> | |
399 | <td>Foo Bar <foo.bar@example.com></td> |
|
614 | <td>Foo Bar <foo.bar@example.com></td> | |
400 | <td class="age">*</td> (glob) |
|
615 | <td class="age">*</td> (glob) | |
401 | <td class="indexlinks"></td> |
|
616 | <td class="indexlinks"></td> | |
402 | <td> |
|
617 | <td> | |
403 | <a href="/rcoll/c/atom-log" title="subscribe to repository atom feed"> |
|
618 | <a href="/rcoll/c/atom-log" title="subscribe to repository atom feed"> | |
404 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
619 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
405 | </a> |
|
620 | </a> | |
406 | </td> |
|
621 | </td> | |
407 | </tr> |
|
622 | </tr> | |
408 |
|
623 | |||
409 | <tr> |
|
624 | <tr> | |
410 | <td><a href="/rcoll/notrepo/e/?style=paper">rcoll/notrepo/e</a></td> |
|
625 | <td><a href="/rcoll/notrepo/e/?style=paper">rcoll/notrepo/e</a></td> | |
411 | <td>unknown</td> |
|
626 | <td>unknown</td> | |
412 | <td>Foo Bar <foo.bar@example.com></td> |
|
627 | <td>Foo Bar <foo.bar@example.com></td> | |
413 | <td class="age">*</td> (glob) |
|
628 | <td class="age">*</td> (glob) | |
414 | <td class="indexlinks"></td> |
|
629 | <td class="indexlinks"></td> | |
415 | <td> |
|
630 | <td> | |
416 | <a href="/rcoll/notrepo/e/atom-log" title="subscribe to repository atom feed"> |
|
631 | <a href="/rcoll/notrepo/e/atom-log" title="subscribe to repository atom feed"> | |
417 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
632 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
418 | </a> |
|
633 | </a> | |
419 | </td> |
|
634 | </td> | |
420 | </tr> |
|
635 | </tr> | |
421 |
|
636 | |||
422 | <tr> |
|
637 | <tr> | |
423 | <td><a href="/rcoll/notrepo/e/e2/?style=paper">rcoll/notrepo/e/e2</a></td> |
|
638 | <td><a href="/rcoll/notrepo/e/e2/?style=paper">rcoll/notrepo/e/e2</a></td> | |
424 | <td>unknown</td> |
|
639 | <td>unknown</td> | |
425 | <td>Foo Bar <foo.bar@example.com></td> |
|
640 | <td>Foo Bar <foo.bar@example.com></td> | |
426 | <td class="age">*</td> (glob) |
|
641 | <td class="age">*</td> (glob) | |
427 | <td class="indexlinks"></td> |
|
642 | <td class="indexlinks"></td> | |
428 | <td> |
|
643 | <td> | |
429 | <a href="/rcoll/notrepo/e/e2/atom-log" title="subscribe to repository atom feed"> |
|
644 | <a href="/rcoll/notrepo/e/e2/atom-log" title="subscribe to repository atom feed"> | |
430 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
645 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
431 | </a> |
|
646 | </a> | |
432 | </td> |
|
647 | </td> | |
433 | </tr> |
|
648 | </tr> | |
434 |
|
649 | |||
435 | <tr> |
|
650 | <tr> | |
436 | <td><a href="/rcoll/notrepo/f/?style=paper">fancy name for repo f</a></td> |
|
651 | <td><a href="/rcoll/notrepo/f/?style=paper">fancy name for repo f</a></td> | |
437 | <td>unknown</td> |
|
652 | <td>unknown</td> | |
438 | <td>Foo Bar <foo.bar@example.com></td> |
|
653 | <td>Foo Bar <foo.bar@example.com></td> | |
439 | <td class="age">*</td> (glob) |
|
654 | <td class="age">*</td> (glob) | |
440 | <td class="indexlinks"></td> |
|
655 | <td class="indexlinks"></td> | |
441 | <td> |
|
656 | <td> | |
442 | <a href="/rcoll/notrepo/f/atom-log" title="subscribe to repository atom feed"> |
|
657 | <a href="/rcoll/notrepo/f/atom-log" title="subscribe to repository atom feed"> | |
443 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
658 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
444 | </a> |
|
659 | </a> | |
445 | </td> |
|
660 | </td> | |
446 | </tr> |
|
661 | </tr> | |
447 |
|
662 | |||
448 | <tr> |
|
663 | <tr> | |
449 | <td><a href="/rcoll/notrepo/f/f2/?style=paper">rcoll/notrepo/f/f2</a></td> |
|
664 | <td><a href="/rcoll/notrepo/f/f2/?style=paper">rcoll/notrepo/f/f2</a></td> | |
450 | <td>unknown</td> |
|
665 | <td>unknown</td> | |
451 | <td>Foo Bar <foo.bar@example.com></td> |
|
666 | <td>Foo Bar <foo.bar@example.com></td> | |
452 | <td class="age">*</td> (glob) |
|
667 | <td class="age">*</td> (glob) | |
453 | <td class="indexlinks"></td> |
|
668 | <td class="indexlinks"></td> | |
454 | <td> |
|
669 | <td> | |
455 | <a href="/rcoll/notrepo/f/f2/atom-log" title="subscribe to repository atom feed"> |
|
670 | <a href="/rcoll/notrepo/f/f2/atom-log" title="subscribe to repository atom feed"> | |
456 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
671 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
457 | </a> |
|
672 | </a> | |
458 | </td> |
|
673 | </td> | |
459 | </tr> |
|
674 | </tr> | |
460 |
|
675 | |||
461 | <tr> |
|
676 | <tr> | |
462 | <td><a href="/star/webdir/a/?style=paper">star/webdir/a</a></td> |
|
677 | <td><a href="/star/webdir/a/?style=paper">star/webdir/a</a></td> | |
463 | <td>unknown</td> |
|
678 | <td>unknown</td> | |
464 | <td>Foo Bar <foo.bar@example.com></td> |
|
679 | <td>Foo Bar <foo.bar@example.com></td> | |
465 | <td class="age">*</td> (glob) |
|
680 | <td class="age">*</td> (glob) | |
466 | <td class="indexlinks"></td> |
|
681 | <td class="indexlinks"></td> | |
467 | <td> |
|
682 | <td> | |
468 | <a href="/star/webdir/a/atom-log" title="subscribe to repository atom feed"> |
|
683 | <a href="/star/webdir/a/atom-log" title="subscribe to repository atom feed"> | |
469 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
684 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
470 | </a> |
|
685 | </a> | |
471 | </td> |
|
686 | </td> | |
472 | </tr> |
|
687 | </tr> | |
473 |
|
688 | |||
474 | <tr> |
|
689 | <tr> | |
475 | <td><a href="/star/webdir/a/.hg/patches/?style=paper">star/webdir/a/.hg/patches</a></td> |
|
690 | <td><a href="/star/webdir/a/.hg/patches/?style=paper">star/webdir/a/.hg/patches</a></td> | |
476 | <td>unknown</td> |
|
691 | <td>unknown</td> | |
477 | <td>Foo Bar <foo.bar@example.com></td> |
|
692 | <td>Foo Bar <foo.bar@example.com></td> | |
478 | <td class="age">*</td> (glob) |
|
693 | <td class="age">*</td> (glob) | |
479 | <td class="indexlinks"></td> |
|
694 | <td class="indexlinks"></td> | |
480 | <td> |
|
695 | <td> | |
481 | <a href="/star/webdir/a/.hg/patches/atom-log" title="subscribe to repository atom feed"> |
|
696 | <a href="/star/webdir/a/.hg/patches/atom-log" title="subscribe to repository atom feed"> | |
482 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
697 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
483 | </a> |
|
698 | </a> | |
484 | </td> |
|
699 | </td> | |
485 | </tr> |
|
700 | </tr> | |
486 |
|
701 | |||
487 | <tr> |
|
702 | <tr> | |
488 | <td><a href="/star/webdir/b/?style=paper">star/webdir/b</a></td> |
|
703 | <td><a href="/star/webdir/b/?style=paper">star/webdir/b</a></td> | |
489 | <td>unknown</td> |
|
704 | <td>unknown</td> | |
490 | <td>Foo Bar <foo.bar@example.com></td> |
|
705 | <td>Foo Bar <foo.bar@example.com></td> | |
491 | <td class="age">*</td> (glob) |
|
706 | <td class="age">*</td> (glob) | |
492 | <td class="indexlinks"></td> |
|
707 | <td class="indexlinks"></td> | |
493 | <td> |
|
708 | <td> | |
494 | <a href="/star/webdir/b/atom-log" title="subscribe to repository atom feed"> |
|
709 | <a href="/star/webdir/b/atom-log" title="subscribe to repository atom feed"> | |
495 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
710 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
496 | </a> |
|
711 | </a> | |
497 | </td> |
|
712 | </td> | |
498 | </tr> |
|
713 | </tr> | |
499 |
|
714 | |||
500 | <tr> |
|
715 | <tr> | |
501 | <td><a href="/star/webdir/c/?style=paper">star/webdir/c</a></td> |
|
716 | <td><a href="/star/webdir/c/?style=paper">star/webdir/c</a></td> | |
502 | <td>unknown</td> |
|
717 | <td>unknown</td> | |
503 | <td>Foo Bar <foo.bar@example.com></td> |
|
718 | <td>Foo Bar <foo.bar@example.com></td> | |
504 | <td class="age">*</td> (glob) |
|
719 | <td class="age">*</td> (glob) | |
505 | <td class="indexlinks"></td> |
|
720 | <td class="indexlinks"></td> | |
506 | <td> |
|
721 | <td> | |
507 | <a href="/star/webdir/c/atom-log" title="subscribe to repository atom feed"> |
|
722 | <a href="/star/webdir/c/atom-log" title="subscribe to repository atom feed"> | |
508 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
723 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
509 | </a> |
|
724 | </a> | |
510 | </td> |
|
725 | </td> | |
511 | </tr> |
|
726 | </tr> | |
512 |
|
727 | |||
513 | <tr> |
|
728 | <tr> | |
514 | <td><a href="/star/webdir/notrepo/e/?style=paper">star/webdir/notrepo/e</a></td> |
|
729 | <td><a href="/star/webdir/notrepo/e/?style=paper">star/webdir/notrepo/e</a></td> | |
515 | <td>unknown</td> |
|
730 | <td>unknown</td> | |
516 | <td>Foo Bar <foo.bar@example.com></td> |
|
731 | <td>Foo Bar <foo.bar@example.com></td> | |
517 | <td class="age">*</td> (glob) |
|
732 | <td class="age">*</td> (glob) | |
518 | <td class="indexlinks"></td> |
|
733 | <td class="indexlinks"></td> | |
519 | <td> |
|
734 | <td> | |
520 | <a href="/star/webdir/notrepo/e/atom-log" title="subscribe to repository atom feed"> |
|
735 | <a href="/star/webdir/notrepo/e/atom-log" title="subscribe to repository atom feed"> | |
521 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
736 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
522 | </a> |
|
737 | </a> | |
523 | </td> |
|
738 | </td> | |
524 | </tr> |
|
739 | </tr> | |
525 |
|
740 | |||
526 | <tr> |
|
741 | <tr> | |
527 | <td><a href="/star/webdir/notrepo/f/?style=paper">fancy name for repo f</a></td> |
|
742 | <td><a href="/star/webdir/notrepo/f/?style=paper">fancy name for repo f</a></td> | |
528 | <td>unknown</td> |
|
743 | <td>unknown</td> | |
529 | <td>Foo Bar <foo.bar@example.com></td> |
|
744 | <td>Foo Bar <foo.bar@example.com></td> | |
530 | <td class="age">*</td> (glob) |
|
745 | <td class="age">*</td> (glob) | |
531 | <td class="indexlinks"></td> |
|
746 | <td class="indexlinks"></td> | |
532 | <td> |
|
747 | <td> | |
533 | <a href="/star/webdir/notrepo/f/atom-log" title="subscribe to repository atom feed"> |
|
748 | <a href="/star/webdir/notrepo/f/atom-log" title="subscribe to repository atom feed"> | |
534 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
749 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
535 | </a> |
|
750 | </a> | |
536 | </td> |
|
751 | </td> | |
537 | </tr> |
|
752 | </tr> | |
538 |
|
753 | |||
539 | <tr> |
|
754 | <tr> | |
540 | <td><a href="/starstar/webdir/a/?style=paper">starstar/webdir/a</a></td> |
|
755 | <td><a href="/starstar/webdir/a/?style=paper">starstar/webdir/a</a></td> | |
541 | <td>unknown</td> |
|
756 | <td>unknown</td> | |
542 | <td>Foo Bar <foo.bar@example.com></td> |
|
757 | <td>Foo Bar <foo.bar@example.com></td> | |
543 | <td class="age">*</td> (glob) |
|
758 | <td class="age">*</td> (glob) | |
544 | <td class="indexlinks"></td> |
|
759 | <td class="indexlinks"></td> | |
545 | <td> |
|
760 | <td> | |
546 | <a href="/starstar/webdir/a/atom-log" title="subscribe to repository atom feed"> |
|
761 | <a href="/starstar/webdir/a/atom-log" title="subscribe to repository atom feed"> | |
547 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
762 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
548 | </a> |
|
763 | </a> | |
549 | </td> |
|
764 | </td> | |
550 | </tr> |
|
765 | </tr> | |
551 |
|
766 | |||
552 | <tr> |
|
767 | <tr> | |
553 | <td><a href="/starstar/webdir/a/.hg/patches/?style=paper">starstar/webdir/a/.hg/patches</a></td> |
|
768 | <td><a href="/starstar/webdir/a/.hg/patches/?style=paper">starstar/webdir/a/.hg/patches</a></td> | |
554 | <td>unknown</td> |
|
769 | <td>unknown</td> | |
555 | <td>Foo Bar <foo.bar@example.com></td> |
|
770 | <td>Foo Bar <foo.bar@example.com></td> | |
556 | <td class="age">*</td> (glob) |
|
771 | <td class="age">*</td> (glob) | |
557 | <td class="indexlinks"></td> |
|
772 | <td class="indexlinks"></td> | |
558 | <td> |
|
773 | <td> | |
559 | <a href="/starstar/webdir/a/.hg/patches/atom-log" title="subscribe to repository atom feed"> |
|
774 | <a href="/starstar/webdir/a/.hg/patches/atom-log" title="subscribe to repository atom feed"> | |
560 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
775 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
561 | </a> |
|
776 | </a> | |
562 | </td> |
|
777 | </td> | |
563 | </tr> |
|
778 | </tr> | |
564 |
|
779 | |||
565 | <tr> |
|
780 | <tr> | |
566 | <td><a href="/starstar/webdir/b/?style=paper">starstar/webdir/b</a></td> |
|
781 | <td><a href="/starstar/webdir/b/?style=paper">starstar/webdir/b</a></td> | |
567 | <td>unknown</td> |
|
782 | <td>unknown</td> | |
568 | <td>Foo Bar <foo.bar@example.com></td> |
|
783 | <td>Foo Bar <foo.bar@example.com></td> | |
569 | <td class="age">*</td> (glob) |
|
784 | <td class="age">*</td> (glob) | |
570 | <td class="indexlinks"></td> |
|
785 | <td class="indexlinks"></td> | |
571 | <td> |
|
786 | <td> | |
572 | <a href="/starstar/webdir/b/atom-log" title="subscribe to repository atom feed"> |
|
787 | <a href="/starstar/webdir/b/atom-log" title="subscribe to repository atom feed"> | |
573 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
788 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
574 | </a> |
|
789 | </a> | |
575 | </td> |
|
790 | </td> | |
576 | </tr> |
|
791 | </tr> | |
577 |
|
792 | |||
578 | <tr> |
|
793 | <tr> | |
579 | <td><a href="/starstar/webdir/b/d/?style=paper">starstar/webdir/b/d</a></td> |
|
794 | <td><a href="/starstar/webdir/b/d/?style=paper">starstar/webdir/b/d</a></td> | |
580 | <td>unknown</td> |
|
795 | <td>unknown</td> | |
581 | <td>Foo Bar <foo.bar@example.com></td> |
|
796 | <td>Foo Bar <foo.bar@example.com></td> | |
582 | <td class="age">*</td> (glob) |
|
797 | <td class="age">*</td> (glob) | |
583 | <td class="indexlinks"></td> |
|
798 | <td class="indexlinks"></td> | |
584 | <td> |
|
799 | <td> | |
585 | <a href="/starstar/webdir/b/d/atom-log" title="subscribe to repository atom feed"> |
|
800 | <a href="/starstar/webdir/b/d/atom-log" title="subscribe to repository atom feed"> | |
586 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
801 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
587 | </a> |
|
802 | </a> | |
588 | </td> |
|
803 | </td> | |
589 | </tr> |
|
804 | </tr> | |
590 |
|
805 | |||
591 | <tr> |
|
806 | <tr> | |
592 | <td><a href="/starstar/webdir/c/?style=paper">starstar/webdir/c</a></td> |
|
807 | <td><a href="/starstar/webdir/c/?style=paper">starstar/webdir/c</a></td> | |
593 | <td>unknown</td> |
|
808 | <td>unknown</td> | |
594 | <td>Foo Bar <foo.bar@example.com></td> |
|
809 | <td>Foo Bar <foo.bar@example.com></td> | |
595 | <td class="age">*</td> (glob) |
|
810 | <td class="age">*</td> (glob) | |
596 | <td class="indexlinks"></td> |
|
811 | <td class="indexlinks"></td> | |
597 | <td> |
|
812 | <td> | |
598 | <a href="/starstar/webdir/c/atom-log" title="subscribe to repository atom feed"> |
|
813 | <a href="/starstar/webdir/c/atom-log" title="subscribe to repository atom feed"> | |
599 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
814 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
600 | </a> |
|
815 | </a> | |
601 | </td> |
|
816 | </td> | |
602 | </tr> |
|
817 | </tr> | |
603 |
|
818 | |||
604 | <tr> |
|
819 | <tr> | |
605 | <td><a href="/starstar/webdir/notrepo/e/?style=paper">starstar/webdir/notrepo/e</a></td> |
|
820 | <td><a href="/starstar/webdir/notrepo/e/?style=paper">starstar/webdir/notrepo/e</a></td> | |
606 | <td>unknown</td> |
|
821 | <td>unknown</td> | |
607 | <td>Foo Bar <foo.bar@example.com></td> |
|
822 | <td>Foo Bar <foo.bar@example.com></td> | |
608 | <td class="age">*</td> (glob) |
|
823 | <td class="age">*</td> (glob) | |
609 | <td class="indexlinks"></td> |
|
824 | <td class="indexlinks"></td> | |
610 | <td> |
|
825 | <td> | |
611 | <a href="/starstar/webdir/notrepo/e/atom-log" title="subscribe to repository atom feed"> |
|
826 | <a href="/starstar/webdir/notrepo/e/atom-log" title="subscribe to repository atom feed"> | |
612 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
827 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
613 | </a> |
|
828 | </a> | |
614 | </td> |
|
829 | </td> | |
615 | </tr> |
|
830 | </tr> | |
616 |
|
831 | |||
617 | <tr> |
|
832 | <tr> | |
618 | <td><a href="/starstar/webdir/notrepo/e/e2/?style=paper">starstar/webdir/notrepo/e/e2</a></td> |
|
833 | <td><a href="/starstar/webdir/notrepo/e/e2/?style=paper">starstar/webdir/notrepo/e/e2</a></td> | |
619 | <td>unknown</td> |
|
834 | <td>unknown</td> | |
620 | <td>Foo Bar <foo.bar@example.com></td> |
|
835 | <td>Foo Bar <foo.bar@example.com></td> | |
621 | <td class="age">*</td> (glob) |
|
836 | <td class="age">*</td> (glob) | |
622 | <td class="indexlinks"></td> |
|
837 | <td class="indexlinks"></td> | |
623 | <td> |
|
838 | <td> | |
624 | <a href="/starstar/webdir/notrepo/e/e2/atom-log" title="subscribe to repository atom feed"> |
|
839 | <a href="/starstar/webdir/notrepo/e/e2/atom-log" title="subscribe to repository atom feed"> | |
625 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
840 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
626 | </a> |
|
841 | </a> | |
627 | </td> |
|
842 | </td> | |
628 | </tr> |
|
843 | </tr> | |
629 |
|
844 | |||
630 | <tr> |
|
845 | <tr> | |
631 | <td><a href="/starstar/webdir/notrepo/f/?style=paper">fancy name for repo f</a></td> |
|
846 | <td><a href="/starstar/webdir/notrepo/f/?style=paper">fancy name for repo f</a></td> | |
632 | <td>unknown</td> |
|
847 | <td>unknown</td> | |
633 | <td>Foo Bar <foo.bar@example.com></td> |
|
848 | <td>Foo Bar <foo.bar@example.com></td> | |
634 | <td class="age">*</td> (glob) |
|
849 | <td class="age">*</td> (glob) | |
635 | <td class="indexlinks"></td> |
|
850 | <td class="indexlinks"></td> | |
636 | <td> |
|
851 | <td> | |
637 | <a href="/starstar/webdir/notrepo/f/atom-log" title="subscribe to repository atom feed"> |
|
852 | <a href="/starstar/webdir/notrepo/f/atom-log" title="subscribe to repository atom feed"> | |
638 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
853 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
639 | </a> |
|
854 | </a> | |
640 | </td> |
|
855 | </td> | |
641 | </tr> |
|
856 | </tr> | |
642 |
|
857 | |||
643 | <tr> |
|
858 | <tr> | |
644 | <td><a href="/starstar/webdir/notrepo/f/f2/?style=paper">starstar/webdir/notrepo/f/f2</a></td> |
|
859 | <td><a href="/starstar/webdir/notrepo/f/f2/?style=paper">starstar/webdir/notrepo/f/f2</a></td> | |
645 | <td>unknown</td> |
|
860 | <td>unknown</td> | |
646 | <td>Foo Bar <foo.bar@example.com></td> |
|
861 | <td>Foo Bar <foo.bar@example.com></td> | |
647 | <td class="age">*</td> (glob) |
|
862 | <td class="age">*</td> (glob) | |
648 | <td class="indexlinks"></td> |
|
863 | <td class="indexlinks"></td> | |
649 | <td> |
|
864 | <td> | |
650 | <a href="/starstar/webdir/notrepo/f/f2/atom-log" title="subscribe to repository atom feed"> |
|
865 | <a href="/starstar/webdir/notrepo/f/f2/atom-log" title="subscribe to repository atom feed"> | |
651 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
866 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
652 | </a> |
|
867 | </a> | |
653 | </td> |
|
868 | </td> | |
654 | </tr> |
|
869 | </tr> | |
655 |
|
870 | |||
656 | <tr> |
|
871 | <tr> | |
657 | <td><a href="/astar/?style=paper">astar</a></td> |
|
872 | <td><a href="/astar/?style=paper">astar</a></td> | |
658 | <td>unknown</td> |
|
873 | <td>unknown</td> | |
659 | <td>Foo Bar <foo.bar@example.com></td> |
|
874 | <td>Foo Bar <foo.bar@example.com></td> | |
660 | <td class="age">*</td> (glob) |
|
875 | <td class="age">*</td> (glob) | |
661 | <td class="indexlinks"></td> |
|
876 | <td class="indexlinks"></td> | |
662 | <td> |
|
877 | <td> | |
663 | <a href="/astar/atom-log" title="subscribe to repository atom feed"> |
|
878 | <a href="/astar/atom-log" title="subscribe to repository atom feed"> | |
664 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
879 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
665 | </a> |
|
880 | </a> | |
666 | </td> |
|
881 | </td> | |
667 | </tr> |
|
882 | </tr> | |
668 |
|
883 | |||
669 | <tr> |
|
884 | <tr> | |
670 | <td><a href="/astar/.hg/patches/?style=paper">astar/.hg/patches</a></td> |
|
885 | <td><a href="/astar/.hg/patches/?style=paper">astar/.hg/patches</a></td> | |
671 | <td>unknown</td> |
|
886 | <td>unknown</td> | |
672 | <td>Foo Bar <foo.bar@example.com></td> |
|
887 | <td>Foo Bar <foo.bar@example.com></td> | |
673 | <td class="age">*</td> (glob) |
|
888 | <td class="age">*</td> (glob) | |
674 | <td class="indexlinks"></td> |
|
889 | <td class="indexlinks"></td> | |
675 | <td> |
|
890 | <td> | |
676 | <a href="/astar/.hg/patches/atom-log" title="subscribe to repository atom feed"> |
|
891 | <a href="/astar/.hg/patches/atom-log" title="subscribe to repository atom feed"> | |
677 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
892 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
678 | </a> |
|
893 | </a> | |
679 | </td> |
|
894 | </td> | |
680 | </tr> |
|
895 | </tr> | |
681 |
|
896 | |||
682 | </tbody> |
|
897 | </tbody> | |
683 | </table> |
|
898 | </table> | |
684 | </div> |
|
899 | </div> | |
685 | </div> |
|
900 | </div> | |
686 | <script type="text/javascript">process_dates()</script> |
|
901 | <script type="text/javascript">process_dates()</script> | |
687 |
|
902 | |||
688 |
|
903 | |||
689 | </body> |
|
904 | </body> | |
690 | </html> |
|
905 | </html> | |
691 |
|
906 | |||
692 | $ get-with-headers.py localhost:$HGPORT1 't?style=raw' |
|
907 | $ get-with-headers.py localhost:$HGPORT1 't?style=raw' | |
693 | 200 Script output follows |
|
908 | 200 Script output follows | |
694 |
|
909 | |||
695 |
|
910 | |||
696 | /t/a/ |
|
911 | /t/a/ | |
697 |
|
912 | |||
698 | $ get-with-headers.py localhost:$HGPORT1 't/?style=raw' |
|
913 | $ get-with-headers.py localhost:$HGPORT1 't/?style=raw' | |
699 | 200 Script output follows |
|
914 | 200 Script output follows | |
700 |
|
915 | |||
701 |
|
916 | |||
702 | /t/a/ |
|
917 | /t/a/ | |
703 |
|
918 | |||
704 | $ get-with-headers.py localhost:$HGPORT1 't/?style=paper' |
|
919 | $ get-with-headers.py localhost:$HGPORT1 't/?style=paper' | |
705 | 200 Script output follows |
|
920 | 200 Script output follows | |
706 |
|
921 | |||
707 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> |
|
922 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> | |
708 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US"> |
|
923 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US"> | |
709 | <head> |
|
924 | <head> | |
710 | <link rel="icon" href="/static/hgicon.png" type="image/png" /> |
|
925 | <link rel="icon" href="/static/hgicon.png" type="image/png" /> | |
711 | <meta name="robots" content="index, nofollow" /> |
|
926 | <meta name="robots" content="index, nofollow" /> | |
712 | <link rel="stylesheet" href="/static/style-paper.css" type="text/css" /> |
|
927 | <link rel="stylesheet" href="/static/style-paper.css" type="text/css" /> | |
713 | <script type="text/javascript" src="/static/mercurial.js"></script> |
|
928 | <script type="text/javascript" src="/static/mercurial.js"></script> | |
714 |
|
929 | |||
715 | <title>Mercurial repositories index</title> |
|
930 | <title>Mercurial repositories index</title> | |
716 | </head> |
|
931 | </head> | |
717 | <body> |
|
932 | <body> | |
718 |
|
933 | |||
719 | <div class="container"> |
|
934 | <div class="container"> | |
720 | <div class="menu"> |
|
935 | <div class="menu"> | |
721 | <a href="https://mercurial-scm.org/"> |
|
936 | <a href="https://mercurial-scm.org/"> | |
722 | <img src="/static/hglogo.png" width=75 height=90 border=0 alt="mercurial" /></a> |
|
937 | <img src="/static/hglogo.png" width=75 height=90 border=0 alt="mercurial" /></a> | |
723 | </div> |
|
938 | </div> | |
724 | <div class="main"> |
|
939 | <div class="main"> | |
725 | <h2 class="breadcrumb"><a href="/">Mercurial</a> > <a href="/t">t</a> </h2> |
|
940 | <h2 class="breadcrumb"><a href="/">Mercurial</a> > <a href="/t">t</a> </h2> | |
726 |
|
941 | |||
727 | <table class="bigtable"> |
|
942 | <table class="bigtable"> | |
728 | <thead> |
|
943 | <thead> | |
729 | <tr> |
|
944 | <tr> | |
730 | <th><a href="?sort=name">Name</a></th> |
|
945 | <th><a href="?sort=name">Name</a></th> | |
731 | <th><a href="?sort=description">Description</a></th> |
|
946 | <th><a href="?sort=description">Description</a></th> | |
732 | <th><a href="?sort=contact">Contact</a></th> |
|
947 | <th><a href="?sort=contact">Contact</a></th> | |
733 | <th><a href="?sort=lastchange">Last modified</a></th> |
|
948 | <th><a href="?sort=lastchange">Last modified</a></th> | |
734 | <th> </th> |
|
949 | <th> </th> | |
735 | <th> </th> |
|
950 | <th> </th> | |
736 | </tr> |
|
951 | </tr> | |
737 | </thead> |
|
952 | </thead> | |
738 | <tbody class="stripes2"> |
|
953 | <tbody class="stripes2"> | |
739 |
|
954 | |||
740 | <tr> |
|
955 | <tr> | |
741 | <td><a href="/t/a/?style=paper">a</a></td> |
|
956 | <td><a href="/t/a/?style=paper">a</a></td> | |
742 | <td>unknown</td> |
|
957 | <td>unknown</td> | |
743 | <td>Foo Bar <foo.bar@example.com></td> |
|
958 | <td>Foo Bar <foo.bar@example.com></td> | |
744 | <td class="age">*</td> (glob) |
|
959 | <td class="age">*</td> (glob) | |
745 | <td class="indexlinks"></td> |
|
960 | <td class="indexlinks"></td> | |
746 | <td> |
|
961 | <td> | |
747 | <a href="/t/a/atom-log" title="subscribe to repository atom feed"> |
|
962 | <a href="/t/a/atom-log" title="subscribe to repository atom feed"> | |
748 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> |
|
963 | <img class="atom-logo" src="/static/feed-icon-14x14.png" alt="subscribe to repository atom feed"> | |
749 | </a> |
|
964 | </a> | |
750 | </td> |
|
965 | </td> | |
751 | </tr> |
|
966 | </tr> | |
752 |
|
967 | |||
753 | </tbody> |
|
968 | </tbody> | |
754 | </table> |
|
969 | </table> | |
755 | </div> |
|
970 | </div> | |
756 | </div> |
|
971 | </div> | |
757 | <script type="text/javascript">process_dates()</script> |
|
972 | <script type="text/javascript">process_dates()</script> | |
758 |
|
973 | |||
759 |
|
974 | |||
760 | </body> |
|
975 | </body> | |
761 | </html> |
|
976 | </html> | |
762 |
|
977 | |||
763 | $ get-with-headers.py localhost:$HGPORT1 't/a?style=atom' |
|
978 | $ get-with-headers.py localhost:$HGPORT1 't/a?style=atom' | |
764 | 200 Script output follows |
|
979 | 200 Script output follows | |
765 |
|
980 | |||
766 | <?xml version="1.0" encoding="ascii"?> |
|
981 | <?xml version="1.0" encoding="ascii"?> | |
767 | <feed xmlns="http://www.w3.org/2005/Atom"> |
|
982 | <feed xmlns="http://www.w3.org/2005/Atom"> | |
768 | <!-- Changelog --> |
|
983 | <!-- Changelog --> | |
769 | <id>http://*:$HGPORT1/t/a/</id> (glob) |
|
984 | <id>http://*:$HGPORT1/t/a/</id> (glob) | |
770 | <link rel="self" href="http://*:$HGPORT1/t/a/atom-log"/> (glob) |
|
985 | <link rel="self" href="http://*:$HGPORT1/t/a/atom-log"/> (glob) | |
771 | <link rel="alternate" href="http://*:$HGPORT1/t/a/"/> (glob) |
|
986 | <link rel="alternate" href="http://*:$HGPORT1/t/a/"/> (glob) | |
772 | <title>t/a Changelog</title> |
|
987 | <title>t/a Changelog</title> | |
773 | <updated>1970-01-01T00:00:01+00:00</updated> |
|
988 | <updated>1970-01-01T00:00:01+00:00</updated> | |
774 |
|
989 | |||
775 | <entry> |
|
990 | <entry> | |
776 | <title>[default] a</title> |
|
991 | <title>[default] a</title> | |
777 | <id>http://*:$HGPORT1/t/a/#changeset-8580ff50825a50c8f716709acdf8de0deddcd6ab</id> (glob) |
|
992 | <id>http://*:$HGPORT1/t/a/#changeset-8580ff50825a50c8f716709acdf8de0deddcd6ab</id> (glob) | |
778 | <link href="http://*:$HGPORT1/t/a/rev/8580ff50825a"/> (glob) |
|
993 | <link href="http://*:$HGPORT1/t/a/rev/8580ff50825a"/> (glob) | |
779 | <author> |
|
994 | <author> | |
780 | <name>test</name> |
|
995 | <name>test</name> | |
781 | <email>test</email> |
|
996 | <email>test</email> | |
782 | </author> |
|
997 | </author> | |
783 | <updated>1970-01-01T00:00:01+00:00</updated> |
|
998 | <updated>1970-01-01T00:00:01+00:00</updated> | |
784 | <published>1970-01-01T00:00:01+00:00</published> |
|
999 | <published>1970-01-01T00:00:01+00:00</published> | |
785 | <content type="xhtml"> |
|
1000 | <content type="xhtml"> | |
786 | <table xmlns="http://www.w3.org/1999/xhtml"> |
|
1001 | <table xmlns="http://www.w3.org/1999/xhtml"> | |
787 | <tr> |
|
1002 | <tr> | |
788 | <th style="text-align:left;">changeset</th> |
|
1003 | <th style="text-align:left;">changeset</th> | |
789 | <td>8580ff50825a</td> |
|
1004 | <td>8580ff50825a</td> | |
790 | </tr> |
|
1005 | </tr> | |
791 | <tr> |
|
1006 | <tr> | |
792 | <th style="text-align:left;">branch</th> |
|
1007 | <th style="text-align:left;">branch</th> | |
793 | <td>default</td> |
|
1008 | <td>default</td> | |
794 | </tr> |
|
1009 | </tr> | |
795 | <tr> |
|
1010 | <tr> | |
796 | <th style="text-align:left;">bookmark</th> |
|
1011 | <th style="text-align:left;">bookmark</th> | |
797 | <td></td> |
|
1012 | <td></td> | |
798 | </tr> |
|
1013 | </tr> | |
799 | <tr> |
|
1014 | <tr> | |
800 | <th style="text-align:left;">tag</th> |
|
1015 | <th style="text-align:left;">tag</th> | |
801 | <td>tip</td> |
|
1016 | <td>tip</td> | |
802 | </tr> |
|
1017 | </tr> | |
803 | <tr> |
|
1018 | <tr> | |
804 | <th style="text-align:left;">user</th> |
|
1019 | <th style="text-align:left;">user</th> | |
805 | <td>test</td> |
|
1020 | <td>test</td> | |
806 | </tr> |
|
1021 | </tr> | |
807 | <tr> |
|
1022 | <tr> | |
808 | <th style="text-align:left;vertical-align:top;">description</th> |
|
1023 | <th style="text-align:left;vertical-align:top;">description</th> | |
809 | <td>a</td> |
|
1024 | <td>a</td> | |
810 | </tr> |
|
1025 | </tr> | |
811 | <tr> |
|
1026 | <tr> | |
812 | <th style="text-align:left;vertical-align:top;">files</th> |
|
1027 | <th style="text-align:left;vertical-align:top;">files</th> | |
813 | <td>a<br /></td> |
|
1028 | <td>a<br /></td> | |
814 | </tr> |
|
1029 | </tr> | |
815 | </table> |
|
1030 | </table> | |
816 | </content> |
|
1031 | </content> | |
817 | </entry> |
|
1032 | </entry> | |
818 |
|
1033 | |||
819 | </feed> |
|
1034 | </feed> | |
820 | $ get-with-headers.py localhost:$HGPORT1 't/a/?style=atom' |
|
1035 | $ get-with-headers.py localhost:$HGPORT1 't/a/?style=atom' | |
821 | 200 Script output follows |
|
1036 | 200 Script output follows | |
822 |
|
1037 | |||
823 | <?xml version="1.0" encoding="ascii"?> |
|
1038 | <?xml version="1.0" encoding="ascii"?> | |
824 | <feed xmlns="http://www.w3.org/2005/Atom"> |
|
1039 | <feed xmlns="http://www.w3.org/2005/Atom"> | |
825 | <!-- Changelog --> |
|
1040 | <!-- Changelog --> | |
826 | <id>http://*:$HGPORT1/t/a/</id> (glob) |
|
1041 | <id>http://*:$HGPORT1/t/a/</id> (glob) | |
827 | <link rel="self" href="http://*:$HGPORT1/t/a/atom-log"/> (glob) |
|
1042 | <link rel="self" href="http://*:$HGPORT1/t/a/atom-log"/> (glob) | |
828 | <link rel="alternate" href="http://*:$HGPORT1/t/a/"/> (glob) |
|
1043 | <link rel="alternate" href="http://*:$HGPORT1/t/a/"/> (glob) | |
829 | <title>t/a Changelog</title> |
|
1044 | <title>t/a Changelog</title> | |
830 | <updated>1970-01-01T00:00:01+00:00</updated> |
|
1045 | <updated>1970-01-01T00:00:01+00:00</updated> | |
831 |
|
1046 | |||
832 | <entry> |
|
1047 | <entry> | |
833 | <title>[default] a</title> |
|
1048 | <title>[default] a</title> | |
834 | <id>http://*:$HGPORT1/t/a/#changeset-8580ff50825a50c8f716709acdf8de0deddcd6ab</id> (glob) |
|
1049 | <id>http://*:$HGPORT1/t/a/#changeset-8580ff50825a50c8f716709acdf8de0deddcd6ab</id> (glob) | |
835 | <link href="http://*:$HGPORT1/t/a/rev/8580ff50825a"/> (glob) |
|
1050 | <link href="http://*:$HGPORT1/t/a/rev/8580ff50825a"/> (glob) | |
836 | <author> |
|
1051 | <author> | |
837 | <name>test</name> |
|
1052 | <name>test</name> | |
838 | <email>test</email> |
|
1053 | <email>test</email> | |
839 | </author> |
|
1054 | </author> | |
840 | <updated>1970-01-01T00:00:01+00:00</updated> |
|
1055 | <updated>1970-01-01T00:00:01+00:00</updated> | |
841 | <published>1970-01-01T00:00:01+00:00</published> |
|
1056 | <published>1970-01-01T00:00:01+00:00</published> | |
842 | <content type="xhtml"> |
|
1057 | <content type="xhtml"> | |
843 | <table xmlns="http://www.w3.org/1999/xhtml"> |
|
1058 | <table xmlns="http://www.w3.org/1999/xhtml"> | |
844 | <tr> |
|
1059 | <tr> | |
845 | <th style="text-align:left;">changeset</th> |
|
1060 | <th style="text-align:left;">changeset</th> | |
846 | <td>8580ff50825a</td> |
|
1061 | <td>8580ff50825a</td> | |
847 | </tr> |
|
1062 | </tr> | |
848 | <tr> |
|
1063 | <tr> | |
849 | <th style="text-align:left;">branch</th> |
|
1064 | <th style="text-align:left;">branch</th> | |
850 | <td>default</td> |
|
1065 | <td>default</td> | |
851 | </tr> |
|
1066 | </tr> | |
852 | <tr> |
|
1067 | <tr> | |
853 | <th style="text-align:left;">bookmark</th> |
|
1068 | <th style="text-align:left;">bookmark</th> | |
854 | <td></td> |
|
1069 | <td></td> | |
855 | </tr> |
|
1070 | </tr> | |
856 | <tr> |
|
1071 | <tr> | |
857 | <th style="text-align:left;">tag</th> |
|
1072 | <th style="text-align:left;">tag</th> | |
858 | <td>tip</td> |
|
1073 | <td>tip</td> | |
859 | </tr> |
|
1074 | </tr> | |
860 | <tr> |
|
1075 | <tr> | |
861 | <th style="text-align:left;">user</th> |
|
1076 | <th style="text-align:left;">user</th> | |
862 | <td>test</td> |
|
1077 | <td>test</td> | |
863 | </tr> |
|
1078 | </tr> | |
864 | <tr> |
|
1079 | <tr> | |
865 | <th style="text-align:left;vertical-align:top;">description</th> |
|
1080 | <th style="text-align:left;vertical-align:top;">description</th> | |
866 | <td>a</td> |
|
1081 | <td>a</td> | |
867 | </tr> |
|
1082 | </tr> | |
868 | <tr> |
|
1083 | <tr> | |
869 | <th style="text-align:left;vertical-align:top;">files</th> |
|
1084 | <th style="text-align:left;vertical-align:top;">files</th> | |
870 | <td>a<br /></td> |
|
1085 | <td>a<br /></td> | |
871 | </tr> |
|
1086 | </tr> | |
872 | </table> |
|
1087 | </table> | |
873 | </content> |
|
1088 | </content> | |
874 | </entry> |
|
1089 | </entry> | |
875 |
|
1090 | |||
876 | </feed> |
|
1091 | </feed> | |
877 | $ get-with-headers.py localhost:$HGPORT1 't/a/file/tip/a?style=raw' |
|
1092 | $ get-with-headers.py localhost:$HGPORT1 't/a/file/tip/a?style=raw' | |
878 | 200 Script output follows |
|
1093 | 200 Script output follows | |
879 |
|
1094 | |||
880 | a |
|
1095 | a | |
881 |
|
1096 | |||
882 | Test [paths] '*' extension |
|
1097 | Test [paths] '*' extension | |
883 |
|
1098 | |||
884 | $ get-with-headers.py localhost:$HGPORT1 'coll/?style=raw' |
|
1099 | $ get-with-headers.py localhost:$HGPORT1 'coll/?style=raw' | |
885 | 200 Script output follows |
|
1100 | 200 Script output follows | |
886 |
|
1101 | |||
887 |
|
1102 | |||
888 | /coll/a/ |
|
1103 | /coll/a/ | |
889 | /coll/a/.hg/patches/ |
|
1104 | /coll/a/.hg/patches/ | |
890 | /coll/b/ |
|
1105 | /coll/b/ | |
891 | /coll/c/ |
|
1106 | /coll/c/ | |
892 | /coll/notrepo/e/ |
|
1107 | /coll/notrepo/e/ | |
893 | /coll/notrepo/f/ |
|
1108 | /coll/notrepo/f/ | |
894 |
|
1109 | |||
895 | $ get-with-headers.py localhost:$HGPORT1 'coll/a/file/tip/a?style=raw' |
|
1110 | $ get-with-headers.py localhost:$HGPORT1 'coll/a/file/tip/a?style=raw' | |
896 | 200 Script output follows |
|
1111 | 200 Script output follows | |
897 |
|
1112 | |||
898 | a |
|
1113 | a | |
899 |
|
1114 | |||
900 | Test [paths] '**' extension |
|
1115 | Test [paths] '**' extension | |
901 |
|
1116 | |||
902 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/?style=raw' |
|
1117 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/?style=raw' | |
903 | 200 Script output follows |
|
1118 | 200 Script output follows | |
904 |
|
1119 | |||
905 |
|
1120 | |||
906 | /rcoll/a/ |
|
1121 | /rcoll/a/ | |
907 | /rcoll/a/.hg/patches/ |
|
1122 | /rcoll/a/.hg/patches/ | |
908 | /rcoll/b/ |
|
1123 | /rcoll/b/ | |
909 | /rcoll/b/d/ |
|
1124 | /rcoll/b/d/ | |
910 | /rcoll/c/ |
|
1125 | /rcoll/c/ | |
911 | /rcoll/notrepo/e/ |
|
1126 | /rcoll/notrepo/e/ | |
912 | /rcoll/notrepo/e/e2/ |
|
1127 | /rcoll/notrepo/e/e2/ | |
913 | /rcoll/notrepo/f/ |
|
1128 | /rcoll/notrepo/f/ | |
914 | /rcoll/notrepo/f/f2/ |
|
1129 | /rcoll/notrepo/f/f2/ | |
915 |
|
1130 | |||
916 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/b/d/file/tip/d?style=raw' |
|
1131 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/b/d/file/tip/d?style=raw' | |
917 | 200 Script output follows |
|
1132 | 200 Script output follows | |
918 |
|
1133 | |||
919 | d |
|
1134 | d | |
920 |
|
1135 | |||
921 | Test collapse = True |
|
1136 | Test collapse = True | |
922 |
|
1137 | |||
923 | $ killdaemons.py |
|
1138 | $ killdaemons.py | |
924 | $ cat >> paths.conf <<EOF |
|
1139 | $ cat >> paths.conf <<EOF | |
925 | > [web] |
|
1140 | > [web] | |
926 | > collapse=true |
|
1141 | > collapse=true | |
927 | > descend = true |
|
1142 | > descend = true | |
928 | > EOF |
|
1143 | > EOF | |
929 | $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \ |
|
1144 | $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \ | |
930 | > -A access-paths.log -E error-paths-3.log |
|
1145 | > -A access-paths.log -E error-paths-3.log | |
931 | $ cat hg.pid >> $DAEMON_PIDS |
|
1146 | $ cat hg.pid >> $DAEMON_PIDS | |
932 | $ get-with-headers.py localhost:$HGPORT1 'coll/?style=raw' |
|
1147 | $ get-with-headers.py localhost:$HGPORT1 'coll/?style=raw' | |
933 | 200 Script output follows |
|
1148 | 200 Script output follows | |
934 |
|
1149 | |||
935 |
|
1150 | |||
936 | /coll/a/ |
|
1151 | /coll/a/ | |
937 | /coll/a/.hg/patches/ |
|
1152 | /coll/a/.hg/patches/ | |
938 | /coll/b/ |
|
1153 | /coll/b/ | |
939 | /coll/c/ |
|
1154 | /coll/c/ | |
940 | /coll/notrepo/ |
|
1155 | /coll/notrepo/ | |
941 |
|
1156 | |||
942 | $ get-with-headers.py localhost:$HGPORT1 'coll/a/file/tip/a?style=raw' |
|
1157 | $ get-with-headers.py localhost:$HGPORT1 'coll/a/file/tip/a?style=raw' | |
943 | 200 Script output follows |
|
1158 | 200 Script output follows | |
944 |
|
1159 | |||
945 | a |
|
1160 | a | |
946 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/?style=raw' |
|
1161 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/?style=raw' | |
947 | 200 Script output follows |
|
1162 | 200 Script output follows | |
948 |
|
1163 | |||
949 |
|
1164 | |||
950 | /rcoll/a/ |
|
1165 | /rcoll/a/ | |
951 | /rcoll/a/.hg/patches/ |
|
1166 | /rcoll/a/.hg/patches/ | |
952 | /rcoll/b/ |
|
1167 | /rcoll/b/ | |
953 | /rcoll/b/d/ |
|
1168 | /rcoll/b/d/ | |
954 | /rcoll/c/ |
|
1169 | /rcoll/c/ | |
955 | /rcoll/notrepo/ |
|
1170 | /rcoll/notrepo/ | |
956 |
|
1171 | |||
957 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/b/d/file/tip/d?style=raw' |
|
1172 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/b/d/file/tip/d?style=raw' | |
958 | 200 Script output follows |
|
1173 | 200 Script output follows | |
959 |
|
1174 | |||
960 | d |
|
1175 | d | |
961 |
|
1176 | |||
962 | Test intermediate directories |
|
1177 | Test intermediate directories | |
963 |
|
1178 | |||
964 | Hide the subrepo parent |
|
1179 | Hide the subrepo parent | |
965 |
|
1180 | |||
966 | $ cp $root/notrepo/f/.hg/hgrc $root/notrepo/f/.hg/hgrc.bak |
|
1181 | $ cp $root/notrepo/f/.hg/hgrc $root/notrepo/f/.hg/hgrc.bak | |
967 | $ cat >> $root/notrepo/f/.hg/hgrc << EOF |
|
1182 | $ cat >> $root/notrepo/f/.hg/hgrc << EOF | |
968 | > [web] |
|
1183 | > [web] | |
969 | > hidden = True |
|
1184 | > hidden = True | |
970 | > EOF |
|
1185 | > EOF | |
971 |
|
1186 | |||
972 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/notrepo/?style=raw' |
|
1187 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/notrepo/?style=raw' | |
973 | 200 Script output follows |
|
1188 | 200 Script output follows | |
974 |
|
1189 | |||
975 |
|
1190 | |||
976 | /rcoll/notrepo/e/ |
|
1191 | /rcoll/notrepo/e/ | |
977 | /rcoll/notrepo/e/e2/ |
|
1192 | /rcoll/notrepo/e/e2/ | |
978 |
|
1193 | |||
979 |
|
1194 | |||
980 | Subrepo parent not hidden |
|
1195 | Subrepo parent not hidden | |
981 | $ mv $root/notrepo/f/.hg/hgrc.bak $root/notrepo/f/.hg/hgrc |
|
1196 | $ mv $root/notrepo/f/.hg/hgrc.bak $root/notrepo/f/.hg/hgrc | |
982 |
|
1197 | |||
983 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/notrepo/?style=raw' |
|
1198 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/notrepo/?style=raw' | |
984 | 200 Script output follows |
|
1199 | 200 Script output follows | |
985 |
|
1200 | |||
986 |
|
1201 | |||
987 | /rcoll/notrepo/e/ |
|
1202 | /rcoll/notrepo/e/ | |
988 | /rcoll/notrepo/e/e2/ |
|
1203 | /rcoll/notrepo/e/e2/ | |
989 | /rcoll/notrepo/f/ |
|
1204 | /rcoll/notrepo/f/ | |
990 | /rcoll/notrepo/f/f2/ |
|
1205 | /rcoll/notrepo/f/f2/ | |
991 |
|
1206 | |||
992 |
|
1207 | |||
993 | Test repositories inside intermediate directories |
|
1208 | Test repositories inside intermediate directories | |
994 |
|
1209 | |||
995 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/notrepo/e/file/tip/e?style=raw' |
|
1210 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/notrepo/e/file/tip/e?style=raw' | |
996 | 200 Script output follows |
|
1211 | 200 Script output follows | |
997 |
|
1212 | |||
998 | e |
|
1213 | e | |
999 |
|
1214 | |||
1000 | Test subrepositories inside intermediate directories |
|
1215 | Test subrepositories inside intermediate directories | |
1001 |
|
1216 | |||
1002 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/notrepo/f/f2/file/tip/f2?style=raw' |
|
1217 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/notrepo/f/f2/file/tip/f2?style=raw' | |
1003 | 200 Script output follows |
|
1218 | 200 Script output follows | |
1004 |
|
1219 | |||
1005 | f2 |
|
1220 | f2 | |
1006 |
|
1221 | |||
1007 | Test descend = False |
|
1222 | Test descend = False | |
1008 |
|
1223 | |||
1009 | $ killdaemons.py |
|
1224 | $ killdaemons.py | |
1010 | $ cat >> paths.conf <<EOF |
|
1225 | $ cat >> paths.conf <<EOF | |
1011 | > descend=false |
|
1226 | > descend=false | |
1012 | > EOF |
|
1227 | > EOF | |
1013 | $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \ |
|
1228 | $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \ | |
1014 | > -A access-paths.log -E error-paths-4.log |
|
1229 | > -A access-paths.log -E error-paths-4.log | |
1015 | $ cat hg.pid >> $DAEMON_PIDS |
|
1230 | $ cat hg.pid >> $DAEMON_PIDS | |
1016 | $ get-with-headers.py localhost:$HGPORT1 'coll/?style=raw' |
|
1231 | $ get-with-headers.py localhost:$HGPORT1 'coll/?style=raw' | |
1017 | 200 Script output follows |
|
1232 | 200 Script output follows | |
1018 |
|
1233 | |||
1019 |
|
1234 | |||
1020 | /coll/a/ |
|
1235 | /coll/a/ | |
1021 | /coll/b/ |
|
1236 | /coll/b/ | |
1022 | /coll/c/ |
|
1237 | /coll/c/ | |
1023 |
|
1238 | |||
1024 | $ get-with-headers.py localhost:$HGPORT1 'coll/a/file/tip/a?style=raw' |
|
1239 | $ get-with-headers.py localhost:$HGPORT1 'coll/a/file/tip/a?style=raw' | |
1025 | 200 Script output follows |
|
1240 | 200 Script output follows | |
1026 |
|
1241 | |||
1027 | a |
|
1242 | a | |
1028 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/?style=raw' |
|
1243 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/?style=raw' | |
1029 | 200 Script output follows |
|
1244 | 200 Script output follows | |
1030 |
|
1245 | |||
1031 |
|
1246 | |||
1032 | /rcoll/a/ |
|
1247 | /rcoll/a/ | |
1033 | /rcoll/b/ |
|
1248 | /rcoll/b/ | |
1034 | /rcoll/c/ |
|
1249 | /rcoll/c/ | |
1035 |
|
1250 | |||
1036 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/b/d/file/tip/d?style=raw' |
|
1251 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/b/d/file/tip/d?style=raw' | |
1037 | 200 Script output follows |
|
1252 | 200 Script output follows | |
1038 |
|
1253 | |||
1039 | d |
|
1254 | d | |
1040 |
|
1255 | |||
1041 | Test intermediate directories |
|
1256 | Test intermediate directories | |
1042 |
|
1257 | |||
1043 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/notrepo/?style=raw' |
|
1258 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/notrepo/?style=raw' | |
1044 | 200 Script output follows |
|
1259 | 200 Script output follows | |
1045 |
|
1260 | |||
1046 |
|
1261 | |||
1047 | /rcoll/notrepo/e/ |
|
1262 | /rcoll/notrepo/e/ | |
1048 | /rcoll/notrepo/f/ |
|
1263 | /rcoll/notrepo/f/ | |
1049 |
|
1264 | |||
1050 |
|
1265 | |||
1051 | Test repositories inside intermediate directories |
|
1266 | Test repositories inside intermediate directories | |
1052 |
|
1267 | |||
1053 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/notrepo/e/file/tip/e?style=raw' |
|
1268 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/notrepo/e/file/tip/e?style=raw' | |
1054 | 200 Script output follows |
|
1269 | 200 Script output follows | |
1055 |
|
1270 | |||
1056 | e |
|
1271 | e | |
1057 |
|
1272 | |||
1058 | Test subrepositories inside intermediate directories |
|
1273 | Test subrepositories inside intermediate directories | |
1059 |
|
1274 | |||
1060 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/notrepo/f/f2/file/tip/f2?style=raw' |
|
1275 | $ get-with-headers.py localhost:$HGPORT1 'rcoll/notrepo/f/f2/file/tip/f2?style=raw' | |
1061 | 200 Script output follows |
|
1276 | 200 Script output follows | |
1062 |
|
1277 | |||
1063 | f2 |
|
1278 | f2 | |
1064 |
|
1279 | |||
1065 | Test [paths] '*' in a repo root |
|
1280 | Test [paths] '*' in a repo root | |
1066 |
|
1281 | |||
1067 | $ hg id http://localhost:$HGPORT1/astar |
|
1282 | $ hg id http://localhost:$HGPORT1/astar | |
1068 | 8580ff50825a |
|
1283 | 8580ff50825a | |
1069 |
|
1284 | |||
1070 | $ killdaemons.py |
|
1285 | $ killdaemons.py | |
1071 | $ cat > paths.conf <<EOF |
|
1286 | $ cat > paths.conf <<EOF | |
1072 | > [paths] |
|
1287 | > [paths] | |
1073 | > t/a = $root/a |
|
1288 | > t/a = $root/a | |
1074 | > t/b = $root/b |
|
1289 | > t/b = $root/b | |
1075 | > c = $root/c |
|
1290 | > c = $root/c | |
1076 | > EOF |
|
1291 | > EOF | |
1077 | $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \ |
|
1292 | $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \ | |
1078 | > -A access-paths.log -E error-paths-5.log |
|
1293 | > -A access-paths.log -E error-paths-5.log | |
1079 | $ cat hg.pid >> $DAEMON_PIDS |
|
1294 | $ cat hg.pid >> $DAEMON_PIDS | |
1080 | $ get-with-headers.py localhost:$HGPORT1 '?style=raw' |
|
1295 | $ get-with-headers.py localhost:$HGPORT1 '?style=raw' | |
1081 | 200 Script output follows |
|
1296 | 200 Script output follows | |
1082 |
|
1297 | |||
1083 |
|
1298 | |||
1084 | /t/a/ |
|
1299 | /t/a/ | |
1085 | /t/b/ |
|
1300 | /t/b/ | |
1086 | /c/ |
|
1301 | /c/ | |
1087 |
|
1302 | |||
1088 | $ get-with-headers.py localhost:$HGPORT1 't/?style=raw' |
|
1303 | $ get-with-headers.py localhost:$HGPORT1 't/?style=raw' | |
1089 | 200 Script output follows |
|
1304 | 200 Script output follows | |
1090 |
|
1305 | |||
1091 |
|
1306 | |||
1092 | /t/a/ |
|
1307 | /t/a/ | |
1093 | /t/b/ |
|
1308 | /t/b/ | |
1094 |
|
1309 | |||
1095 |
|
1310 | |||
1096 | Test collapse = True |
|
1311 | Test collapse = True | |
1097 |
|
1312 | |||
1098 | $ killdaemons.py |
|
1313 | $ killdaemons.py | |
1099 | $ cat >> paths.conf <<EOF |
|
1314 | $ cat >> paths.conf <<EOF | |
1100 | > [web] |
|
1315 | > [web] | |
1101 | > collapse=true |
|
1316 | > collapse=true | |
1102 | > EOF |
|
1317 | > EOF | |
1103 | $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \ |
|
1318 | $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \ | |
1104 | > -A access-paths.log -E error-paths-6.log |
|
1319 | > -A access-paths.log -E error-paths-6.log | |
1105 | $ cat hg.pid >> $DAEMON_PIDS |
|
1320 | $ cat hg.pid >> $DAEMON_PIDS | |
1106 | $ get-with-headers.py localhost:$HGPORT1 '?style=raw' |
|
1321 | $ get-with-headers.py localhost:$HGPORT1 '?style=raw' | |
1107 | 200 Script output follows |
|
1322 | 200 Script output follows | |
1108 |
|
1323 | |||
1109 |
|
1324 | |||
1110 | /t/ |
|
1325 | /t/ | |
1111 | /c/ |
|
1326 | /c/ | |
1112 |
|
1327 | |||
1113 | $ get-with-headers.py localhost:$HGPORT1 't/?style=raw' |
|
1328 | $ get-with-headers.py localhost:$HGPORT1 't/?style=raw' | |
1114 | 200 Script output follows |
|
1329 | 200 Script output follows | |
1115 |
|
1330 | |||
1116 |
|
1331 | |||
1117 | /t/a/ |
|
1332 | /t/a/ | |
1118 | /t/b/ |
|
1333 | /t/b/ | |
1119 |
|
1334 | |||
1120 |
|
1335 | |||
1121 | test descend = False |
|
1336 | test descend = False | |
1122 |
|
1337 | |||
1123 | $ killdaemons.py |
|
1338 | $ killdaemons.py | |
1124 | $ cat >> paths.conf <<EOF |
|
1339 | $ cat >> paths.conf <<EOF | |
1125 | > descend=false |
|
1340 | > descend=false | |
1126 | > EOF |
|
1341 | > EOF | |
1127 | $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \ |
|
1342 | $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \ | |
1128 | > -A access-paths.log -E error-paths-7.log |
|
1343 | > -A access-paths.log -E error-paths-7.log | |
1129 | $ cat hg.pid >> $DAEMON_PIDS |
|
1344 | $ cat hg.pid >> $DAEMON_PIDS | |
1130 | $ get-with-headers.py localhost:$HGPORT1 '?style=raw' |
|
1345 | $ get-with-headers.py localhost:$HGPORT1 '?style=raw' | |
1131 | 200 Script output follows |
|
1346 | 200 Script output follows | |
1132 |
|
1347 | |||
1133 |
|
1348 | |||
1134 | /c/ |
|
1349 | /c/ | |
1135 |
|
1350 | |||
1136 | $ get-with-headers.py localhost:$HGPORT1 't/?style=raw' |
|
1351 | $ get-with-headers.py localhost:$HGPORT1 't/?style=raw' | |
1137 | 200 Script output follows |
|
1352 | 200 Script output follows | |
1138 |
|
1353 | |||
1139 |
|
1354 | |||
1140 | /t/a/ |
|
1355 | /t/a/ | |
1141 | /t/b/ |
|
1356 | /t/b/ | |
1142 |
|
1357 | |||
1143 | $ killdaemons.py |
|
1358 | $ killdaemons.py | |
1144 | $ cat > paths.conf <<EOF |
|
1359 | $ cat > paths.conf <<EOF | |
1145 | > [paths] |
|
1360 | > [paths] | |
1146 | > nostore = $root/nostore |
|
1361 | > nostore = $root/nostore | |
1147 | > inexistent = $root/inexistent |
|
1362 | > inexistent = $root/inexistent | |
1148 | > EOF |
|
1363 | > EOF | |
1149 | $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \ |
|
1364 | $ hg serve -p $HGPORT1 -d --pid-file=hg.pid --webdir-conf paths.conf \ | |
1150 | > -A access-paths.log -E error-paths-8.log |
|
1365 | > -A access-paths.log -E error-paths-8.log | |
1151 | $ cat hg.pid >> $DAEMON_PIDS |
|
1366 | $ cat hg.pid >> $DAEMON_PIDS | |
1152 |
|
1367 | |||
1153 | test inexistent and inaccessible repo should be ignored silently |
|
1368 | test inexistent and inaccessible repo should be ignored silently | |
1154 |
|
1369 | |||
1155 | $ get-with-headers.py localhost:$HGPORT1 '' |
|
1370 | $ get-with-headers.py localhost:$HGPORT1 '' | |
1156 | 200 Script output follows |
|
1371 | 200 Script output follows | |
1157 |
|
1372 | |||
1158 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> |
|
1373 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> | |
1159 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US"> |
|
1374 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US"> | |
1160 | <head> |
|
1375 | <head> | |
1161 | <link rel="icon" href="/static/hgicon.png" type="image/png" /> |
|
1376 | <link rel="icon" href="/static/hgicon.png" type="image/png" /> | |
1162 | <meta name="robots" content="index, nofollow" /> |
|
1377 | <meta name="robots" content="index, nofollow" /> | |
1163 | <link rel="stylesheet" href="/static/style-paper.css" type="text/css" /> |
|
1378 | <link rel="stylesheet" href="/static/style-paper.css" type="text/css" /> | |
1164 | <script type="text/javascript" src="/static/mercurial.js"></script> |
|
1379 | <script type="text/javascript" src="/static/mercurial.js"></script> | |
1165 |
|
1380 | |||
1166 | <title>Mercurial repositories index</title> |
|
1381 | <title>Mercurial repositories index</title> | |
1167 | </head> |
|
1382 | </head> | |
1168 | <body> |
|
1383 | <body> | |
1169 |
|
1384 | |||
1170 | <div class="container"> |
|
1385 | <div class="container"> | |
1171 | <div class="menu"> |
|
1386 | <div class="menu"> | |
1172 | <a href="https://mercurial-scm.org/"> |
|
1387 | <a href="https://mercurial-scm.org/"> | |
1173 | <img src="/static/hglogo.png" width=75 height=90 border=0 alt="mercurial" /></a> |
|
1388 | <img src="/static/hglogo.png" width=75 height=90 border=0 alt="mercurial" /></a> | |
1174 | </div> |
|
1389 | </div> | |
1175 | <div class="main"> |
|
1390 | <div class="main"> | |
1176 | <h2 class="breadcrumb"><a href="/">Mercurial</a> </h2> |
|
1391 | <h2 class="breadcrumb"><a href="/">Mercurial</a> </h2> | |
1177 |
|
1392 | |||
1178 | <table class="bigtable"> |
|
1393 | <table class="bigtable"> | |
1179 | <thead> |
|
1394 | <thead> | |
1180 | <tr> |
|
1395 | <tr> | |
1181 | <th><a href="?sort=name">Name</a></th> |
|
1396 | <th><a href="?sort=name">Name</a></th> | |
1182 | <th><a href="?sort=description">Description</a></th> |
|
1397 | <th><a href="?sort=description">Description</a></th> | |
1183 | <th><a href="?sort=contact">Contact</a></th> |
|
1398 | <th><a href="?sort=contact">Contact</a></th> | |
1184 | <th><a href="?sort=lastchange">Last modified</a></th> |
|
1399 | <th><a href="?sort=lastchange">Last modified</a></th> | |
1185 | <th> </th> |
|
1400 | <th> </th> | |
1186 | <th> </th> |
|
1401 | <th> </th> | |
1187 | </tr> |
|
1402 | </tr> | |
1188 | </thead> |
|
1403 | </thead> | |
1189 | <tbody class="stripes2"> |
|
1404 | <tbody class="stripes2"> | |
1190 |
|
1405 | |||
1191 | </tbody> |
|
1406 | </tbody> | |
1192 | </table> |
|
1407 | </table> | |
1193 | </div> |
|
1408 | </div> | |
1194 | </div> |
|
1409 | </div> | |
1195 | <script type="text/javascript">process_dates()</script> |
|
1410 | <script type="text/javascript">process_dates()</script> | |
1196 |
|
1411 | |||
1197 |
|
1412 | |||
1198 | </body> |
|
1413 | </body> | |
1199 | </html> |
|
1414 | </html> | |
1200 |
|
1415 | |||
1201 |
|
1416 | |||
1202 | test listening address/port specified by web-conf (issue4699): |
|
1417 | test listening address/port specified by web-conf (issue4699): | |
1203 |
|
1418 | |||
1204 | $ killdaemons.py |
|
1419 | $ killdaemons.py | |
1205 | $ cat >> paths.conf <<EOF |
|
1420 | $ cat >> paths.conf <<EOF | |
1206 | > [web] |
|
1421 | > [web] | |
1207 | > address = localhost |
|
1422 | > address = localhost | |
1208 | > port = $HGPORT1 |
|
1423 | > port = $HGPORT1 | |
1209 | > EOF |
|
1424 | > EOF | |
1210 | $ hg serve -d --pid-file=hg.pid --web-conf paths.conf \ |
|
1425 | $ hg serve -d --pid-file=hg.pid --web-conf paths.conf \ | |
1211 | > -A access-paths.log -E error-paths-9.log |
|
1426 | > -A access-paths.log -E error-paths-9.log | |
1212 | listening at http://*:$HGPORT1/ (bound to 127.0.0.1:$HGPORT1) (glob) |
|
1427 | listening at http://*:$HGPORT1/ (bound to 127.0.0.1:$HGPORT1) (glob) | |
1213 | $ cat hg.pid >> $DAEMON_PIDS |
|
1428 | $ cat hg.pid >> $DAEMON_PIDS | |
1214 | $ get-with-headers.py localhost:$HGPORT1 '?style=raw' |
|
1429 | $ get-with-headers.py localhost:$HGPORT1 '?style=raw' | |
1215 | 200 Script output follows |
|
1430 | 200 Script output follows | |
1216 |
|
1431 | |||
1217 |
|
1432 | |||
1218 |
|
1433 | |||
1219 | test --port option overrides web.port: |
|
1434 | test --port option overrides web.port: | |
1220 |
|
1435 | |||
1221 | $ killdaemons.py |
|
1436 | $ killdaemons.py | |
1222 | $ hg serve -p $HGPORT2 -d -v --pid-file=hg.pid --web-conf paths.conf \ |
|
1437 | $ hg serve -p $HGPORT2 -d -v --pid-file=hg.pid --web-conf paths.conf \ | |
1223 | > -A access-paths.log -E error-paths-10.log |
|
1438 | > -A access-paths.log -E error-paths-10.log | |
1224 | listening at http://*:$HGPORT2/ (bound to 127.0.0.1:$HGPORT2) (glob) |
|
1439 | listening at http://*:$HGPORT2/ (bound to 127.0.0.1:$HGPORT2) (glob) | |
1225 | $ cat hg.pid >> $DAEMON_PIDS |
|
1440 | $ cat hg.pid >> $DAEMON_PIDS | |
1226 | $ get-with-headers.py localhost:$HGPORT2 '?style=raw' |
|
1441 | $ get-with-headers.py localhost:$HGPORT2 '?style=raw' | |
1227 | 200 Script output follows |
|
1442 | 200 Script output follows | |
1228 |
|
1443 | |||
1229 |
|
1444 | |||
1230 |
|
1445 | |||
1231 |
|
1446 | |||
1232 | $ killdaemons.py |
|
1447 | $ killdaemons.py | |
1233 | $ cat > collections.conf <<EOF |
|
1448 | $ cat > collections.conf <<EOF | |
1234 | > [collections] |
|
1449 | > [collections] | |
1235 | > $root=$root |
|
1450 | > $root=$root | |
1236 | > EOF |
|
1451 | > EOF | |
1237 | $ hg serve --config web.baseurl=http://hg.example.com:8080/ -p $HGPORT2 -d \ |
|
1452 | $ hg serve --config web.baseurl=http://hg.example.com:8080/ -p $HGPORT2 -d \ | |
1238 | > --pid-file=hg.pid --webdir-conf collections.conf \ |
|
1453 | > --pid-file=hg.pid --webdir-conf collections.conf \ | |
1239 | > -A access-collections.log -E error-collections.log |
|
1454 | > -A access-collections.log -E error-collections.log | |
1240 | $ cat hg.pid >> $DAEMON_PIDS |
|
1455 | $ cat hg.pid >> $DAEMON_PIDS | |
1241 |
|
1456 | |||
1242 | collections: should succeed |
|
1457 | collections: should succeed | |
1243 |
|
1458 | |||
1244 | $ get-with-headers.py localhost:$HGPORT2 '?style=raw' |
|
1459 | $ get-with-headers.py localhost:$HGPORT2 '?style=raw' | |
1245 | 200 Script output follows |
|
1460 | 200 Script output follows | |
1246 |
|
1461 | |||
1247 |
|
1462 | |||
1248 | /a/ |
|
1463 | /a/ | |
1249 | /a/.hg/patches/ |
|
1464 | /a/.hg/patches/ | |
1250 | /b/ |
|
1465 | /b/ | |
1251 | /c/ |
|
1466 | /c/ | |
1252 | /notrepo/e/ |
|
1467 | /notrepo/e/ | |
1253 | /notrepo/f/ |
|
1468 | /notrepo/f/ | |
1254 |
|
1469 | |||
1255 | $ get-with-headers.py localhost:$HGPORT2 'a/file/tip/a?style=raw' |
|
1470 | $ get-with-headers.py localhost:$HGPORT2 'a/file/tip/a?style=raw' | |
1256 | 200 Script output follows |
|
1471 | 200 Script output follows | |
1257 |
|
1472 | |||
1258 | a |
|
1473 | a | |
1259 | $ get-with-headers.py localhost:$HGPORT2 'b/file/tip/b?style=raw' |
|
1474 | $ get-with-headers.py localhost:$HGPORT2 'b/file/tip/b?style=raw' | |
1260 | 200 Script output follows |
|
1475 | 200 Script output follows | |
1261 |
|
1476 | |||
1262 | b |
|
1477 | b | |
1263 | $ get-with-headers.py localhost:$HGPORT2 'c/file/tip/c?style=raw' |
|
1478 | $ get-with-headers.py localhost:$HGPORT2 'c/file/tip/c?style=raw' | |
1264 | 200 Script output follows |
|
1479 | 200 Script output follows | |
1265 |
|
1480 | |||
1266 | c |
|
1481 | c | |
1267 |
|
1482 | |||
1268 | atom-log with basedir / |
|
1483 | atom-log with basedir / | |
1269 |
|
1484 | |||
1270 | $ get-with-headers.py localhost:$HGPORT2 'a/atom-log' | grep '<link' |
|
1485 | $ get-with-headers.py localhost:$HGPORT2 'a/atom-log' | grep '<link' | |
1271 | <link rel="self" href="http://hg.example.com:8080/a/atom-log"/> |
|
1486 | <link rel="self" href="http://hg.example.com:8080/a/atom-log"/> | |
1272 | <link rel="alternate" href="http://hg.example.com:8080/a/"/> |
|
1487 | <link rel="alternate" href="http://hg.example.com:8080/a/"/> | |
1273 | <link href="http://hg.example.com:8080/a/rev/8580ff50825a"/> |
|
1488 | <link href="http://hg.example.com:8080/a/rev/8580ff50825a"/> | |
1274 |
|
1489 | |||
1275 | rss-log with basedir / |
|
1490 | rss-log with basedir / | |
1276 |
|
1491 | |||
1277 | $ get-with-headers.py localhost:$HGPORT2 'a/rss-log' | grep '<guid' |
|
1492 | $ get-with-headers.py localhost:$HGPORT2 'a/rss-log' | grep '<guid' | |
1278 | <guid isPermaLink="true">http://hg.example.com:8080/a/rev/8580ff50825a</guid> |
|
1493 | <guid isPermaLink="true">http://hg.example.com:8080/a/rev/8580ff50825a</guid> | |
1279 | $ killdaemons.py |
|
1494 | $ killdaemons.py | |
1280 | $ hg serve --config web.baseurl=http://hg.example.com:8080/foo/ -p $HGPORT2 -d \ |
|
1495 | $ hg serve --config web.baseurl=http://hg.example.com:8080/foo/ -p $HGPORT2 -d \ | |
1281 | > --pid-file=hg.pid --webdir-conf collections.conf \ |
|
1496 | > --pid-file=hg.pid --webdir-conf collections.conf \ | |
1282 | > -A access-collections-2.log -E error-collections-2.log |
|
1497 | > -A access-collections-2.log -E error-collections-2.log | |
1283 | $ cat hg.pid >> $DAEMON_PIDS |
|
1498 | $ cat hg.pid >> $DAEMON_PIDS | |
1284 |
|
1499 | |||
1285 | atom-log with basedir /foo/ |
|
1500 | atom-log with basedir /foo/ | |
1286 |
|
1501 | |||
1287 | $ get-with-headers.py localhost:$HGPORT2 'a/atom-log' | grep '<link' |
|
1502 | $ get-with-headers.py localhost:$HGPORT2 'a/atom-log' | grep '<link' | |
1288 | <link rel="self" href="http://hg.example.com:8080/foo/a/atom-log"/> |
|
1503 | <link rel="self" href="http://hg.example.com:8080/foo/a/atom-log"/> | |
1289 | <link rel="alternate" href="http://hg.example.com:8080/foo/a/"/> |
|
1504 | <link rel="alternate" href="http://hg.example.com:8080/foo/a/"/> | |
1290 | <link href="http://hg.example.com:8080/foo/a/rev/8580ff50825a"/> |
|
1505 | <link href="http://hg.example.com:8080/foo/a/rev/8580ff50825a"/> | |
1291 |
|
1506 | |||
1292 | rss-log with basedir /foo/ |
|
1507 | rss-log with basedir /foo/ | |
1293 |
|
1508 | |||
1294 | $ get-with-headers.py localhost:$HGPORT2 'a/rss-log' | grep '<guid' |
|
1509 | $ get-with-headers.py localhost:$HGPORT2 'a/rss-log' | grep '<guid' | |
1295 | <guid isPermaLink="true">http://hg.example.com:8080/foo/a/rev/8580ff50825a</guid> |
|
1510 | <guid isPermaLink="true">http://hg.example.com:8080/foo/a/rev/8580ff50825a</guid> | |
1296 |
|
1511 | |||
1297 | Path refreshing works as expected |
|
1512 | Path refreshing works as expected | |
1298 |
|
1513 | |||
1299 | $ killdaemons.py |
|
1514 | $ killdaemons.py | |
1300 | $ mkdir $root/refreshtest |
|
1515 | $ mkdir $root/refreshtest | |
1301 | $ hg init $root/refreshtest/a |
|
1516 | $ hg init $root/refreshtest/a | |
1302 | $ cat > paths.conf << EOF |
|
1517 | $ cat > paths.conf << EOF | |
1303 | > [paths] |
|
1518 | > [paths] | |
1304 | > / = $root/refreshtest/* |
|
1519 | > / = $root/refreshtest/* | |
1305 | > EOF |
|
1520 | > EOF | |
1306 | $ hg serve -p $HGPORT1 -d --pid-file hg.pid --webdir-conf paths.conf |
|
1521 | $ hg serve -p $HGPORT1 -d --pid-file hg.pid --webdir-conf paths.conf | |
1307 | $ cat hg.pid >> $DAEMON_PIDS |
|
1522 | $ cat hg.pid >> $DAEMON_PIDS | |
1308 |
|
1523 | |||
1309 | $ get-with-headers.py localhost:$HGPORT1 '?style=raw' |
|
1524 | $ get-with-headers.py localhost:$HGPORT1 '?style=raw' | |
1310 | 200 Script output follows |
|
1525 | 200 Script output follows | |
1311 |
|
1526 | |||
1312 |
|
1527 | |||
1313 | /a/ |
|
1528 | /a/ | |
1314 |
|
1529 | |||
1315 |
|
1530 | |||
1316 | By default refreshing occurs every 20s and a new repo won't be listed |
|
1531 | By default refreshing occurs every 20s and a new repo won't be listed | |
1317 | immediately. |
|
1532 | immediately. | |
1318 |
|
1533 | |||
1319 | $ hg init $root/refreshtest/b |
|
1534 | $ hg init $root/refreshtest/b | |
1320 | $ get-with-headers.py localhost:$HGPORT1 '?style=raw' |
|
1535 | $ get-with-headers.py localhost:$HGPORT1 '?style=raw' | |
1321 | 200 Script output follows |
|
1536 | 200 Script output follows | |
1322 |
|
1537 | |||
1323 |
|
1538 | |||
1324 | /a/ |
|
1539 | /a/ | |
1325 |
|
1540 | |||
1326 |
|
1541 | |||
1327 | Restart the server with no refresh interval. New repo should appear |
|
1542 | Restart the server with no refresh interval. New repo should appear | |
1328 | immediately. |
|
1543 | immediately. | |
1329 |
|
1544 | |||
1330 | $ killdaemons.py |
|
1545 | $ killdaemons.py | |
1331 | $ cat > paths.conf << EOF |
|
1546 | $ cat > paths.conf << EOF | |
1332 | > [web] |
|
1547 | > [web] | |
1333 | > refreshinterval = -1 |
|
1548 | > refreshinterval = -1 | |
1334 | > [paths] |
|
1549 | > [paths] | |
1335 | > / = $root/refreshtest/* |
|
1550 | > / = $root/refreshtest/* | |
1336 | > EOF |
|
1551 | > EOF | |
1337 | $ hg serve -p $HGPORT1 -d --pid-file hg.pid --webdir-conf paths.conf |
|
1552 | $ hg serve -p $HGPORT1 -d --pid-file hg.pid --webdir-conf paths.conf | |
1338 | $ cat hg.pid >> $DAEMON_PIDS |
|
1553 | $ cat hg.pid >> $DAEMON_PIDS | |
1339 |
|
1554 | |||
1340 | $ get-with-headers.py localhost:$HGPORT1 '?style=raw' |
|
1555 | $ get-with-headers.py localhost:$HGPORT1 '?style=raw' | |
1341 | 200 Script output follows |
|
1556 | 200 Script output follows | |
1342 |
|
1557 | |||
1343 |
|
1558 | |||
1344 | /a/ |
|
1559 | /a/ | |
1345 | /b/ |
|
1560 | /b/ | |
1346 |
|
1561 | |||
1347 |
|
1562 | |||
1348 | $ hg init $root/refreshtest/c |
|
1563 | $ hg init $root/refreshtest/c | |
1349 | $ get-with-headers.py localhost:$HGPORT1 '?style=raw' |
|
1564 | $ get-with-headers.py localhost:$HGPORT1 '?style=raw' | |
1350 | 200 Script output follows |
|
1565 | 200 Script output follows | |
1351 |
|
1566 | |||
1352 |
|
1567 | |||
1353 | /a/ |
|
1568 | /a/ | |
1354 | /b/ |
|
1569 | /b/ | |
1355 | /c/ |
|
1570 | /c/ | |
1356 |
|
1571 | |||
1357 |
|
1572 | |||
1358 | paths errors 1 |
|
1573 | paths errors 1 | |
1359 |
|
1574 | |||
1360 | $ cat error-paths-1.log |
|
1575 | $ cat error-paths-1.log | |
1361 |
|
1576 | |||
1362 | paths errors 2 |
|
1577 | paths errors 2 | |
1363 |
|
1578 | |||
1364 | $ cat error-paths-2.log |
|
1579 | $ cat error-paths-2.log | |
1365 |
|
1580 | |||
1366 | paths errors 3 |
|
1581 | paths errors 3 | |
1367 |
|
1582 | |||
1368 | $ cat error-paths-3.log |
|
1583 | $ cat error-paths-3.log | |
1369 |
|
1584 | |||
1370 | paths errors 4 |
|
1585 | paths errors 4 | |
1371 |
|
1586 | |||
1372 | $ cat error-paths-4.log |
|
1587 | $ cat error-paths-4.log | |
1373 |
|
1588 | |||
1374 | paths errors 5 |
|
1589 | paths errors 5 | |
1375 |
|
1590 | |||
1376 | $ cat error-paths-5.log |
|
1591 | $ cat error-paths-5.log | |
1377 |
|
1592 | |||
1378 | paths errors 6 |
|
1593 | paths errors 6 | |
1379 |
|
1594 | |||
1380 | $ cat error-paths-6.log |
|
1595 | $ cat error-paths-6.log | |
1381 |
|
1596 | |||
1382 | paths errors 7 |
|
1597 | paths errors 7 | |
1383 |
|
1598 | |||
1384 | $ cat error-paths-7.log |
|
1599 | $ cat error-paths-7.log | |
1385 |
|
1600 | |||
1386 | paths errors 8 |
|
1601 | paths errors 8 | |
1387 |
|
1602 | |||
1388 | $ cat error-paths-8.log |
|
1603 | $ cat error-paths-8.log | |
1389 |
|
1604 | |||
1390 | paths errors 9 |
|
1605 | paths errors 9 | |
1391 |
|
1606 | |||
1392 | $ cat error-paths-9.log |
|
1607 | $ cat error-paths-9.log | |
1393 |
|
1608 | |||
1394 | paths errors 10 |
|
1609 | paths errors 10 | |
1395 |
|
1610 | |||
1396 | $ cat error-paths-10.log |
|
1611 | $ cat error-paths-10.log | |
1397 |
|
1612 | |||
1398 | collections errors |
|
1613 | collections errors | |
1399 |
|
1614 | |||
1400 | $ cat error-collections.log |
|
1615 | $ cat error-collections.log | |
1401 |
|
1616 | |||
1402 | collections errors 2 |
|
1617 | collections errors 2 | |
1403 |
|
1618 | |||
1404 | $ cat error-collections-2.log |
|
1619 | $ cat error-collections-2.log |
General Comments 0
You need to be logged in to leave comments.
Login now