Show More
@@ -1,1588 +1,1593 b'' | |||
|
1 | 1 | # configitems.py - centralized declaration of configuration option |
|
2 | 2 | # |
|
3 | 3 | # Copyright 2017 Pierre-Yves David <pierre-yves.david@octobus.net> |
|
4 | 4 | # |
|
5 | 5 | # This software may be used and distributed according to the terms of the |
|
6 | 6 | # GNU General Public License version 2 or any later version. |
|
7 | 7 | |
|
8 | 8 | from __future__ import absolute_import |
|
9 | 9 | |
|
10 | 10 | import functools |
|
11 | 11 | import re |
|
12 | 12 | |
|
13 | 13 | from . import ( |
|
14 | 14 | encoding, |
|
15 | 15 | error, |
|
16 | 16 | ) |
|
17 | 17 | |
|
18 | 18 | |
|
19 | 19 | def loadconfigtable(ui, extname, configtable): |
|
20 | 20 | """update config item known to the ui with the extension ones""" |
|
21 | 21 | for section, items in sorted(configtable.items()): |
|
22 | 22 | knownitems = ui._knownconfig.setdefault(section, itemregister()) |
|
23 | 23 | knownkeys = set(knownitems) |
|
24 | 24 | newkeys = set(items) |
|
25 | 25 | for key in sorted(knownkeys & newkeys): |
|
26 | 26 | msg = b"extension '%s' overwrite config item '%s.%s'" |
|
27 | 27 | msg %= (extname, section, key) |
|
28 | 28 | ui.develwarn(msg, config=b'warn-config') |
|
29 | 29 | |
|
30 | 30 | knownitems.update(items) |
|
31 | 31 | |
|
32 | 32 | |
|
33 | 33 | class configitem(object): |
|
34 | 34 | """represent a known config item |
|
35 | 35 | |
|
36 | 36 | :section: the official config section where to find this item, |
|
37 | 37 | :name: the official name within the section, |
|
38 | 38 | :default: default value for this item, |
|
39 | 39 | :alias: optional list of tuples as alternatives, |
|
40 | 40 | :generic: this is a generic definition, match name using regular expression. |
|
41 | 41 | """ |
|
42 | 42 | |
|
43 | 43 | def __init__( |
|
44 | 44 | self, |
|
45 | 45 | section, |
|
46 | 46 | name, |
|
47 | 47 | default=None, |
|
48 | 48 | alias=(), |
|
49 | 49 | generic=False, |
|
50 | 50 | priority=0, |
|
51 | 51 | experimental=False, |
|
52 | 52 | ): |
|
53 | 53 | self.section = section |
|
54 | 54 | self.name = name |
|
55 | 55 | self.default = default |
|
56 | 56 | self.alias = list(alias) |
|
57 | 57 | self.generic = generic |
|
58 | 58 | self.priority = priority |
|
59 | 59 | self.experimental = experimental |
|
60 | 60 | self._re = None |
|
61 | 61 | if generic: |
|
62 | 62 | self._re = re.compile(self.name) |
|
63 | 63 | |
|
64 | 64 | |
|
65 | 65 | class itemregister(dict): |
|
66 | 66 | """A specialized dictionary that can handle wild-card selection""" |
|
67 | 67 | |
|
68 | 68 | def __init__(self): |
|
69 | 69 | super(itemregister, self).__init__() |
|
70 | 70 | self._generics = set() |
|
71 | 71 | |
|
72 | 72 | def update(self, other): |
|
73 | 73 | super(itemregister, self).update(other) |
|
74 | 74 | self._generics.update(other._generics) |
|
75 | 75 | |
|
76 | 76 | def __setitem__(self, key, item): |
|
77 | 77 | super(itemregister, self).__setitem__(key, item) |
|
78 | 78 | if item.generic: |
|
79 | 79 | self._generics.add(item) |
|
80 | 80 | |
|
81 | 81 | def get(self, key): |
|
82 | 82 | baseitem = super(itemregister, self).get(key) |
|
83 | 83 | if baseitem is not None and not baseitem.generic: |
|
84 | 84 | return baseitem |
|
85 | 85 | |
|
86 | 86 | # search for a matching generic item |
|
87 | 87 | generics = sorted(self._generics, key=(lambda x: (x.priority, x.name))) |
|
88 | 88 | for item in generics: |
|
89 | 89 | # we use 'match' instead of 'search' to make the matching simpler |
|
90 | 90 | # for people unfamiliar with regular expression. Having the match |
|
91 | 91 | # rooted to the start of the string will produce less surprising |
|
92 | 92 | # result for user writing simple regex for sub-attribute. |
|
93 | 93 | # |
|
94 | 94 | # For example using "color\..*" match produces an unsurprising |
|
95 | 95 | # result, while using search could suddenly match apparently |
|
96 | 96 | # unrelated configuration that happens to contains "color." |
|
97 | 97 | # anywhere. This is a tradeoff where we favor requiring ".*" on |
|
98 | 98 | # some match to avoid the need to prefix most pattern with "^". |
|
99 | 99 | # The "^" seems more error prone. |
|
100 | 100 | if item._re.match(key): |
|
101 | 101 | return item |
|
102 | 102 | |
|
103 | 103 | return None |
|
104 | 104 | |
|
105 | 105 | |
|
106 | 106 | coreitems = {} |
|
107 | 107 | |
|
108 | 108 | |
|
109 | 109 | def _register(configtable, *args, **kwargs): |
|
110 | 110 | item = configitem(*args, **kwargs) |
|
111 | 111 | section = configtable.setdefault(item.section, itemregister()) |
|
112 | 112 | if item.name in section: |
|
113 | 113 | msg = b"duplicated config item registration for '%s.%s'" |
|
114 | 114 | raise error.ProgrammingError(msg % (item.section, item.name)) |
|
115 | 115 | section[item.name] = item |
|
116 | 116 | |
|
117 | 117 | |
|
118 | 118 | # special value for case where the default is derived from other values |
|
119 | 119 | dynamicdefault = object() |
|
120 | 120 | |
|
121 | 121 | # Registering actual config items |
|
122 | 122 | |
|
123 | 123 | |
|
124 | 124 | def getitemregister(configtable): |
|
125 | 125 | f = functools.partial(_register, configtable) |
|
126 | 126 | # export pseudo enum as configitem.* |
|
127 | 127 | f.dynamicdefault = dynamicdefault |
|
128 | 128 | return f |
|
129 | 129 | |
|
130 | 130 | |
|
131 | 131 | coreconfigitem = getitemregister(coreitems) |
|
132 | 132 | |
|
133 | 133 | |
|
134 | 134 | def _registerdiffopts(section, configprefix=b''): |
|
135 | 135 | coreconfigitem( |
|
136 | 136 | section, configprefix + b'nodates', default=False, |
|
137 | 137 | ) |
|
138 | 138 | coreconfigitem( |
|
139 | 139 | section, configprefix + b'showfunc', default=False, |
|
140 | 140 | ) |
|
141 | 141 | coreconfigitem( |
|
142 | 142 | section, configprefix + b'unified', default=None, |
|
143 | 143 | ) |
|
144 | 144 | coreconfigitem( |
|
145 | 145 | section, configprefix + b'git', default=False, |
|
146 | 146 | ) |
|
147 | 147 | coreconfigitem( |
|
148 | 148 | section, configprefix + b'ignorews', default=False, |
|
149 | 149 | ) |
|
150 | 150 | coreconfigitem( |
|
151 | 151 | section, configprefix + b'ignorewsamount', default=False, |
|
152 | 152 | ) |
|
153 | 153 | coreconfigitem( |
|
154 | 154 | section, configprefix + b'ignoreblanklines', default=False, |
|
155 | 155 | ) |
|
156 | 156 | coreconfigitem( |
|
157 | 157 | section, configprefix + b'ignorewseol', default=False, |
|
158 | 158 | ) |
|
159 | 159 | coreconfigitem( |
|
160 | 160 | section, configprefix + b'nobinary', default=False, |
|
161 | 161 | ) |
|
162 | 162 | coreconfigitem( |
|
163 | 163 | section, configprefix + b'noprefix', default=False, |
|
164 | 164 | ) |
|
165 | 165 | coreconfigitem( |
|
166 | 166 | section, configprefix + b'word-diff', default=False, |
|
167 | 167 | ) |
|
168 | 168 | |
|
169 | 169 | |
|
170 | 170 | coreconfigitem( |
|
171 | 171 | b'alias', b'.*', default=dynamicdefault, generic=True, |
|
172 | 172 | ) |
|
173 | 173 | coreconfigitem( |
|
174 | 174 | b'auth', b'cookiefile', default=None, |
|
175 | 175 | ) |
|
176 | 176 | _registerdiffopts(section=b'annotate') |
|
177 | 177 | # bookmarks.pushing: internal hack for discovery |
|
178 | 178 | coreconfigitem( |
|
179 | 179 | b'bookmarks', b'pushing', default=list, |
|
180 | 180 | ) |
|
181 | 181 | # bundle.mainreporoot: internal hack for bundlerepo |
|
182 | 182 | coreconfigitem( |
|
183 | 183 | b'bundle', b'mainreporoot', default=b'', |
|
184 | 184 | ) |
|
185 | 185 | coreconfigitem( |
|
186 | 186 | b'censor', b'policy', default=b'abort', experimental=True, |
|
187 | 187 | ) |
|
188 | 188 | coreconfigitem( |
|
189 | 189 | b'chgserver', b'idletimeout', default=3600, |
|
190 | 190 | ) |
|
191 | 191 | coreconfigitem( |
|
192 | 192 | b'chgserver', b'skiphash', default=False, |
|
193 | 193 | ) |
|
194 | 194 | coreconfigitem( |
|
195 | 195 | b'cmdserver', b'log', default=None, |
|
196 | 196 | ) |
|
197 | 197 | coreconfigitem( |
|
198 | 198 | b'cmdserver', b'max-log-files', default=7, |
|
199 | 199 | ) |
|
200 | 200 | coreconfigitem( |
|
201 | 201 | b'cmdserver', b'max-log-size', default=b'1 MB', |
|
202 | 202 | ) |
|
203 | 203 | coreconfigitem( |
|
204 | 204 | b'cmdserver', b'max-repo-cache', default=0, experimental=True, |
|
205 | 205 | ) |
|
206 | 206 | coreconfigitem( |
|
207 | 207 | b'cmdserver', b'message-encodings', default=list, |
|
208 | 208 | ) |
|
209 | 209 | coreconfigitem( |
|
210 | 210 | b'cmdserver', |
|
211 | 211 | b'track-log', |
|
212 | 212 | default=lambda: [b'chgserver', b'cmdserver', b'repocache'], |
|
213 | 213 | ) |
|
214 | 214 | coreconfigitem( |
|
215 | 215 | b'cmdserver', b'shutdown-on-interrupt', default=True, |
|
216 | 216 | ) |
|
217 | 217 | coreconfigitem( |
|
218 | 218 | b'color', b'.*', default=None, generic=True, |
|
219 | 219 | ) |
|
220 | 220 | coreconfigitem( |
|
221 | 221 | b'color', b'mode', default=b'auto', |
|
222 | 222 | ) |
|
223 | 223 | coreconfigitem( |
|
224 | 224 | b'color', b'pagermode', default=dynamicdefault, |
|
225 | 225 | ) |
|
226 | 226 | _registerdiffopts(section=b'commands', configprefix=b'commit.interactive.') |
|
227 | 227 | coreconfigitem( |
|
228 | 228 | b'commands', b'commit.post-status', default=False, |
|
229 | 229 | ) |
|
230 | 230 | coreconfigitem( |
|
231 | 231 | b'commands', b'grep.all-files', default=False, experimental=True, |
|
232 | 232 | ) |
|
233 | 233 | coreconfigitem( |
|
234 | 234 | b'commands', b'merge.require-rev', default=False, |
|
235 | 235 | ) |
|
236 | 236 | coreconfigitem( |
|
237 | 237 | b'commands', b'push.require-revs', default=False, |
|
238 | 238 | ) |
|
239 | 239 | coreconfigitem( |
|
240 | 240 | b'commands', b'resolve.confirm', default=False, |
|
241 | 241 | ) |
|
242 | 242 | coreconfigitem( |
|
243 | 243 | b'commands', b'resolve.explicit-re-merge', default=False, |
|
244 | 244 | ) |
|
245 | 245 | coreconfigitem( |
|
246 | 246 | b'commands', b'resolve.mark-check', default=b'none', |
|
247 | 247 | ) |
|
248 | 248 | _registerdiffopts(section=b'commands', configprefix=b'revert.interactive.') |
|
249 | 249 | coreconfigitem( |
|
250 | 250 | b'commands', b'show.aliasprefix', default=list, |
|
251 | 251 | ) |
|
252 | 252 | coreconfigitem( |
|
253 | 253 | b'commands', b'status.relative', default=False, |
|
254 | 254 | ) |
|
255 | 255 | coreconfigitem( |
|
256 | 256 | b'commands', b'status.skipstates', default=[], experimental=True, |
|
257 | 257 | ) |
|
258 | 258 | coreconfigitem( |
|
259 | 259 | b'commands', b'status.terse', default=b'', |
|
260 | 260 | ) |
|
261 | 261 | coreconfigitem( |
|
262 | 262 | b'commands', b'status.verbose', default=False, |
|
263 | 263 | ) |
|
264 | 264 | coreconfigitem( |
|
265 | 265 | b'commands', b'update.check', default=None, |
|
266 | 266 | ) |
|
267 | 267 | coreconfigitem( |
|
268 | 268 | b'commands', b'update.requiredest', default=False, |
|
269 | 269 | ) |
|
270 | 270 | coreconfigitem( |
|
271 | 271 | b'committemplate', b'.*', default=None, generic=True, |
|
272 | 272 | ) |
|
273 | 273 | coreconfigitem( |
|
274 | 274 | b'convert', b'bzr.saverev', default=True, |
|
275 | 275 | ) |
|
276 | 276 | coreconfigitem( |
|
277 | 277 | b'convert', b'cvsps.cache', default=True, |
|
278 | 278 | ) |
|
279 | 279 | coreconfigitem( |
|
280 | 280 | b'convert', b'cvsps.fuzz', default=60, |
|
281 | 281 | ) |
|
282 | 282 | coreconfigitem( |
|
283 | 283 | b'convert', b'cvsps.logencoding', default=None, |
|
284 | 284 | ) |
|
285 | 285 | coreconfigitem( |
|
286 | 286 | b'convert', b'cvsps.mergefrom', default=None, |
|
287 | 287 | ) |
|
288 | 288 | coreconfigitem( |
|
289 | 289 | b'convert', b'cvsps.mergeto', default=None, |
|
290 | 290 | ) |
|
291 | 291 | coreconfigitem( |
|
292 | 292 | b'convert', b'git.committeractions', default=lambda: [b'messagedifferent'], |
|
293 | 293 | ) |
|
294 | 294 | coreconfigitem( |
|
295 | 295 | b'convert', b'git.extrakeys', default=list, |
|
296 | 296 | ) |
|
297 | 297 | coreconfigitem( |
|
298 | 298 | b'convert', b'git.findcopiesharder', default=False, |
|
299 | 299 | ) |
|
300 | 300 | coreconfigitem( |
|
301 | 301 | b'convert', b'git.remoteprefix', default=b'remote', |
|
302 | 302 | ) |
|
303 | 303 | coreconfigitem( |
|
304 | 304 | b'convert', b'git.renamelimit', default=400, |
|
305 | 305 | ) |
|
306 | 306 | coreconfigitem( |
|
307 | 307 | b'convert', b'git.saverev', default=True, |
|
308 | 308 | ) |
|
309 | 309 | coreconfigitem( |
|
310 | 310 | b'convert', b'git.similarity', default=50, |
|
311 | 311 | ) |
|
312 | 312 | coreconfigitem( |
|
313 | 313 | b'convert', b'git.skipsubmodules', default=False, |
|
314 | 314 | ) |
|
315 | 315 | coreconfigitem( |
|
316 | 316 | b'convert', b'hg.clonebranches', default=False, |
|
317 | 317 | ) |
|
318 | 318 | coreconfigitem( |
|
319 | 319 | b'convert', b'hg.ignoreerrors', default=False, |
|
320 | 320 | ) |
|
321 | 321 | coreconfigitem( |
|
322 | 322 | b'convert', b'hg.preserve-hash', default=False, |
|
323 | 323 | ) |
|
324 | 324 | coreconfigitem( |
|
325 | 325 | b'convert', b'hg.revs', default=None, |
|
326 | 326 | ) |
|
327 | 327 | coreconfigitem( |
|
328 | 328 | b'convert', b'hg.saverev', default=False, |
|
329 | 329 | ) |
|
330 | 330 | coreconfigitem( |
|
331 | 331 | b'convert', b'hg.sourcename', default=None, |
|
332 | 332 | ) |
|
333 | 333 | coreconfigitem( |
|
334 | 334 | b'convert', b'hg.startrev', default=None, |
|
335 | 335 | ) |
|
336 | 336 | coreconfigitem( |
|
337 | 337 | b'convert', b'hg.tagsbranch', default=b'default', |
|
338 | 338 | ) |
|
339 | 339 | coreconfigitem( |
|
340 | 340 | b'convert', b'hg.usebranchnames', default=True, |
|
341 | 341 | ) |
|
342 | 342 | coreconfigitem( |
|
343 | 343 | b'convert', b'ignoreancestorcheck', default=False, experimental=True, |
|
344 | 344 | ) |
|
345 | 345 | coreconfigitem( |
|
346 | 346 | b'convert', b'localtimezone', default=False, |
|
347 | 347 | ) |
|
348 | 348 | coreconfigitem( |
|
349 | 349 | b'convert', b'p4.encoding', default=dynamicdefault, |
|
350 | 350 | ) |
|
351 | 351 | coreconfigitem( |
|
352 | 352 | b'convert', b'p4.startrev', default=0, |
|
353 | 353 | ) |
|
354 | 354 | coreconfigitem( |
|
355 | 355 | b'convert', b'skiptags', default=False, |
|
356 | 356 | ) |
|
357 | 357 | coreconfigitem( |
|
358 | 358 | b'convert', b'svn.debugsvnlog', default=True, |
|
359 | 359 | ) |
|
360 | 360 | coreconfigitem( |
|
361 | 361 | b'convert', b'svn.trunk', default=None, |
|
362 | 362 | ) |
|
363 | 363 | coreconfigitem( |
|
364 | 364 | b'convert', b'svn.tags', default=None, |
|
365 | 365 | ) |
|
366 | 366 | coreconfigitem( |
|
367 | 367 | b'convert', b'svn.branches', default=None, |
|
368 | 368 | ) |
|
369 | 369 | coreconfigitem( |
|
370 | 370 | b'convert', b'svn.startrev', default=0, |
|
371 | 371 | ) |
|
372 | 372 | coreconfigitem( |
|
373 | 373 | b'debug', b'dirstate.delaywrite', default=0, |
|
374 | 374 | ) |
|
375 | 375 | coreconfigitem( |
|
376 | 376 | b'defaults', b'.*', default=None, generic=True, |
|
377 | 377 | ) |
|
378 | 378 | coreconfigitem( |
|
379 | 379 | b'devel', b'all-warnings', default=False, |
|
380 | 380 | ) |
|
381 | 381 | coreconfigitem( |
|
382 | 382 | b'devel', b'bundle2.debug', default=False, |
|
383 | 383 | ) |
|
384 | 384 | coreconfigitem( |
|
385 | 385 | b'devel', b'bundle.delta', default=b'', |
|
386 | 386 | ) |
|
387 | 387 | coreconfigitem( |
|
388 | 388 | b'devel', b'cache-vfs', default=None, |
|
389 | 389 | ) |
|
390 | 390 | coreconfigitem( |
|
391 | 391 | b'devel', b'check-locks', default=False, |
|
392 | 392 | ) |
|
393 | 393 | coreconfigitem( |
|
394 | 394 | b'devel', b'check-relroot', default=False, |
|
395 | 395 | ) |
|
396 | 396 | coreconfigitem( |
|
397 | 397 | b'devel', b'default-date', default=None, |
|
398 | 398 | ) |
|
399 | 399 | coreconfigitem( |
|
400 | 400 | b'devel', b'deprec-warn', default=False, |
|
401 | 401 | ) |
|
402 | 402 | coreconfigitem( |
|
403 | 403 | b'devel', b'disableloaddefaultcerts', default=False, |
|
404 | 404 | ) |
|
405 | 405 | coreconfigitem( |
|
406 | 406 | b'devel', b'warn-empty-changegroup', default=False, |
|
407 | 407 | ) |
|
408 | 408 | coreconfigitem( |
|
409 | 409 | b'devel', b'legacy.exchange', default=list, |
|
410 | 410 | ) |
|
411 | 411 | coreconfigitem( |
|
412 | 412 | b'devel', b'persistent-nodemap', default=False, |
|
413 | 413 | ) |
|
414 | 414 | coreconfigitem( |
|
415 | 415 | b'devel', b'servercafile', default=b'', |
|
416 | 416 | ) |
|
417 | 417 | coreconfigitem( |
|
418 | 418 | b'devel', b'serverexactprotocol', default=b'', |
|
419 | 419 | ) |
|
420 | 420 | coreconfigitem( |
|
421 | 421 | b'devel', b'serverrequirecert', default=False, |
|
422 | 422 | ) |
|
423 | 423 | coreconfigitem( |
|
424 | 424 | b'devel', b'strip-obsmarkers', default=True, |
|
425 | 425 | ) |
|
426 | 426 | coreconfigitem( |
|
427 | 427 | b'devel', b'warn-config', default=None, |
|
428 | 428 | ) |
|
429 | 429 | coreconfigitem( |
|
430 | 430 | b'devel', b'warn-config-default', default=None, |
|
431 | 431 | ) |
|
432 | 432 | coreconfigitem( |
|
433 | 433 | b'devel', b'user.obsmarker', default=None, |
|
434 | 434 | ) |
|
435 | 435 | coreconfigitem( |
|
436 | 436 | b'devel', b'warn-config-unknown', default=None, |
|
437 | 437 | ) |
|
438 | 438 | coreconfigitem( |
|
439 | 439 | b'devel', b'debug.copies', default=False, |
|
440 | 440 | ) |
|
441 | 441 | coreconfigitem( |
|
442 | 442 | b'devel', b'debug.extensions', default=False, |
|
443 | 443 | ) |
|
444 | 444 | coreconfigitem( |
|
445 | 445 | b'devel', b'debug.repo-filters', default=False, |
|
446 | 446 | ) |
|
447 | 447 | coreconfigitem( |
|
448 | 448 | b'devel', b'debug.peer-request', default=False, |
|
449 | 449 | ) |
|
450 | 450 | coreconfigitem( |
|
451 | 451 | b'devel', b'discovery.randomize', default=True, |
|
452 | 452 | ) |
|
453 | 453 | _registerdiffopts(section=b'diff') |
|
454 | 454 | coreconfigitem( |
|
455 | 455 | b'email', b'bcc', default=None, |
|
456 | 456 | ) |
|
457 | 457 | coreconfigitem( |
|
458 | 458 | b'email', b'cc', default=None, |
|
459 | 459 | ) |
|
460 | 460 | coreconfigitem( |
|
461 | 461 | b'email', b'charsets', default=list, |
|
462 | 462 | ) |
|
463 | 463 | coreconfigitem( |
|
464 | 464 | b'email', b'from', default=None, |
|
465 | 465 | ) |
|
466 | 466 | coreconfigitem( |
|
467 | 467 | b'email', b'method', default=b'smtp', |
|
468 | 468 | ) |
|
469 | 469 | coreconfigitem( |
|
470 | 470 | b'email', b'reply-to', default=None, |
|
471 | 471 | ) |
|
472 | 472 | coreconfigitem( |
|
473 | 473 | b'email', b'to', default=None, |
|
474 | 474 | ) |
|
475 | 475 | coreconfigitem( |
|
476 | 476 | b'experimental', b'archivemetatemplate', default=dynamicdefault, |
|
477 | 477 | ) |
|
478 | 478 | coreconfigitem( |
|
479 | 479 | b'experimental', b'auto-publish', default=b'publish', |
|
480 | 480 | ) |
|
481 | 481 | coreconfigitem( |
|
482 | 482 | b'experimental', b'bundle-phases', default=False, |
|
483 | 483 | ) |
|
484 | 484 | coreconfigitem( |
|
485 | 485 | b'experimental', b'bundle2-advertise', default=True, |
|
486 | 486 | ) |
|
487 | 487 | coreconfigitem( |
|
488 | 488 | b'experimental', b'bundle2-output-capture', default=False, |
|
489 | 489 | ) |
|
490 | 490 | coreconfigitem( |
|
491 | 491 | b'experimental', b'bundle2.pushback', default=False, |
|
492 | 492 | ) |
|
493 | 493 | coreconfigitem( |
|
494 | 494 | b'experimental', b'bundle2lazylocking', default=False, |
|
495 | 495 | ) |
|
496 | 496 | coreconfigitem( |
|
497 | 497 | b'experimental', b'bundlecomplevel', default=None, |
|
498 | 498 | ) |
|
499 | 499 | coreconfigitem( |
|
500 | 500 | b'experimental', b'bundlecomplevel.bzip2', default=None, |
|
501 | 501 | ) |
|
502 | 502 | coreconfigitem( |
|
503 | 503 | b'experimental', b'bundlecomplevel.gzip', default=None, |
|
504 | 504 | ) |
|
505 | 505 | coreconfigitem( |
|
506 | 506 | b'experimental', b'bundlecomplevel.none', default=None, |
|
507 | 507 | ) |
|
508 | 508 | coreconfigitem( |
|
509 | 509 | b'experimental', b'bundlecomplevel.zstd', default=None, |
|
510 | 510 | ) |
|
511 | 511 | coreconfigitem( |
|
512 | 512 | b'experimental', b'changegroup3', default=False, |
|
513 | 513 | ) |
|
514 | 514 | coreconfigitem( |
|
515 | 515 | b'experimental', b'cleanup-as-archived', default=False, |
|
516 | 516 | ) |
|
517 | 517 | coreconfigitem( |
|
518 | 518 | b'experimental', b'clientcompressionengines', default=list, |
|
519 | 519 | ) |
|
520 | 520 | coreconfigitem( |
|
521 | 521 | b'experimental', b'copytrace', default=b'on', |
|
522 | 522 | ) |
|
523 | 523 | coreconfigitem( |
|
524 | 524 | b'experimental', b'copytrace.movecandidateslimit', default=100, |
|
525 | 525 | ) |
|
526 | 526 | coreconfigitem( |
|
527 | 527 | b'experimental', b'copytrace.sourcecommitlimit', default=100, |
|
528 | 528 | ) |
|
529 | 529 | coreconfigitem( |
|
530 | 530 | b'experimental', b'copies.read-from', default=b"filelog-only", |
|
531 | 531 | ) |
|
532 | 532 | coreconfigitem( |
|
533 | 533 | b'experimental', b'copies.write-to', default=b'filelog-only', |
|
534 | 534 | ) |
|
535 | 535 | coreconfigitem( |
|
536 | 536 | b'experimental', b'crecordtest', default=None, |
|
537 | 537 | ) |
|
538 | 538 | coreconfigitem( |
|
539 | 539 | b'experimental', b'directaccess', default=False, |
|
540 | 540 | ) |
|
541 | 541 | coreconfigitem( |
|
542 | 542 | b'experimental', b'directaccess.revnums', default=False, |
|
543 | 543 | ) |
|
544 | 544 | coreconfigitem( |
|
545 | 545 | b'experimental', b'editortmpinhg', default=False, |
|
546 | 546 | ) |
|
547 | 547 | coreconfigitem( |
|
548 | 548 | b'experimental', b'evolution', default=list, |
|
549 | 549 | ) |
|
550 | 550 | coreconfigitem( |
|
551 | 551 | b'experimental', |
|
552 | 552 | b'evolution.allowdivergence', |
|
553 | 553 | default=False, |
|
554 | 554 | alias=[(b'experimental', b'allowdivergence')], |
|
555 | 555 | ) |
|
556 | 556 | coreconfigitem( |
|
557 | 557 | b'experimental', b'evolution.allowunstable', default=None, |
|
558 | 558 | ) |
|
559 | 559 | coreconfigitem( |
|
560 | 560 | b'experimental', b'evolution.createmarkers', default=None, |
|
561 | 561 | ) |
|
562 | 562 | coreconfigitem( |
|
563 | 563 | b'experimental', |
|
564 | 564 | b'evolution.effect-flags', |
|
565 | 565 | default=True, |
|
566 | 566 | alias=[(b'experimental', b'effect-flags')], |
|
567 | 567 | ) |
|
568 | 568 | coreconfigitem( |
|
569 | 569 | b'experimental', b'evolution.exchange', default=None, |
|
570 | 570 | ) |
|
571 | 571 | coreconfigitem( |
|
572 | 572 | b'experimental', b'evolution.bundle-obsmarker', default=False, |
|
573 | 573 | ) |
|
574 | 574 | coreconfigitem( |
|
575 | 575 | b'experimental', b'log.topo', default=False, |
|
576 | 576 | ) |
|
577 | 577 | coreconfigitem( |
|
578 | 578 | b'experimental', b'evolution.report-instabilities', default=True, |
|
579 | 579 | ) |
|
580 | 580 | coreconfigitem( |
|
581 | 581 | b'experimental', b'evolution.track-operation', default=True, |
|
582 | 582 | ) |
|
583 | 583 | # repo-level config to exclude a revset visibility |
|
584 | 584 | # |
|
585 | 585 | # The target use case is to use `share` to expose different subset of the same |
|
586 | 586 | # repository, especially server side. See also `server.view`. |
|
587 | 587 | coreconfigitem( |
|
588 | 588 | b'experimental', b'extra-filter-revs', default=None, |
|
589 | 589 | ) |
|
590 | 590 | coreconfigitem( |
|
591 | 591 | b'experimental', b'maxdeltachainspan', default=-1, |
|
592 | 592 | ) |
|
593 | # tracks files which were undeleted (merge might delete them but we explicitly | |
|
594 | # kept/undeleted them) and creates new filenodes for them | |
|
595 | coreconfigitem( | |
|
596 | b'experimental', b'merge-track-salvaged', default=False, | |
|
597 | ) | |
|
593 | 598 | coreconfigitem( |
|
594 | 599 | b'experimental', b'mergetempdirprefix', default=None, |
|
595 | 600 | ) |
|
596 | 601 | coreconfigitem( |
|
597 | 602 | b'experimental', b'mmapindexthreshold', default=None, |
|
598 | 603 | ) |
|
599 | 604 | coreconfigitem( |
|
600 | 605 | b'experimental', b'narrow', default=False, |
|
601 | 606 | ) |
|
602 | 607 | coreconfigitem( |
|
603 | 608 | b'experimental', b'nonnormalparanoidcheck', default=False, |
|
604 | 609 | ) |
|
605 | 610 | coreconfigitem( |
|
606 | 611 | b'experimental', b'exportableenviron', default=list, |
|
607 | 612 | ) |
|
608 | 613 | coreconfigitem( |
|
609 | 614 | b'experimental', b'extendedheader.index', default=None, |
|
610 | 615 | ) |
|
611 | 616 | coreconfigitem( |
|
612 | 617 | b'experimental', b'extendedheader.similarity', default=False, |
|
613 | 618 | ) |
|
614 | 619 | coreconfigitem( |
|
615 | 620 | b'experimental', b'graphshorten', default=False, |
|
616 | 621 | ) |
|
617 | 622 | coreconfigitem( |
|
618 | 623 | b'experimental', b'graphstyle.parent', default=dynamicdefault, |
|
619 | 624 | ) |
|
620 | 625 | coreconfigitem( |
|
621 | 626 | b'experimental', b'graphstyle.missing', default=dynamicdefault, |
|
622 | 627 | ) |
|
623 | 628 | coreconfigitem( |
|
624 | 629 | b'experimental', b'graphstyle.grandparent', default=dynamicdefault, |
|
625 | 630 | ) |
|
626 | 631 | coreconfigitem( |
|
627 | 632 | b'experimental', b'hook-track-tags', default=False, |
|
628 | 633 | ) |
|
629 | 634 | coreconfigitem( |
|
630 | 635 | b'experimental', b'httppeer.advertise-v2', default=False, |
|
631 | 636 | ) |
|
632 | 637 | coreconfigitem( |
|
633 | 638 | b'experimental', b'httppeer.v2-encoder-order', default=None, |
|
634 | 639 | ) |
|
635 | 640 | coreconfigitem( |
|
636 | 641 | b'experimental', b'httppostargs', default=False, |
|
637 | 642 | ) |
|
638 | 643 | coreconfigitem(b'experimental', b'nointerrupt', default=False) |
|
639 | 644 | coreconfigitem(b'experimental', b'nointerrupt-interactiveonly', default=True) |
|
640 | 645 | |
|
641 | 646 | coreconfigitem( |
|
642 | 647 | b'experimental', b'obsmarkers-exchange-debug', default=False, |
|
643 | 648 | ) |
|
644 | 649 | coreconfigitem( |
|
645 | 650 | b'experimental', b'remotenames', default=False, |
|
646 | 651 | ) |
|
647 | 652 | coreconfigitem( |
|
648 | 653 | b'experimental', b'removeemptydirs', default=True, |
|
649 | 654 | ) |
|
650 | 655 | coreconfigitem( |
|
651 | 656 | b'experimental', b'revert.interactive.select-to-keep', default=False, |
|
652 | 657 | ) |
|
653 | 658 | coreconfigitem( |
|
654 | 659 | b'experimental', b'revisions.prefixhexnode', default=False, |
|
655 | 660 | ) |
|
656 | 661 | coreconfigitem( |
|
657 | 662 | b'experimental', b'revlogv2', default=None, |
|
658 | 663 | ) |
|
659 | 664 | coreconfigitem( |
|
660 | 665 | b'experimental', b'revisions.disambiguatewithin', default=None, |
|
661 | 666 | ) |
|
662 | 667 | coreconfigitem( |
|
663 | 668 | b'experimental', b'rust.index', default=False, |
|
664 | 669 | ) |
|
665 | 670 | coreconfigitem( |
|
666 | 671 | b'experimental', b'server.filesdata.recommended-batch-size', default=50000, |
|
667 | 672 | ) |
|
668 | 673 | coreconfigitem( |
|
669 | 674 | b'experimental', |
|
670 | 675 | b'server.manifestdata.recommended-batch-size', |
|
671 | 676 | default=100000, |
|
672 | 677 | ) |
|
673 | 678 | coreconfigitem( |
|
674 | 679 | b'experimental', b'server.stream-narrow-clones', default=False, |
|
675 | 680 | ) |
|
676 | 681 | coreconfigitem( |
|
677 | 682 | b'experimental', b'single-head-per-branch', default=False, |
|
678 | 683 | ) |
|
679 | 684 | coreconfigitem( |
|
680 | 685 | b'experimental', |
|
681 | 686 | b'single-head-per-branch:account-closed-heads', |
|
682 | 687 | default=False, |
|
683 | 688 | ) |
|
684 | 689 | coreconfigitem( |
|
685 | 690 | b'experimental', b'sshserver.support-v2', default=False, |
|
686 | 691 | ) |
|
687 | 692 | coreconfigitem( |
|
688 | 693 | b'experimental', b'sparse-read', default=False, |
|
689 | 694 | ) |
|
690 | 695 | coreconfigitem( |
|
691 | 696 | b'experimental', b'sparse-read.density-threshold', default=0.50, |
|
692 | 697 | ) |
|
693 | 698 | coreconfigitem( |
|
694 | 699 | b'experimental', b'sparse-read.min-gap-size', default=b'65K', |
|
695 | 700 | ) |
|
696 | 701 | coreconfigitem( |
|
697 | 702 | b'experimental', b'treemanifest', default=False, |
|
698 | 703 | ) |
|
699 | 704 | coreconfigitem( |
|
700 | 705 | b'experimental', b'update.atomic-file', default=False, |
|
701 | 706 | ) |
|
702 | 707 | coreconfigitem( |
|
703 | 708 | b'experimental', b'sshpeer.advertise-v2', default=False, |
|
704 | 709 | ) |
|
705 | 710 | coreconfigitem( |
|
706 | 711 | b'experimental', b'web.apiserver', default=False, |
|
707 | 712 | ) |
|
708 | 713 | coreconfigitem( |
|
709 | 714 | b'experimental', b'web.api.http-v2', default=False, |
|
710 | 715 | ) |
|
711 | 716 | coreconfigitem( |
|
712 | 717 | b'experimental', b'web.api.debugreflect', default=False, |
|
713 | 718 | ) |
|
714 | 719 | coreconfigitem( |
|
715 | 720 | b'experimental', b'worker.wdir-get-thread-safe', default=False, |
|
716 | 721 | ) |
|
717 | 722 | coreconfigitem( |
|
718 | 723 | b'experimental', b'worker.repository-upgrade', default=False, |
|
719 | 724 | ) |
|
720 | 725 | coreconfigitem( |
|
721 | 726 | b'experimental', b'xdiff', default=False, |
|
722 | 727 | ) |
|
723 | 728 | coreconfigitem( |
|
724 | 729 | b'extensions', b'.*', default=None, generic=True, |
|
725 | 730 | ) |
|
726 | 731 | coreconfigitem( |
|
727 | 732 | b'extdata', b'.*', default=None, generic=True, |
|
728 | 733 | ) |
|
729 | 734 | coreconfigitem( |
|
730 | 735 | b'format', b'bookmarks-in-store', default=False, |
|
731 | 736 | ) |
|
732 | 737 | coreconfigitem( |
|
733 | 738 | b'format', b'chunkcachesize', default=None, experimental=True, |
|
734 | 739 | ) |
|
735 | 740 | coreconfigitem( |
|
736 | 741 | b'format', b'dotencode', default=True, |
|
737 | 742 | ) |
|
738 | 743 | coreconfigitem( |
|
739 | 744 | b'format', b'generaldelta', default=False, experimental=True, |
|
740 | 745 | ) |
|
741 | 746 | coreconfigitem( |
|
742 | 747 | b'format', b'manifestcachesize', default=None, experimental=True, |
|
743 | 748 | ) |
|
744 | 749 | coreconfigitem( |
|
745 | 750 | b'format', b'maxchainlen', default=dynamicdefault, experimental=True, |
|
746 | 751 | ) |
|
747 | 752 | coreconfigitem( |
|
748 | 753 | b'format', b'obsstore-version', default=None, |
|
749 | 754 | ) |
|
750 | 755 | coreconfigitem( |
|
751 | 756 | b'format', b'sparse-revlog', default=True, |
|
752 | 757 | ) |
|
753 | 758 | coreconfigitem( |
|
754 | 759 | b'format', |
|
755 | 760 | b'revlog-compression', |
|
756 | 761 | default=lambda: [b'zlib'], |
|
757 | 762 | alias=[(b'experimental', b'format.compression')], |
|
758 | 763 | ) |
|
759 | 764 | coreconfigitem( |
|
760 | 765 | b'format', b'usefncache', default=True, |
|
761 | 766 | ) |
|
762 | 767 | coreconfigitem( |
|
763 | 768 | b'format', b'usegeneraldelta', default=True, |
|
764 | 769 | ) |
|
765 | 770 | coreconfigitem( |
|
766 | 771 | b'format', b'usestore', default=True, |
|
767 | 772 | ) |
|
768 | 773 | # Right now, the only efficient implement of the nodemap logic is in Rust, so |
|
769 | 774 | # the persistent nodemap feature needs to stay experimental as long as the Rust |
|
770 | 775 | # extensions are an experimental feature. |
|
771 | 776 | coreconfigitem( |
|
772 | 777 | b'format', b'use-persistent-nodemap', default=False, experimental=True |
|
773 | 778 | ) |
|
774 | 779 | coreconfigitem( |
|
775 | 780 | b'format', |
|
776 | 781 | b'exp-use-copies-side-data-changeset', |
|
777 | 782 | default=False, |
|
778 | 783 | experimental=True, |
|
779 | 784 | ) |
|
780 | 785 | coreconfigitem( |
|
781 | 786 | b'format', b'exp-use-side-data', default=False, experimental=True, |
|
782 | 787 | ) |
|
783 | 788 | coreconfigitem( |
|
784 | 789 | b'format', b'exp-share-safe', default=False, experimental=True, |
|
785 | 790 | ) |
|
786 | 791 | coreconfigitem( |
|
787 | 792 | b'format', b'internal-phase', default=False, experimental=True, |
|
788 | 793 | ) |
|
789 | 794 | coreconfigitem( |
|
790 | 795 | b'fsmonitor', b'warn_when_unused', default=True, |
|
791 | 796 | ) |
|
792 | 797 | coreconfigitem( |
|
793 | 798 | b'fsmonitor', b'warn_update_file_count', default=50000, |
|
794 | 799 | ) |
|
795 | 800 | coreconfigitem( |
|
796 | 801 | b'fsmonitor', b'warn_update_file_count_rust', default=400000, |
|
797 | 802 | ) |
|
798 | 803 | coreconfigitem( |
|
799 | 804 | b'help', br'hidden-command\..*', default=False, generic=True, |
|
800 | 805 | ) |
|
801 | 806 | coreconfigitem( |
|
802 | 807 | b'help', br'hidden-topic\..*', default=False, generic=True, |
|
803 | 808 | ) |
|
804 | 809 | coreconfigitem( |
|
805 | 810 | b'hooks', b'.*', default=dynamicdefault, generic=True, |
|
806 | 811 | ) |
|
807 | 812 | coreconfigitem( |
|
808 | 813 | b'hgweb-paths', b'.*', default=list, generic=True, |
|
809 | 814 | ) |
|
810 | 815 | coreconfigitem( |
|
811 | 816 | b'hostfingerprints', b'.*', default=list, generic=True, |
|
812 | 817 | ) |
|
813 | 818 | coreconfigitem( |
|
814 | 819 | b'hostsecurity', b'ciphers', default=None, |
|
815 | 820 | ) |
|
816 | 821 | coreconfigitem( |
|
817 | 822 | b'hostsecurity', b'minimumprotocol', default=dynamicdefault, |
|
818 | 823 | ) |
|
819 | 824 | coreconfigitem( |
|
820 | 825 | b'hostsecurity', |
|
821 | 826 | b'.*:minimumprotocol$', |
|
822 | 827 | default=dynamicdefault, |
|
823 | 828 | generic=True, |
|
824 | 829 | ) |
|
825 | 830 | coreconfigitem( |
|
826 | 831 | b'hostsecurity', b'.*:ciphers$', default=dynamicdefault, generic=True, |
|
827 | 832 | ) |
|
828 | 833 | coreconfigitem( |
|
829 | 834 | b'hostsecurity', b'.*:fingerprints$', default=list, generic=True, |
|
830 | 835 | ) |
|
831 | 836 | coreconfigitem( |
|
832 | 837 | b'hostsecurity', b'.*:verifycertsfile$', default=None, generic=True, |
|
833 | 838 | ) |
|
834 | 839 | |
|
835 | 840 | coreconfigitem( |
|
836 | 841 | b'http_proxy', b'always', default=False, |
|
837 | 842 | ) |
|
838 | 843 | coreconfigitem( |
|
839 | 844 | b'http_proxy', b'host', default=None, |
|
840 | 845 | ) |
|
841 | 846 | coreconfigitem( |
|
842 | 847 | b'http_proxy', b'no', default=list, |
|
843 | 848 | ) |
|
844 | 849 | coreconfigitem( |
|
845 | 850 | b'http_proxy', b'passwd', default=None, |
|
846 | 851 | ) |
|
847 | 852 | coreconfigitem( |
|
848 | 853 | b'http_proxy', b'user', default=None, |
|
849 | 854 | ) |
|
850 | 855 | |
|
851 | 856 | coreconfigitem( |
|
852 | 857 | b'http', b'timeout', default=None, |
|
853 | 858 | ) |
|
854 | 859 | |
|
855 | 860 | coreconfigitem( |
|
856 | 861 | b'logtoprocess', b'commandexception', default=None, |
|
857 | 862 | ) |
|
858 | 863 | coreconfigitem( |
|
859 | 864 | b'logtoprocess', b'commandfinish', default=None, |
|
860 | 865 | ) |
|
861 | 866 | coreconfigitem( |
|
862 | 867 | b'logtoprocess', b'command', default=None, |
|
863 | 868 | ) |
|
864 | 869 | coreconfigitem( |
|
865 | 870 | b'logtoprocess', b'develwarn', default=None, |
|
866 | 871 | ) |
|
867 | 872 | coreconfigitem( |
|
868 | 873 | b'logtoprocess', b'uiblocked', default=None, |
|
869 | 874 | ) |
|
870 | 875 | coreconfigitem( |
|
871 | 876 | b'merge', b'checkunknown', default=b'abort', |
|
872 | 877 | ) |
|
873 | 878 | coreconfigitem( |
|
874 | 879 | b'merge', b'checkignored', default=b'abort', |
|
875 | 880 | ) |
|
876 | 881 | coreconfigitem( |
|
877 | 882 | b'experimental', b'merge.checkpathconflicts', default=False, |
|
878 | 883 | ) |
|
879 | 884 | coreconfigitem( |
|
880 | 885 | b'merge', b'followcopies', default=True, |
|
881 | 886 | ) |
|
882 | 887 | coreconfigitem( |
|
883 | 888 | b'merge', b'on-failure', default=b'continue', |
|
884 | 889 | ) |
|
885 | 890 | coreconfigitem( |
|
886 | 891 | b'merge', b'preferancestor', default=lambda: [b'*'], experimental=True, |
|
887 | 892 | ) |
|
888 | 893 | coreconfigitem( |
|
889 | 894 | b'merge', b'strict-capability-check', default=False, |
|
890 | 895 | ) |
|
891 | 896 | coreconfigitem( |
|
892 | 897 | b'merge-tools', b'.*', default=None, generic=True, |
|
893 | 898 | ) |
|
894 | 899 | coreconfigitem( |
|
895 | 900 | b'merge-tools', |
|
896 | 901 | br'.*\.args$', |
|
897 | 902 | default=b"$local $base $other", |
|
898 | 903 | generic=True, |
|
899 | 904 | priority=-1, |
|
900 | 905 | ) |
|
901 | 906 | coreconfigitem( |
|
902 | 907 | b'merge-tools', br'.*\.binary$', default=False, generic=True, priority=-1, |
|
903 | 908 | ) |
|
904 | 909 | coreconfigitem( |
|
905 | 910 | b'merge-tools', br'.*\.check$', default=list, generic=True, priority=-1, |
|
906 | 911 | ) |
|
907 | 912 | coreconfigitem( |
|
908 | 913 | b'merge-tools', |
|
909 | 914 | br'.*\.checkchanged$', |
|
910 | 915 | default=False, |
|
911 | 916 | generic=True, |
|
912 | 917 | priority=-1, |
|
913 | 918 | ) |
|
914 | 919 | coreconfigitem( |
|
915 | 920 | b'merge-tools', |
|
916 | 921 | br'.*\.executable$', |
|
917 | 922 | default=dynamicdefault, |
|
918 | 923 | generic=True, |
|
919 | 924 | priority=-1, |
|
920 | 925 | ) |
|
921 | 926 | coreconfigitem( |
|
922 | 927 | b'merge-tools', br'.*\.fixeol$', default=False, generic=True, priority=-1, |
|
923 | 928 | ) |
|
924 | 929 | coreconfigitem( |
|
925 | 930 | b'merge-tools', br'.*\.gui$', default=False, generic=True, priority=-1, |
|
926 | 931 | ) |
|
927 | 932 | coreconfigitem( |
|
928 | 933 | b'merge-tools', |
|
929 | 934 | br'.*\.mergemarkers$', |
|
930 | 935 | default=b'basic', |
|
931 | 936 | generic=True, |
|
932 | 937 | priority=-1, |
|
933 | 938 | ) |
|
934 | 939 | coreconfigitem( |
|
935 | 940 | b'merge-tools', |
|
936 | 941 | br'.*\.mergemarkertemplate$', |
|
937 | 942 | default=dynamicdefault, # take from ui.mergemarkertemplate |
|
938 | 943 | generic=True, |
|
939 | 944 | priority=-1, |
|
940 | 945 | ) |
|
941 | 946 | coreconfigitem( |
|
942 | 947 | b'merge-tools', br'.*\.priority$', default=0, generic=True, priority=-1, |
|
943 | 948 | ) |
|
944 | 949 | coreconfigitem( |
|
945 | 950 | b'merge-tools', |
|
946 | 951 | br'.*\.premerge$', |
|
947 | 952 | default=dynamicdefault, |
|
948 | 953 | generic=True, |
|
949 | 954 | priority=-1, |
|
950 | 955 | ) |
|
951 | 956 | coreconfigitem( |
|
952 | 957 | b'merge-tools', br'.*\.symlink$', default=False, generic=True, priority=-1, |
|
953 | 958 | ) |
|
954 | 959 | coreconfigitem( |
|
955 | 960 | b'pager', b'attend-.*', default=dynamicdefault, generic=True, |
|
956 | 961 | ) |
|
957 | 962 | coreconfigitem( |
|
958 | 963 | b'pager', b'ignore', default=list, |
|
959 | 964 | ) |
|
960 | 965 | coreconfigitem( |
|
961 | 966 | b'pager', b'pager', default=dynamicdefault, |
|
962 | 967 | ) |
|
963 | 968 | coreconfigitem( |
|
964 | 969 | b'patch', b'eol', default=b'strict', |
|
965 | 970 | ) |
|
966 | 971 | coreconfigitem( |
|
967 | 972 | b'patch', b'fuzz', default=2, |
|
968 | 973 | ) |
|
969 | 974 | coreconfigitem( |
|
970 | 975 | b'paths', b'default', default=None, |
|
971 | 976 | ) |
|
972 | 977 | coreconfigitem( |
|
973 | 978 | b'paths', b'default-push', default=None, |
|
974 | 979 | ) |
|
975 | 980 | coreconfigitem( |
|
976 | 981 | b'paths', b'.*', default=None, generic=True, |
|
977 | 982 | ) |
|
978 | 983 | coreconfigitem( |
|
979 | 984 | b'phases', b'checksubrepos', default=b'follow', |
|
980 | 985 | ) |
|
981 | 986 | coreconfigitem( |
|
982 | 987 | b'phases', b'new-commit', default=b'draft', |
|
983 | 988 | ) |
|
984 | 989 | coreconfigitem( |
|
985 | 990 | b'phases', b'publish', default=True, |
|
986 | 991 | ) |
|
987 | 992 | coreconfigitem( |
|
988 | 993 | b'profiling', b'enabled', default=False, |
|
989 | 994 | ) |
|
990 | 995 | coreconfigitem( |
|
991 | 996 | b'profiling', b'format', default=b'text', |
|
992 | 997 | ) |
|
993 | 998 | coreconfigitem( |
|
994 | 999 | b'profiling', b'freq', default=1000, |
|
995 | 1000 | ) |
|
996 | 1001 | coreconfigitem( |
|
997 | 1002 | b'profiling', b'limit', default=30, |
|
998 | 1003 | ) |
|
999 | 1004 | coreconfigitem( |
|
1000 | 1005 | b'profiling', b'nested', default=0, |
|
1001 | 1006 | ) |
|
1002 | 1007 | coreconfigitem( |
|
1003 | 1008 | b'profiling', b'output', default=None, |
|
1004 | 1009 | ) |
|
1005 | 1010 | coreconfigitem( |
|
1006 | 1011 | b'profiling', b'showmax', default=0.999, |
|
1007 | 1012 | ) |
|
1008 | 1013 | coreconfigitem( |
|
1009 | 1014 | b'profiling', b'showmin', default=dynamicdefault, |
|
1010 | 1015 | ) |
|
1011 | 1016 | coreconfigitem( |
|
1012 | 1017 | b'profiling', b'showtime', default=True, |
|
1013 | 1018 | ) |
|
1014 | 1019 | coreconfigitem( |
|
1015 | 1020 | b'profiling', b'sort', default=b'inlinetime', |
|
1016 | 1021 | ) |
|
1017 | 1022 | coreconfigitem( |
|
1018 | 1023 | b'profiling', b'statformat', default=b'hotpath', |
|
1019 | 1024 | ) |
|
1020 | 1025 | coreconfigitem( |
|
1021 | 1026 | b'profiling', b'time-track', default=dynamicdefault, |
|
1022 | 1027 | ) |
|
1023 | 1028 | coreconfigitem( |
|
1024 | 1029 | b'profiling', b'type', default=b'stat', |
|
1025 | 1030 | ) |
|
1026 | 1031 | coreconfigitem( |
|
1027 | 1032 | b'progress', b'assume-tty', default=False, |
|
1028 | 1033 | ) |
|
1029 | 1034 | coreconfigitem( |
|
1030 | 1035 | b'progress', b'changedelay', default=1, |
|
1031 | 1036 | ) |
|
1032 | 1037 | coreconfigitem( |
|
1033 | 1038 | b'progress', b'clear-complete', default=True, |
|
1034 | 1039 | ) |
|
1035 | 1040 | coreconfigitem( |
|
1036 | 1041 | b'progress', b'debug', default=False, |
|
1037 | 1042 | ) |
|
1038 | 1043 | coreconfigitem( |
|
1039 | 1044 | b'progress', b'delay', default=3, |
|
1040 | 1045 | ) |
|
1041 | 1046 | coreconfigitem( |
|
1042 | 1047 | b'progress', b'disable', default=False, |
|
1043 | 1048 | ) |
|
1044 | 1049 | coreconfigitem( |
|
1045 | 1050 | b'progress', b'estimateinterval', default=60.0, |
|
1046 | 1051 | ) |
|
1047 | 1052 | coreconfigitem( |
|
1048 | 1053 | b'progress', |
|
1049 | 1054 | b'format', |
|
1050 | 1055 | default=lambda: [b'topic', b'bar', b'number', b'estimate'], |
|
1051 | 1056 | ) |
|
1052 | 1057 | coreconfigitem( |
|
1053 | 1058 | b'progress', b'refresh', default=0.1, |
|
1054 | 1059 | ) |
|
1055 | 1060 | coreconfigitem( |
|
1056 | 1061 | b'progress', b'width', default=dynamicdefault, |
|
1057 | 1062 | ) |
|
1058 | 1063 | coreconfigitem( |
|
1059 | 1064 | b'pull', b'confirm', default=False, |
|
1060 | 1065 | ) |
|
1061 | 1066 | coreconfigitem( |
|
1062 | 1067 | b'push', b'pushvars.server', default=False, |
|
1063 | 1068 | ) |
|
1064 | 1069 | coreconfigitem( |
|
1065 | 1070 | b'rewrite', |
|
1066 | 1071 | b'backup-bundle', |
|
1067 | 1072 | default=True, |
|
1068 | 1073 | alias=[(b'ui', b'history-editing-backup')], |
|
1069 | 1074 | ) |
|
1070 | 1075 | coreconfigitem( |
|
1071 | 1076 | b'rewrite', b'update-timestamp', default=False, |
|
1072 | 1077 | ) |
|
1073 | 1078 | coreconfigitem( |
|
1074 | 1079 | b'rewrite', b'empty-successor', default=b'skip', experimental=True, |
|
1075 | 1080 | ) |
|
1076 | 1081 | coreconfigitem( |
|
1077 | 1082 | b'storage', b'new-repo-backend', default=b'revlogv1', experimental=True, |
|
1078 | 1083 | ) |
|
1079 | 1084 | coreconfigitem( |
|
1080 | 1085 | b'storage', |
|
1081 | 1086 | b'revlog.optimize-delta-parent-choice', |
|
1082 | 1087 | default=True, |
|
1083 | 1088 | alias=[(b'format', b'aggressivemergedeltas')], |
|
1084 | 1089 | ) |
|
1085 | 1090 | # experimental as long as rust is experimental (or a C version is implemented) |
|
1086 | 1091 | coreconfigitem( |
|
1087 | 1092 | b'storage', b'revlog.nodemap.mmap', default=True, experimental=True |
|
1088 | 1093 | ) |
|
1089 | 1094 | # experimental as long as format.use-persistent-nodemap is. |
|
1090 | 1095 | coreconfigitem( |
|
1091 | 1096 | b'storage', b'revlog.nodemap.mode', default=b'compat', experimental=True |
|
1092 | 1097 | ) |
|
1093 | 1098 | coreconfigitem( |
|
1094 | 1099 | b'storage', b'revlog.reuse-external-delta', default=True, |
|
1095 | 1100 | ) |
|
1096 | 1101 | coreconfigitem( |
|
1097 | 1102 | b'storage', b'revlog.reuse-external-delta-parent', default=None, |
|
1098 | 1103 | ) |
|
1099 | 1104 | coreconfigitem( |
|
1100 | 1105 | b'storage', b'revlog.zlib.level', default=None, |
|
1101 | 1106 | ) |
|
1102 | 1107 | coreconfigitem( |
|
1103 | 1108 | b'storage', b'revlog.zstd.level', default=None, |
|
1104 | 1109 | ) |
|
1105 | 1110 | coreconfigitem( |
|
1106 | 1111 | b'server', b'bookmarks-pushkey-compat', default=True, |
|
1107 | 1112 | ) |
|
1108 | 1113 | coreconfigitem( |
|
1109 | 1114 | b'server', b'bundle1', default=True, |
|
1110 | 1115 | ) |
|
1111 | 1116 | coreconfigitem( |
|
1112 | 1117 | b'server', b'bundle1gd', default=None, |
|
1113 | 1118 | ) |
|
1114 | 1119 | coreconfigitem( |
|
1115 | 1120 | b'server', b'bundle1.pull', default=None, |
|
1116 | 1121 | ) |
|
1117 | 1122 | coreconfigitem( |
|
1118 | 1123 | b'server', b'bundle1gd.pull', default=None, |
|
1119 | 1124 | ) |
|
1120 | 1125 | coreconfigitem( |
|
1121 | 1126 | b'server', b'bundle1.push', default=None, |
|
1122 | 1127 | ) |
|
1123 | 1128 | coreconfigitem( |
|
1124 | 1129 | b'server', b'bundle1gd.push', default=None, |
|
1125 | 1130 | ) |
|
1126 | 1131 | coreconfigitem( |
|
1127 | 1132 | b'server', |
|
1128 | 1133 | b'bundle2.stream', |
|
1129 | 1134 | default=True, |
|
1130 | 1135 | alias=[(b'experimental', b'bundle2.stream')], |
|
1131 | 1136 | ) |
|
1132 | 1137 | coreconfigitem( |
|
1133 | 1138 | b'server', b'compressionengines', default=list, |
|
1134 | 1139 | ) |
|
1135 | 1140 | coreconfigitem( |
|
1136 | 1141 | b'server', b'concurrent-push-mode', default=b'check-related', |
|
1137 | 1142 | ) |
|
1138 | 1143 | coreconfigitem( |
|
1139 | 1144 | b'server', b'disablefullbundle', default=False, |
|
1140 | 1145 | ) |
|
1141 | 1146 | coreconfigitem( |
|
1142 | 1147 | b'server', b'maxhttpheaderlen', default=1024, |
|
1143 | 1148 | ) |
|
1144 | 1149 | coreconfigitem( |
|
1145 | 1150 | b'server', b'pullbundle', default=False, |
|
1146 | 1151 | ) |
|
1147 | 1152 | coreconfigitem( |
|
1148 | 1153 | b'server', b'preferuncompressed', default=False, |
|
1149 | 1154 | ) |
|
1150 | 1155 | coreconfigitem( |
|
1151 | 1156 | b'server', b'streamunbundle', default=False, |
|
1152 | 1157 | ) |
|
1153 | 1158 | coreconfigitem( |
|
1154 | 1159 | b'server', b'uncompressed', default=True, |
|
1155 | 1160 | ) |
|
1156 | 1161 | coreconfigitem( |
|
1157 | 1162 | b'server', b'uncompressedallowsecret', default=False, |
|
1158 | 1163 | ) |
|
1159 | 1164 | coreconfigitem( |
|
1160 | 1165 | b'server', b'view', default=b'served', |
|
1161 | 1166 | ) |
|
1162 | 1167 | coreconfigitem( |
|
1163 | 1168 | b'server', b'validate', default=False, |
|
1164 | 1169 | ) |
|
1165 | 1170 | coreconfigitem( |
|
1166 | 1171 | b'server', b'zliblevel', default=-1, |
|
1167 | 1172 | ) |
|
1168 | 1173 | coreconfigitem( |
|
1169 | 1174 | b'server', b'zstdlevel', default=3, |
|
1170 | 1175 | ) |
|
1171 | 1176 | coreconfigitem( |
|
1172 | 1177 | b'share', b'pool', default=None, |
|
1173 | 1178 | ) |
|
1174 | 1179 | coreconfigitem( |
|
1175 | 1180 | b'share', b'poolnaming', default=b'identity', |
|
1176 | 1181 | ) |
|
1177 | 1182 | coreconfigitem( |
|
1178 | 1183 | b'shelve', b'maxbackups', default=10, |
|
1179 | 1184 | ) |
|
1180 | 1185 | coreconfigitem( |
|
1181 | 1186 | b'smtp', b'host', default=None, |
|
1182 | 1187 | ) |
|
1183 | 1188 | coreconfigitem( |
|
1184 | 1189 | b'smtp', b'local_hostname', default=None, |
|
1185 | 1190 | ) |
|
1186 | 1191 | coreconfigitem( |
|
1187 | 1192 | b'smtp', b'password', default=None, |
|
1188 | 1193 | ) |
|
1189 | 1194 | coreconfigitem( |
|
1190 | 1195 | b'smtp', b'port', default=dynamicdefault, |
|
1191 | 1196 | ) |
|
1192 | 1197 | coreconfigitem( |
|
1193 | 1198 | b'smtp', b'tls', default=b'none', |
|
1194 | 1199 | ) |
|
1195 | 1200 | coreconfigitem( |
|
1196 | 1201 | b'smtp', b'username', default=None, |
|
1197 | 1202 | ) |
|
1198 | 1203 | coreconfigitem( |
|
1199 | 1204 | b'sparse', b'missingwarning', default=True, experimental=True, |
|
1200 | 1205 | ) |
|
1201 | 1206 | coreconfigitem( |
|
1202 | 1207 | b'subrepos', |
|
1203 | 1208 | b'allowed', |
|
1204 | 1209 | default=dynamicdefault, # to make backporting simpler |
|
1205 | 1210 | ) |
|
1206 | 1211 | coreconfigitem( |
|
1207 | 1212 | b'subrepos', b'hg:allowed', default=dynamicdefault, |
|
1208 | 1213 | ) |
|
1209 | 1214 | coreconfigitem( |
|
1210 | 1215 | b'subrepos', b'git:allowed', default=dynamicdefault, |
|
1211 | 1216 | ) |
|
1212 | 1217 | coreconfigitem( |
|
1213 | 1218 | b'subrepos', b'svn:allowed', default=dynamicdefault, |
|
1214 | 1219 | ) |
|
1215 | 1220 | coreconfigitem( |
|
1216 | 1221 | b'templates', b'.*', default=None, generic=True, |
|
1217 | 1222 | ) |
|
1218 | 1223 | coreconfigitem( |
|
1219 | 1224 | b'templateconfig', b'.*', default=dynamicdefault, generic=True, |
|
1220 | 1225 | ) |
|
1221 | 1226 | coreconfigitem( |
|
1222 | 1227 | b'trusted', b'groups', default=list, |
|
1223 | 1228 | ) |
|
1224 | 1229 | coreconfigitem( |
|
1225 | 1230 | b'trusted', b'users', default=list, |
|
1226 | 1231 | ) |
|
1227 | 1232 | coreconfigitem( |
|
1228 | 1233 | b'ui', b'_usedassubrepo', default=False, |
|
1229 | 1234 | ) |
|
1230 | 1235 | coreconfigitem( |
|
1231 | 1236 | b'ui', b'allowemptycommit', default=False, |
|
1232 | 1237 | ) |
|
1233 | 1238 | coreconfigitem( |
|
1234 | 1239 | b'ui', b'archivemeta', default=True, |
|
1235 | 1240 | ) |
|
1236 | 1241 | coreconfigitem( |
|
1237 | 1242 | b'ui', b'askusername', default=False, |
|
1238 | 1243 | ) |
|
1239 | 1244 | coreconfigitem( |
|
1240 | 1245 | b'ui', b'available-memory', default=None, |
|
1241 | 1246 | ) |
|
1242 | 1247 | |
|
1243 | 1248 | coreconfigitem( |
|
1244 | 1249 | b'ui', b'clonebundlefallback', default=False, |
|
1245 | 1250 | ) |
|
1246 | 1251 | coreconfigitem( |
|
1247 | 1252 | b'ui', b'clonebundleprefers', default=list, |
|
1248 | 1253 | ) |
|
1249 | 1254 | coreconfigitem( |
|
1250 | 1255 | b'ui', b'clonebundles', default=True, |
|
1251 | 1256 | ) |
|
1252 | 1257 | coreconfigitem( |
|
1253 | 1258 | b'ui', b'color', default=b'auto', |
|
1254 | 1259 | ) |
|
1255 | 1260 | coreconfigitem( |
|
1256 | 1261 | b'ui', b'commitsubrepos', default=False, |
|
1257 | 1262 | ) |
|
1258 | 1263 | coreconfigitem( |
|
1259 | 1264 | b'ui', b'debug', default=False, |
|
1260 | 1265 | ) |
|
1261 | 1266 | coreconfigitem( |
|
1262 | 1267 | b'ui', b'debugger', default=None, |
|
1263 | 1268 | ) |
|
1264 | 1269 | coreconfigitem( |
|
1265 | 1270 | b'ui', b'editor', default=dynamicdefault, |
|
1266 | 1271 | ) |
|
1267 | 1272 | coreconfigitem( |
|
1268 | 1273 | b'ui', b'fallbackencoding', default=None, |
|
1269 | 1274 | ) |
|
1270 | 1275 | coreconfigitem( |
|
1271 | 1276 | b'ui', b'forcecwd', default=None, |
|
1272 | 1277 | ) |
|
1273 | 1278 | coreconfigitem( |
|
1274 | 1279 | b'ui', b'forcemerge', default=None, |
|
1275 | 1280 | ) |
|
1276 | 1281 | coreconfigitem( |
|
1277 | 1282 | b'ui', b'formatdebug', default=False, |
|
1278 | 1283 | ) |
|
1279 | 1284 | coreconfigitem( |
|
1280 | 1285 | b'ui', b'formatjson', default=False, |
|
1281 | 1286 | ) |
|
1282 | 1287 | coreconfigitem( |
|
1283 | 1288 | b'ui', b'formatted', default=None, |
|
1284 | 1289 | ) |
|
1285 | 1290 | coreconfigitem( |
|
1286 | 1291 | b'ui', b'graphnodetemplate', default=None, |
|
1287 | 1292 | ) |
|
1288 | 1293 | coreconfigitem( |
|
1289 | 1294 | b'ui', b'interactive', default=None, |
|
1290 | 1295 | ) |
|
1291 | 1296 | coreconfigitem( |
|
1292 | 1297 | b'ui', b'interface', default=None, |
|
1293 | 1298 | ) |
|
1294 | 1299 | coreconfigitem( |
|
1295 | 1300 | b'ui', b'interface.chunkselector', default=None, |
|
1296 | 1301 | ) |
|
1297 | 1302 | coreconfigitem( |
|
1298 | 1303 | b'ui', b'large-file-limit', default=10000000, |
|
1299 | 1304 | ) |
|
1300 | 1305 | coreconfigitem( |
|
1301 | 1306 | b'ui', b'logblockedtimes', default=False, |
|
1302 | 1307 | ) |
|
1303 | 1308 | coreconfigitem( |
|
1304 | 1309 | b'ui', b'logtemplate', default=None, |
|
1305 | 1310 | ) |
|
1306 | 1311 | coreconfigitem( |
|
1307 | 1312 | b'ui', b'merge', default=None, |
|
1308 | 1313 | ) |
|
1309 | 1314 | coreconfigitem( |
|
1310 | 1315 | b'ui', b'mergemarkers', default=b'basic', |
|
1311 | 1316 | ) |
|
1312 | 1317 | coreconfigitem( |
|
1313 | 1318 | b'ui', |
|
1314 | 1319 | b'mergemarkertemplate', |
|
1315 | 1320 | default=( |
|
1316 | 1321 | b'{node|short} ' |
|
1317 | 1322 | b'{ifeq(tags, "tip", "", ' |
|
1318 | 1323 | b'ifeq(tags, "", "", "{tags} "))}' |
|
1319 | 1324 | b'{if(bookmarks, "{bookmarks} ")}' |
|
1320 | 1325 | b'{ifeq(branch, "default", "", "{branch} ")}' |
|
1321 | 1326 | b'- {author|user}: {desc|firstline}' |
|
1322 | 1327 | ), |
|
1323 | 1328 | ) |
|
1324 | 1329 | coreconfigitem( |
|
1325 | 1330 | b'ui', b'message-output', default=b'stdio', |
|
1326 | 1331 | ) |
|
1327 | 1332 | coreconfigitem( |
|
1328 | 1333 | b'ui', b'nontty', default=False, |
|
1329 | 1334 | ) |
|
1330 | 1335 | coreconfigitem( |
|
1331 | 1336 | b'ui', b'origbackuppath', default=None, |
|
1332 | 1337 | ) |
|
1333 | 1338 | coreconfigitem( |
|
1334 | 1339 | b'ui', b'paginate', default=True, |
|
1335 | 1340 | ) |
|
1336 | 1341 | coreconfigitem( |
|
1337 | 1342 | b'ui', b'patch', default=None, |
|
1338 | 1343 | ) |
|
1339 | 1344 | coreconfigitem( |
|
1340 | 1345 | b'ui', b'pre-merge-tool-output-template', default=None, |
|
1341 | 1346 | ) |
|
1342 | 1347 | coreconfigitem( |
|
1343 | 1348 | b'ui', b'portablefilenames', default=b'warn', |
|
1344 | 1349 | ) |
|
1345 | 1350 | coreconfigitem( |
|
1346 | 1351 | b'ui', b'promptecho', default=False, |
|
1347 | 1352 | ) |
|
1348 | 1353 | coreconfigitem( |
|
1349 | 1354 | b'ui', b'quiet', default=False, |
|
1350 | 1355 | ) |
|
1351 | 1356 | coreconfigitem( |
|
1352 | 1357 | b'ui', b'quietbookmarkmove', default=False, |
|
1353 | 1358 | ) |
|
1354 | 1359 | coreconfigitem( |
|
1355 | 1360 | b'ui', b'relative-paths', default=b'legacy', |
|
1356 | 1361 | ) |
|
1357 | 1362 | coreconfigitem( |
|
1358 | 1363 | b'ui', b'remotecmd', default=b'hg', |
|
1359 | 1364 | ) |
|
1360 | 1365 | coreconfigitem( |
|
1361 | 1366 | b'ui', b'report_untrusted', default=True, |
|
1362 | 1367 | ) |
|
1363 | 1368 | coreconfigitem( |
|
1364 | 1369 | b'ui', b'rollback', default=True, |
|
1365 | 1370 | ) |
|
1366 | 1371 | coreconfigitem( |
|
1367 | 1372 | b'ui', b'signal-safe-lock', default=True, |
|
1368 | 1373 | ) |
|
1369 | 1374 | coreconfigitem( |
|
1370 | 1375 | b'ui', b'slash', default=False, |
|
1371 | 1376 | ) |
|
1372 | 1377 | coreconfigitem( |
|
1373 | 1378 | b'ui', b'ssh', default=b'ssh', |
|
1374 | 1379 | ) |
|
1375 | 1380 | coreconfigitem( |
|
1376 | 1381 | b'ui', b'ssherrorhint', default=None, |
|
1377 | 1382 | ) |
|
1378 | 1383 | coreconfigitem( |
|
1379 | 1384 | b'ui', b'statuscopies', default=False, |
|
1380 | 1385 | ) |
|
1381 | 1386 | coreconfigitem( |
|
1382 | 1387 | b'ui', b'strict', default=False, |
|
1383 | 1388 | ) |
|
1384 | 1389 | coreconfigitem( |
|
1385 | 1390 | b'ui', b'style', default=b'', |
|
1386 | 1391 | ) |
|
1387 | 1392 | coreconfigitem( |
|
1388 | 1393 | b'ui', b'supportcontact', default=None, |
|
1389 | 1394 | ) |
|
1390 | 1395 | coreconfigitem( |
|
1391 | 1396 | b'ui', b'textwidth', default=78, |
|
1392 | 1397 | ) |
|
1393 | 1398 | coreconfigitem( |
|
1394 | 1399 | b'ui', b'timeout', default=b'600', |
|
1395 | 1400 | ) |
|
1396 | 1401 | coreconfigitem( |
|
1397 | 1402 | b'ui', b'timeout.warn', default=0, |
|
1398 | 1403 | ) |
|
1399 | 1404 | coreconfigitem( |
|
1400 | 1405 | b'ui', b'timestamp-output', default=False, |
|
1401 | 1406 | ) |
|
1402 | 1407 | coreconfigitem( |
|
1403 | 1408 | b'ui', b'traceback', default=False, |
|
1404 | 1409 | ) |
|
1405 | 1410 | coreconfigitem( |
|
1406 | 1411 | b'ui', b'tweakdefaults', default=False, |
|
1407 | 1412 | ) |
|
1408 | 1413 | coreconfigitem(b'ui', b'username', alias=[(b'ui', b'user')]) |
|
1409 | 1414 | coreconfigitem( |
|
1410 | 1415 | b'ui', b'verbose', default=False, |
|
1411 | 1416 | ) |
|
1412 | 1417 | coreconfigitem( |
|
1413 | 1418 | b'verify', b'skipflags', default=None, |
|
1414 | 1419 | ) |
|
1415 | 1420 | coreconfigitem( |
|
1416 | 1421 | b'web', b'allowbz2', default=False, |
|
1417 | 1422 | ) |
|
1418 | 1423 | coreconfigitem( |
|
1419 | 1424 | b'web', b'allowgz', default=False, |
|
1420 | 1425 | ) |
|
1421 | 1426 | coreconfigitem( |
|
1422 | 1427 | b'web', b'allow-pull', alias=[(b'web', b'allowpull')], default=True, |
|
1423 | 1428 | ) |
|
1424 | 1429 | coreconfigitem( |
|
1425 | 1430 | b'web', b'allow-push', alias=[(b'web', b'allow_push')], default=list, |
|
1426 | 1431 | ) |
|
1427 | 1432 | coreconfigitem( |
|
1428 | 1433 | b'web', b'allowzip', default=False, |
|
1429 | 1434 | ) |
|
1430 | 1435 | coreconfigitem( |
|
1431 | 1436 | b'web', b'archivesubrepos', default=False, |
|
1432 | 1437 | ) |
|
1433 | 1438 | coreconfigitem( |
|
1434 | 1439 | b'web', b'cache', default=True, |
|
1435 | 1440 | ) |
|
1436 | 1441 | coreconfigitem( |
|
1437 | 1442 | b'web', b'comparisoncontext', default=5, |
|
1438 | 1443 | ) |
|
1439 | 1444 | coreconfigitem( |
|
1440 | 1445 | b'web', b'contact', default=None, |
|
1441 | 1446 | ) |
|
1442 | 1447 | coreconfigitem( |
|
1443 | 1448 | b'web', b'deny_push', default=list, |
|
1444 | 1449 | ) |
|
1445 | 1450 | coreconfigitem( |
|
1446 | 1451 | b'web', b'guessmime', default=False, |
|
1447 | 1452 | ) |
|
1448 | 1453 | coreconfigitem( |
|
1449 | 1454 | b'web', b'hidden', default=False, |
|
1450 | 1455 | ) |
|
1451 | 1456 | coreconfigitem( |
|
1452 | 1457 | b'web', b'labels', default=list, |
|
1453 | 1458 | ) |
|
1454 | 1459 | coreconfigitem( |
|
1455 | 1460 | b'web', b'logoimg', default=b'hglogo.png', |
|
1456 | 1461 | ) |
|
1457 | 1462 | coreconfigitem( |
|
1458 | 1463 | b'web', b'logourl', default=b'https://mercurial-scm.org/', |
|
1459 | 1464 | ) |
|
1460 | 1465 | coreconfigitem( |
|
1461 | 1466 | b'web', b'accesslog', default=b'-', |
|
1462 | 1467 | ) |
|
1463 | 1468 | coreconfigitem( |
|
1464 | 1469 | b'web', b'address', default=b'', |
|
1465 | 1470 | ) |
|
1466 | 1471 | coreconfigitem( |
|
1467 | 1472 | b'web', b'allow-archive', alias=[(b'web', b'allow_archive')], default=list, |
|
1468 | 1473 | ) |
|
1469 | 1474 | coreconfigitem( |
|
1470 | 1475 | b'web', b'allow_read', default=list, |
|
1471 | 1476 | ) |
|
1472 | 1477 | coreconfigitem( |
|
1473 | 1478 | b'web', b'baseurl', default=None, |
|
1474 | 1479 | ) |
|
1475 | 1480 | coreconfigitem( |
|
1476 | 1481 | b'web', b'cacerts', default=None, |
|
1477 | 1482 | ) |
|
1478 | 1483 | coreconfigitem( |
|
1479 | 1484 | b'web', b'certificate', default=None, |
|
1480 | 1485 | ) |
|
1481 | 1486 | coreconfigitem( |
|
1482 | 1487 | b'web', b'collapse', default=False, |
|
1483 | 1488 | ) |
|
1484 | 1489 | coreconfigitem( |
|
1485 | 1490 | b'web', b'csp', default=None, |
|
1486 | 1491 | ) |
|
1487 | 1492 | coreconfigitem( |
|
1488 | 1493 | b'web', b'deny_read', default=list, |
|
1489 | 1494 | ) |
|
1490 | 1495 | coreconfigitem( |
|
1491 | 1496 | b'web', b'descend', default=True, |
|
1492 | 1497 | ) |
|
1493 | 1498 | coreconfigitem( |
|
1494 | 1499 | b'web', b'description', default=b"", |
|
1495 | 1500 | ) |
|
1496 | 1501 | coreconfigitem( |
|
1497 | 1502 | b'web', b'encoding', default=lambda: encoding.encoding, |
|
1498 | 1503 | ) |
|
1499 | 1504 | coreconfigitem( |
|
1500 | 1505 | b'web', b'errorlog', default=b'-', |
|
1501 | 1506 | ) |
|
1502 | 1507 | coreconfigitem( |
|
1503 | 1508 | b'web', b'ipv6', default=False, |
|
1504 | 1509 | ) |
|
1505 | 1510 | coreconfigitem( |
|
1506 | 1511 | b'web', b'maxchanges', default=10, |
|
1507 | 1512 | ) |
|
1508 | 1513 | coreconfigitem( |
|
1509 | 1514 | b'web', b'maxfiles', default=10, |
|
1510 | 1515 | ) |
|
1511 | 1516 | coreconfigitem( |
|
1512 | 1517 | b'web', b'maxshortchanges', default=60, |
|
1513 | 1518 | ) |
|
1514 | 1519 | coreconfigitem( |
|
1515 | 1520 | b'web', b'motd', default=b'', |
|
1516 | 1521 | ) |
|
1517 | 1522 | coreconfigitem( |
|
1518 | 1523 | b'web', b'name', default=dynamicdefault, |
|
1519 | 1524 | ) |
|
1520 | 1525 | coreconfigitem( |
|
1521 | 1526 | b'web', b'port', default=8000, |
|
1522 | 1527 | ) |
|
1523 | 1528 | coreconfigitem( |
|
1524 | 1529 | b'web', b'prefix', default=b'', |
|
1525 | 1530 | ) |
|
1526 | 1531 | coreconfigitem( |
|
1527 | 1532 | b'web', b'push_ssl', default=True, |
|
1528 | 1533 | ) |
|
1529 | 1534 | coreconfigitem( |
|
1530 | 1535 | b'web', b'refreshinterval', default=20, |
|
1531 | 1536 | ) |
|
1532 | 1537 | coreconfigitem( |
|
1533 | 1538 | b'web', b'server-header', default=None, |
|
1534 | 1539 | ) |
|
1535 | 1540 | coreconfigitem( |
|
1536 | 1541 | b'web', b'static', default=None, |
|
1537 | 1542 | ) |
|
1538 | 1543 | coreconfigitem( |
|
1539 | 1544 | b'web', b'staticurl', default=None, |
|
1540 | 1545 | ) |
|
1541 | 1546 | coreconfigitem( |
|
1542 | 1547 | b'web', b'stripes', default=1, |
|
1543 | 1548 | ) |
|
1544 | 1549 | coreconfigitem( |
|
1545 | 1550 | b'web', b'style', default=b'paper', |
|
1546 | 1551 | ) |
|
1547 | 1552 | coreconfigitem( |
|
1548 | 1553 | b'web', b'templates', default=None, |
|
1549 | 1554 | ) |
|
1550 | 1555 | coreconfigitem( |
|
1551 | 1556 | b'web', b'view', default=b'served', experimental=True, |
|
1552 | 1557 | ) |
|
1553 | 1558 | coreconfigitem( |
|
1554 | 1559 | b'worker', b'backgroundclose', default=dynamicdefault, |
|
1555 | 1560 | ) |
|
1556 | 1561 | # Windows defaults to a limit of 512 open files. A buffer of 128 |
|
1557 | 1562 | # should give us enough headway. |
|
1558 | 1563 | coreconfigitem( |
|
1559 | 1564 | b'worker', b'backgroundclosemaxqueue', default=384, |
|
1560 | 1565 | ) |
|
1561 | 1566 | coreconfigitem( |
|
1562 | 1567 | b'worker', b'backgroundcloseminfilecount', default=2048, |
|
1563 | 1568 | ) |
|
1564 | 1569 | coreconfigitem( |
|
1565 | 1570 | b'worker', b'backgroundclosethreadcount', default=4, |
|
1566 | 1571 | ) |
|
1567 | 1572 | coreconfigitem( |
|
1568 | 1573 | b'worker', b'enabled', default=True, |
|
1569 | 1574 | ) |
|
1570 | 1575 | coreconfigitem( |
|
1571 | 1576 | b'worker', b'numcpus', default=None, |
|
1572 | 1577 | ) |
|
1573 | 1578 | |
|
1574 | 1579 | # Rebase related configuration moved to core because other extension are doing |
|
1575 | 1580 | # strange things. For example, shelve import the extensions to reuse some bit |
|
1576 | 1581 | # without formally loading it. |
|
1577 | 1582 | coreconfigitem( |
|
1578 | 1583 | b'commands', b'rebase.requiredest', default=False, |
|
1579 | 1584 | ) |
|
1580 | 1585 | coreconfigitem( |
|
1581 | 1586 | b'experimental', b'rebaseskipobsolete', default=True, |
|
1582 | 1587 | ) |
|
1583 | 1588 | coreconfigitem( |
|
1584 | 1589 | b'rebase', b'singletransaction', default=False, |
|
1585 | 1590 | ) |
|
1586 | 1591 | coreconfigitem( |
|
1587 | 1592 | b'rebase', b'experimental.inmemory', default=False, |
|
1588 | 1593 | ) |
@@ -1,693 +1,705 b'' | |||
|
1 | #testcases old newfilenode | |
|
2 | ||
|
3 | #if newfilenode | |
|
4 | Enable the config option | |
|
5 | ------------------------ | |
|
6 | ||
|
7 | $ cat >> $HGRCPATH <<EOF | |
|
8 | > [experimental] | |
|
9 | > merge-track-salvaged = True | |
|
10 | > EOF | |
|
11 | #endif | |
|
12 | ||
|
1 | 13 | Criss cross merging |
|
2 | 14 | |
|
3 | 15 | $ hg init criss-cross |
|
4 | 16 | $ cd criss-cross |
|
5 | 17 | $ echo '0 base' > f1 |
|
6 | 18 | $ echo '0 base' > f2 |
|
7 | 19 | $ hg ci -Aqm '0 base' |
|
8 | 20 | |
|
9 | 21 | $ echo '1 first change' > f1 |
|
10 | 22 | $ hg ci -m '1 first change f1' |
|
11 | 23 | |
|
12 | 24 | $ hg up -qr0 |
|
13 | 25 | $ echo '2 first change' > f2 |
|
14 | 26 | $ hg ci -qm '2 first change f2' |
|
15 | 27 | |
|
16 | 28 | $ hg merge -qr 1 |
|
17 | 29 | $ hg ci -m '3 merge' |
|
18 | 30 | |
|
19 | 31 | $ hg up -qr2 |
|
20 | 32 | $ hg merge -qr1 |
|
21 | 33 | $ hg ci -qm '4 merge' |
|
22 | 34 | |
|
23 | 35 | $ echo '5 second change' > f1 |
|
24 | 36 | $ hg ci -m '5 second change f1' |
|
25 | 37 | |
|
26 | 38 | $ hg up -r3 |
|
27 | 39 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
28 | 40 | $ echo '6 second change' > f2 |
|
29 | 41 | $ hg ci -m '6 second change f2' |
|
30 | 42 | |
|
31 | 43 | $ hg log -G |
|
32 | 44 | @ changeset: 6:3b08d01b0ab5 |
|
33 | 45 | | tag: tip |
|
34 | 46 | | parent: 3:cf89f02107e5 |
|
35 | 47 | | user: test |
|
36 | 48 | | date: Thu Jan 01 00:00:00 1970 +0000 |
|
37 | 49 | | summary: 6 second change f2 |
|
38 | 50 | | |
|
39 | 51 | | o changeset: 5:adfe50279922 |
|
40 | 52 | | | user: test |
|
41 | 53 | | | date: Thu Jan 01 00:00:00 1970 +0000 |
|
42 | 54 | | | summary: 5 second change f1 |
|
43 | 55 | | | |
|
44 | 56 | | o changeset: 4:7d3e55501ae6 |
|
45 | 57 | | |\ parent: 2:40663881a6dd |
|
46 | 58 | | | | parent: 1:0f6b37dbe527 |
|
47 | 59 | | | | user: test |
|
48 | 60 | | | | date: Thu Jan 01 00:00:00 1970 +0000 |
|
49 | 61 | | | | summary: 4 merge |
|
50 | 62 | | | | |
|
51 | 63 | o---+ changeset: 3:cf89f02107e5 |
|
52 | 64 | | | | parent: 2:40663881a6dd |
|
53 | 65 | |/ / parent: 1:0f6b37dbe527 |
|
54 | 66 | | | user: test |
|
55 | 67 | | | date: Thu Jan 01 00:00:00 1970 +0000 |
|
56 | 68 | | | summary: 3 merge |
|
57 | 69 | | | |
|
58 | 70 | | o changeset: 2:40663881a6dd |
|
59 | 71 | | | parent: 0:40494bf2444c |
|
60 | 72 | | | user: test |
|
61 | 73 | | | date: Thu Jan 01 00:00:00 1970 +0000 |
|
62 | 74 | | | summary: 2 first change f2 |
|
63 | 75 | | | |
|
64 | 76 | o | changeset: 1:0f6b37dbe527 |
|
65 | 77 | |/ user: test |
|
66 | 78 | | date: Thu Jan 01 00:00:00 1970 +0000 |
|
67 | 79 | | summary: 1 first change f1 |
|
68 | 80 | | |
|
69 | 81 | o changeset: 0:40494bf2444c |
|
70 | 82 | user: test |
|
71 | 83 | date: Thu Jan 01 00:00:00 1970 +0000 |
|
72 | 84 | summary: 0 base |
|
73 | 85 | |
|
74 | 86 | |
|
75 | 87 | $ hg merge -v --debug --tool internal:dump 5 --config merge.preferancestor='!' |
|
76 | 88 | note: using 0f6b37dbe527 as ancestor of 3b08d01b0ab5 and adfe50279922 |
|
77 | 89 | alternatively, use --config merge.preferancestor=40663881a6dd |
|
78 | 90 | resolving manifests |
|
79 | 91 | branchmerge: True, force: False, partial: False |
|
80 | 92 | ancestor: 0f6b37dbe527, local: 3b08d01b0ab5+, remote: adfe50279922 |
|
81 | 93 | f1: remote is newer -> g |
|
82 | 94 | getting f1 |
|
83 | 95 | preserving f2 for resolve of f2 |
|
84 | 96 | f2: versions differ -> m (premerge) |
|
85 | 97 | picked tool ':dump' for f2 (binary False symlink False changedelete False) |
|
86 | 98 | merging f2 |
|
87 | 99 | my f2@3b08d01b0ab5+ other f2@adfe50279922 ancestor f2@0f6b37dbe527 |
|
88 | 100 | f2: versions differ -> m (merge) |
|
89 | 101 | picked tool ':dump' for f2 (binary False symlink False changedelete False) |
|
90 | 102 | my f2@3b08d01b0ab5+ other f2@adfe50279922 ancestor f2@0f6b37dbe527 |
|
91 | 103 | 1 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
92 | 104 | use 'hg resolve' to retry unresolved file merges or 'hg merge --abort' to abandon |
|
93 | 105 | [1] |
|
94 | 106 | |
|
95 | 107 | $ f --dump * |
|
96 | 108 | f1: |
|
97 | 109 | >>> |
|
98 | 110 | 5 second change |
|
99 | 111 | <<< |
|
100 | 112 | f2: |
|
101 | 113 | >>> |
|
102 | 114 | 6 second change |
|
103 | 115 | <<< |
|
104 | 116 | f2.base: |
|
105 | 117 | >>> |
|
106 | 118 | 0 base |
|
107 | 119 | <<< |
|
108 | 120 | f2.local: |
|
109 | 121 | >>> |
|
110 | 122 | 6 second change |
|
111 | 123 | <<< |
|
112 | 124 | f2.orig: |
|
113 | 125 | >>> |
|
114 | 126 | 6 second change |
|
115 | 127 | <<< |
|
116 | 128 | f2.other: |
|
117 | 129 | >>> |
|
118 | 130 | 2 first change |
|
119 | 131 | <<< |
|
120 | 132 | |
|
121 | 133 | $ hg up -qC . |
|
122 | 134 | $ hg merge -v --tool internal:dump 5 --config merge.preferancestor="null 40663881 3b08d" |
|
123 | 135 | note: using 40663881a6dd as ancestor of 3b08d01b0ab5 and adfe50279922 |
|
124 | 136 | alternatively, use --config merge.preferancestor=0f6b37dbe527 |
|
125 | 137 | resolving manifests |
|
126 | 138 | merging f1 |
|
127 | 139 | 0 files updated, 0 files merged, 0 files removed, 1 files unresolved |
|
128 | 140 | use 'hg resolve' to retry unresolved file merges or 'hg merge --abort' to abandon |
|
129 | 141 | [1] |
|
130 | 142 | |
|
131 | 143 | Redo merge with merge.preferancestor="*" to enable bid merge |
|
132 | 144 | |
|
133 | 145 | $ rm f* |
|
134 | 146 | $ hg up -qC . |
|
135 | 147 | $ hg merge -v --debug --tool internal:dump 5 --config merge.preferancestor="*" |
|
136 | 148 | note: merging 3b08d01b0ab5+ and adfe50279922 using bids from ancestors 0f6b37dbe527 and 40663881a6dd |
|
137 | 149 | |
|
138 | 150 | calculating bids for ancestor 0f6b37dbe527 |
|
139 | 151 | resolving manifests |
|
140 | 152 | branchmerge: True, force: False, partial: False |
|
141 | 153 | ancestor: 0f6b37dbe527, local: 3b08d01b0ab5+, remote: adfe50279922 |
|
142 | 154 | f1: remote is newer -> g |
|
143 | 155 | f2: versions differ -> m |
|
144 | 156 | |
|
145 | 157 | calculating bids for ancestor 40663881a6dd |
|
146 | 158 | resolving manifests |
|
147 | 159 | branchmerge: True, force: False, partial: False |
|
148 | 160 | ancestor: 40663881a6dd, local: 3b08d01b0ab5+, remote: adfe50279922 |
|
149 | 161 | f1: versions differ -> m |
|
150 | 162 | f2: remote unchanged -> k |
|
151 | 163 | |
|
152 | 164 | auction for merging merge bids (2 ancestors) |
|
153 | 165 | list of bids for f1: |
|
154 | 166 | remote is newer -> g |
|
155 | 167 | versions differ -> m |
|
156 | 168 | f1: picking 'get' action |
|
157 | 169 | list of bids for f2: |
|
158 | 170 | remote unchanged -> k |
|
159 | 171 | versions differ -> m |
|
160 | 172 | f2: picking 'keep' action |
|
161 | 173 | end of auction |
|
162 | 174 | |
|
163 | 175 | f1: remote is newer -> g |
|
164 | 176 | getting f1 |
|
165 | 177 | f2: remote unchanged -> k |
|
166 | 178 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
167 | 179 | (branch merge, don't forget to commit) |
|
168 | 180 | |
|
169 | 181 | $ f --dump * |
|
170 | 182 | f1: |
|
171 | 183 | >>> |
|
172 | 184 | 5 second change |
|
173 | 185 | <<< |
|
174 | 186 | f2: |
|
175 | 187 | >>> |
|
176 | 188 | 6 second change |
|
177 | 189 | <<< |
|
178 | 190 | |
|
179 | 191 | |
|
180 | 192 | The other way around: |
|
181 | 193 | |
|
182 | 194 | $ hg up -C -r5 |
|
183 | 195 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
184 | 196 | $ hg merge -v --debug --config merge.preferancestor="*" |
|
185 | 197 | note: merging adfe50279922+ and 3b08d01b0ab5 using bids from ancestors 0f6b37dbe527 and 40663881a6dd |
|
186 | 198 | |
|
187 | 199 | calculating bids for ancestor 0f6b37dbe527 |
|
188 | 200 | resolving manifests |
|
189 | 201 | branchmerge: True, force: False, partial: False |
|
190 | 202 | ancestor: 0f6b37dbe527, local: adfe50279922+, remote: 3b08d01b0ab5 |
|
191 | 203 | f1: remote unchanged -> k |
|
192 | 204 | f2: versions differ -> m |
|
193 | 205 | |
|
194 | 206 | calculating bids for ancestor 40663881a6dd |
|
195 | 207 | resolving manifests |
|
196 | 208 | branchmerge: True, force: False, partial: False |
|
197 | 209 | ancestor: 40663881a6dd, local: adfe50279922+, remote: 3b08d01b0ab5 |
|
198 | 210 | f1: versions differ -> m |
|
199 | 211 | f2: remote is newer -> g |
|
200 | 212 | |
|
201 | 213 | auction for merging merge bids (2 ancestors) |
|
202 | 214 | list of bids for f1: |
|
203 | 215 | remote unchanged -> k |
|
204 | 216 | versions differ -> m |
|
205 | 217 | f1: picking 'keep' action |
|
206 | 218 | list of bids for f2: |
|
207 | 219 | remote is newer -> g |
|
208 | 220 | versions differ -> m |
|
209 | 221 | f2: picking 'get' action |
|
210 | 222 | end of auction |
|
211 | 223 | |
|
212 | 224 | f2: remote is newer -> g |
|
213 | 225 | getting f2 |
|
214 | 226 | f1: remote unchanged -> k |
|
215 | 227 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
216 | 228 | (branch merge, don't forget to commit) |
|
217 | 229 | |
|
218 | 230 | $ f --dump * |
|
219 | 231 | f1: |
|
220 | 232 | >>> |
|
221 | 233 | 5 second change |
|
222 | 234 | <<< |
|
223 | 235 | f2: |
|
224 | 236 | >>> |
|
225 | 237 | 6 second change |
|
226 | 238 | <<< |
|
227 | 239 | |
|
228 | 240 | Verify how the output looks and and how verbose it is: |
|
229 | 241 | |
|
230 | 242 | $ hg up -qC |
|
231 | 243 | $ hg merge |
|
232 | 244 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
233 | 245 | (branch merge, don't forget to commit) |
|
234 | 246 | |
|
235 | 247 | $ hg up -qC tip |
|
236 | 248 | $ hg merge -v |
|
237 | 249 | note: merging 3b08d01b0ab5+ and adfe50279922 using bids from ancestors 0f6b37dbe527 and 40663881a6dd |
|
238 | 250 | |
|
239 | 251 | calculating bids for ancestor 0f6b37dbe527 |
|
240 | 252 | resolving manifests |
|
241 | 253 | |
|
242 | 254 | calculating bids for ancestor 40663881a6dd |
|
243 | 255 | resolving manifests |
|
244 | 256 | |
|
245 | 257 | auction for merging merge bids (2 ancestors) |
|
246 | 258 | f1: picking 'get' action |
|
247 | 259 | f2: picking 'keep' action |
|
248 | 260 | end of auction |
|
249 | 261 | |
|
250 | 262 | getting f1 |
|
251 | 263 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
252 | 264 | (branch merge, don't forget to commit) |
|
253 | 265 | |
|
254 | 266 | $ hg up -qC |
|
255 | 267 | $ hg merge -v --debug --config merge.preferancestor="*" |
|
256 | 268 | note: merging 3b08d01b0ab5+ and adfe50279922 using bids from ancestors 0f6b37dbe527 and 40663881a6dd |
|
257 | 269 | |
|
258 | 270 | calculating bids for ancestor 0f6b37dbe527 |
|
259 | 271 | resolving manifests |
|
260 | 272 | branchmerge: True, force: False, partial: False |
|
261 | 273 | ancestor: 0f6b37dbe527, local: 3b08d01b0ab5+, remote: adfe50279922 |
|
262 | 274 | f1: remote is newer -> g |
|
263 | 275 | f2: versions differ -> m |
|
264 | 276 | |
|
265 | 277 | calculating bids for ancestor 40663881a6dd |
|
266 | 278 | resolving manifests |
|
267 | 279 | branchmerge: True, force: False, partial: False |
|
268 | 280 | ancestor: 40663881a6dd, local: 3b08d01b0ab5+, remote: adfe50279922 |
|
269 | 281 | f1: versions differ -> m |
|
270 | 282 | f2: remote unchanged -> k |
|
271 | 283 | |
|
272 | 284 | auction for merging merge bids (2 ancestors) |
|
273 | 285 | list of bids for f1: |
|
274 | 286 | remote is newer -> g |
|
275 | 287 | versions differ -> m |
|
276 | 288 | f1: picking 'get' action |
|
277 | 289 | list of bids for f2: |
|
278 | 290 | remote unchanged -> k |
|
279 | 291 | versions differ -> m |
|
280 | 292 | f2: picking 'keep' action |
|
281 | 293 | end of auction |
|
282 | 294 | |
|
283 | 295 | f1: remote is newer -> g |
|
284 | 296 | getting f1 |
|
285 | 297 | f2: remote unchanged -> k |
|
286 | 298 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
287 | 299 | (branch merge, don't forget to commit) |
|
288 | 300 | |
|
289 | 301 | Test the greatest common ancestor returning multiple changesets |
|
290 | 302 | |
|
291 | 303 | $ hg log -r 'heads(commonancestors(head()))' |
|
292 | 304 | changeset: 1:0f6b37dbe527 |
|
293 | 305 | user: test |
|
294 | 306 | date: Thu Jan 01 00:00:00 1970 +0000 |
|
295 | 307 | summary: 1 first change f1 |
|
296 | 308 | |
|
297 | 309 | changeset: 2:40663881a6dd |
|
298 | 310 | parent: 0:40494bf2444c |
|
299 | 311 | user: test |
|
300 | 312 | date: Thu Jan 01 00:00:00 1970 +0000 |
|
301 | 313 | summary: 2 first change f2 |
|
302 | 314 | |
|
303 | 315 | |
|
304 | 316 | $ cd .. |
|
305 | 317 | |
|
306 | 318 | http://stackoverflow.com/questions/9350005/how-do-i-specify-a-merge-base-to-use-in-a-hg-merge/9430810 |
|
307 | 319 | |
|
308 | 320 | $ hg init ancestor-merging |
|
309 | 321 | $ cd ancestor-merging |
|
310 | 322 | $ echo a > x |
|
311 | 323 | $ hg commit -A -m a x |
|
312 | 324 | $ hg update -q 0 |
|
313 | 325 | $ echo b >> x |
|
314 | 326 | $ hg commit -m b |
|
315 | 327 | $ hg update -q 0 |
|
316 | 328 | $ echo c >> x |
|
317 | 329 | $ hg commit -qm c |
|
318 | 330 | $ hg update -q 1 |
|
319 | 331 | $ hg merge -q --tool internal:local 2 |
|
320 | 332 | $ echo c >> x |
|
321 | 333 | $ hg commit -m bc |
|
322 | 334 | $ hg update -q 2 |
|
323 | 335 | $ hg merge -q --tool internal:local 1 |
|
324 | 336 | $ echo b >> x |
|
325 | 337 | $ hg commit -qm cb |
|
326 | 338 | |
|
327 | 339 | $ hg merge --config merge.preferancestor='!' |
|
328 | 340 | note: using 70008a2163f6 as ancestor of 0d355fdef312 and 4b8b546a3eef |
|
329 | 341 | alternatively, use --config merge.preferancestor=b211bbc6eb3c |
|
330 | 342 | merging x |
|
331 | 343 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
332 | 344 | (branch merge, don't forget to commit) |
|
333 | 345 | $ cat x |
|
334 | 346 | a |
|
335 | 347 | c |
|
336 | 348 | b |
|
337 | 349 | c |
|
338 | 350 | |
|
339 | 351 | $ hg up -qC . |
|
340 | 352 | |
|
341 | 353 | $ hg merge --config merge.preferancestor=b211bbc6eb3c |
|
342 | 354 | note: using b211bbc6eb3c as ancestor of 0d355fdef312 and 4b8b546a3eef |
|
343 | 355 | alternatively, use --config merge.preferancestor=70008a2163f6 |
|
344 | 356 | merging x |
|
345 | 357 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
346 | 358 | (branch merge, don't forget to commit) |
|
347 | 359 | $ cat x |
|
348 | 360 | a |
|
349 | 361 | b |
|
350 | 362 | c |
|
351 | 363 | b |
|
352 | 364 | |
|
353 | 365 | $ hg up -qC . |
|
354 | 366 | |
|
355 | 367 | $ hg merge -v --config merge.preferancestor="*" |
|
356 | 368 | note: merging 0d355fdef312+ and 4b8b546a3eef using bids from ancestors 70008a2163f6 and b211bbc6eb3c |
|
357 | 369 | |
|
358 | 370 | calculating bids for ancestor 70008a2163f6 |
|
359 | 371 | resolving manifests |
|
360 | 372 | |
|
361 | 373 | calculating bids for ancestor b211bbc6eb3c |
|
362 | 374 | resolving manifests |
|
363 | 375 | |
|
364 | 376 | auction for merging merge bids (2 ancestors) |
|
365 | 377 | x: multiple bids for merge action: |
|
366 | 378 | versions differ -> m |
|
367 | 379 | versions differ -> m |
|
368 | 380 | x: ambiguous merge - picked m action |
|
369 | 381 | end of auction |
|
370 | 382 | |
|
371 | 383 | merging x |
|
372 | 384 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
373 | 385 | (branch merge, don't forget to commit) |
|
374 | 386 | $ cat x |
|
375 | 387 | a |
|
376 | 388 | c |
|
377 | 389 | b |
|
378 | 390 | c |
|
379 | 391 | |
|
380 | 392 | Verify that the old context ancestor works with / despite preferancestor: |
|
381 | 393 | |
|
382 | 394 | $ hg log -r 'ancestor(head())' --config merge.preferancestor=1 -T '{rev}\n' |
|
383 | 395 | 1 |
|
384 | 396 | $ hg log -r 'ancestor(head())' --config merge.preferancestor=2 -T '{rev}\n' |
|
385 | 397 | 2 |
|
386 | 398 | $ hg log -r 'ancestor(head())' --config merge.preferancestor=3 -T '{rev}\n' |
|
387 | 399 | 1 |
|
388 | 400 | $ hg log -r 'ancestor(head())' --config merge.preferancestor='1337 * - 2' -T '{rev}\n' |
|
389 | 401 | 2 |
|
390 | 402 | |
|
391 | 403 | $ cd .. |
|
392 | 404 | |
|
393 | 405 | $ hg init issue5020 |
|
394 | 406 | $ cd issue5020 |
|
395 | 407 | |
|
396 | 408 | $ echo a > noop |
|
397 | 409 | $ hg ci -qAm initial |
|
398 | 410 | |
|
399 | 411 | $ echo b > noop |
|
400 | 412 | $ hg ci -qAm 'uninteresting change' |
|
401 | 413 | |
|
402 | 414 | $ hg up -q 0 |
|
403 | 415 | $ mkdir d1 |
|
404 | 416 | $ echo a > d1/a |
|
405 | 417 | $ echo b > d1/b |
|
406 | 418 | $ hg ci -qAm 'add d1/a and d1/b' |
|
407 | 419 | |
|
408 | 420 | $ hg merge -q 1 |
|
409 | 421 | $ hg rm d1/a |
|
410 | 422 | $ hg mv -q d1 d2 |
|
411 | 423 | $ hg ci -qm 'merge while removing d1/a and moving d1/b to d2/b' |
|
412 | 424 | |
|
413 | 425 | $ hg up -q 1 |
|
414 | 426 | $ hg merge -q 2 |
|
415 | 427 | $ hg ci -qm 'merge (no changes while merging)' |
|
416 | 428 | $ hg log -G -T '{rev}:{node|short} {desc}' |
|
417 | 429 | @ 4:c0ef19750a22 merge (no changes while merging) |
|
418 | 430 | |\ |
|
419 | 431 | +---o 3:6ca01f7342b9 merge while removing d1/a and moving d1/b to d2/b |
|
420 | 432 | | |/ |
|
421 | 433 | | o 2:154e6000f54e add d1/a and d1/b |
|
422 | 434 | | | |
|
423 | 435 | o | 1:11b5b303e36c uninteresting change |
|
424 | 436 | |/ |
|
425 | 437 | o 0:7b54db1ebf33 initial |
|
426 | 438 | |
|
427 | 439 | $ hg merge 3 --debug |
|
428 | 440 | note: merging c0ef19750a22+ and 6ca01f7342b9 using bids from ancestors 11b5b303e36c and 154e6000f54e |
|
429 | 441 | |
|
430 | 442 | calculating bids for ancestor 11b5b303e36c |
|
431 | 443 | resolving manifests |
|
432 | 444 | branchmerge: True, force: False, partial: False |
|
433 | 445 | ancestor: 11b5b303e36c, local: c0ef19750a22+, remote: 6ca01f7342b9 |
|
434 | 446 | d1/a: ancestor missing, remote missing -> kn |
|
435 | 447 | d1/b: ancestor missing, remote missing -> kn |
|
436 | 448 | d2/b: remote created -> g |
|
437 | 449 | |
|
438 | 450 | calculating bids for ancestor 154e6000f54e |
|
439 | 451 | unmatched files in other: |
|
440 | 452 | d2/b |
|
441 | 453 | all copies found (* = to merge, ! = divergent, % = renamed and deleted): |
|
442 | 454 | on remote side: |
|
443 | 455 | src: 'd1/b' -> dst: 'd2/b' |
|
444 | 456 | checking for directory renames |
|
445 | 457 | discovered dir src: 'd1/' -> dst: 'd2/' |
|
446 | 458 | resolving manifests |
|
447 | 459 | branchmerge: True, force: False, partial: False |
|
448 | 460 | ancestor: 154e6000f54e, local: c0ef19750a22+, remote: 6ca01f7342b9 |
|
449 | 461 | d1/a: other deleted -> r |
|
450 | 462 | d1/b: other deleted -> r |
|
451 | 463 | d2/b: remote created -> g |
|
452 | 464 | |
|
453 | 465 | auction for merging merge bids (2 ancestors) |
|
454 | 466 | list of bids for d1/a: |
|
455 | 467 | ancestor missing, remote missing -> kn |
|
456 | 468 | other deleted -> r |
|
457 | 469 | d1/a: picking 'keep new' action |
|
458 | 470 | list of bids for d1/b: |
|
459 | 471 | ancestor missing, remote missing -> kn |
|
460 | 472 | other deleted -> r |
|
461 | 473 | d1/b: picking 'keep new' action |
|
462 | 474 | list of bids for d2/b: |
|
463 | 475 | remote created -> g |
|
464 | 476 | remote created -> g |
|
465 | 477 | d2/b: consensus for g |
|
466 | 478 | end of auction |
|
467 | 479 | |
|
468 | 480 | d2/b: remote created -> g |
|
469 | 481 | getting d2/b |
|
470 | 482 | d1/a: ancestor missing, remote missing -> kn |
|
471 | 483 | d1/b: ancestor missing, remote missing -> kn |
|
472 | 484 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
473 | 485 | (branch merge, don't forget to commit) |
|
474 | 486 | |
|
475 | 487 | |
|
476 | 488 | Check that removal reversion does not go unotified |
|
477 | 489 | ================================================== |
|
478 | 490 | |
|
479 | 491 | On a merge, a file can be removed and user can revert that removal. This means |
|
480 | 492 | user has made an explicit choice of keeping the file or reverting the removal |
|
481 | 493 | even though the merge algo wanted to remove it. |
|
482 | 494 | Based on this, when we do criss cross merges, merge algorithm should not again |
|
483 | 495 | choose to remove the file as in one of the merges, user made an explicit choice |
|
484 | 496 | to revert the removal. |
|
485 | 497 | Following test cases demonstrate how merge algo does not take in account |
|
486 | 498 | explicit choices made by users to revert the removal and on criss-cross merging |
|
487 | 499 | removes the file again. |
|
488 | 500 | |
|
489 | 501 | "Simple" case where the filenode changes |
|
490 | 502 | ---------------------------------------- |
|
491 | 503 | |
|
492 | 504 | $ cd .. |
|
493 | 505 | $ hg init criss-cross-merge-reversal-with-update |
|
494 | 506 | $ cd criss-cross-merge-reversal-with-update |
|
495 | 507 | $ echo the-file > the-file |
|
496 | 508 | $ echo other-file > other-file |
|
497 | 509 | $ hg add the-file other-file |
|
498 | 510 | $ hg ci -m 'root-commit' |
|
499 | 511 | $ echo foo >> the-file |
|
500 | 512 | $ echo bar >> other-file |
|
501 | 513 | $ hg ci -m 'updating-both-file' |
|
502 | 514 | $ hg up 'desc("root-commit")' |
|
503 | 515 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
504 | 516 | $ hg rm the-file |
|
505 | 517 | $ hg ci -m 'delete-the-file' |
|
506 | 518 | created new head |
|
507 | 519 | $ hg log -G -T '{node|short} {desc}\n' |
|
508 | 520 | @ 7801bc9b9899 delete-the-file |
|
509 | 521 | | |
|
510 | 522 | | o 9b610631ab29 updating-both-file |
|
511 | 523 | |/ |
|
512 | 524 | o 955800955977 root-commit |
|
513 | 525 | |
|
514 | 526 | |
|
515 | 527 | Do all the merge combination (from the deleted or the update side Γ keeping and deleting the file |
|
516 | 528 | |
|
517 | 529 | $ hg update 'desc("delete-the-file")' |
|
518 | 530 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
519 | 531 | $ hg merge 'desc("updating-both-file")' -t :local |
|
520 | 532 | 1 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
521 | 533 | (branch merge, don't forget to commit) |
|
522 | 534 | $ hg ci -m "merge-deleting-the-file-from-deleted" |
|
523 | 535 | $ hg manifest |
|
524 | 536 | other-file |
|
525 | 537 | |
|
526 | 538 | $ hg update 'desc("updating-both-file")' |
|
527 | 539 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
528 | 540 | $ hg merge 'desc("delete-the-file")' -t :other |
|
529 | 541 | 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
|
530 | 542 | (branch merge, don't forget to commit) |
|
531 | 543 | $ hg ci -m "merge-deleting-the-file-from-updated" |
|
532 | 544 | created new head |
|
533 | 545 | $ hg manifest |
|
534 | 546 | other-file |
|
535 | 547 | |
|
536 | 548 | $ hg update 'desc("delete-the-file")' |
|
537 | 549 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
538 | 550 | $ hg merge 'desc("updating-both-file")' -t :other |
|
539 | 551 | 1 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
540 | 552 | (branch merge, don't forget to commit) |
|
541 | 553 | $ hg ci -m "merge-keeping-the-file-from-deleted" |
|
542 | 554 | created new head |
|
543 | 555 | $ hg manifest |
|
544 | 556 | other-file |
|
545 | 557 | the-file |
|
546 | 558 | |
|
547 | 559 | $ hg update 'desc("updating-both-file")' |
|
548 | 560 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
549 | 561 | $ hg merge 'desc("delete-the-file")' -t :local |
|
550 | 562 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved |
|
551 | 563 | (branch merge, don't forget to commit) |
|
552 | 564 | $ hg ci -m "merge-keeping-the-file-from-updated" |
|
553 | 565 | created new head |
|
554 | 566 | $ hg manifest |
|
555 | 567 | other-file |
|
556 | 568 | the-file |
|
557 | 569 | |
|
558 | 570 | There the resulting merge together (leading to criss cross situation). Check |
|
559 | 571 | the conflict is properly detected. |
|
560 | 572 | |
|
561 | 573 | (merging two deletion together β no conflict) |
|
562 | 574 | |
|
563 | 575 | $ hg update --clean 'desc("merge-deleting-the-file-from-deleted")' |
|
564 | 576 | 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
|
565 | 577 | $ hg merge 'desc("merge-deleting-the-file-from-updated")' |
|
566 | 578 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
567 | 579 | (branch merge, don't forget to commit) |
|
568 | 580 | $ ls -1 |
|
569 | 581 | other-file |
|
570 | 582 | |
|
571 | 583 | (merging a deletion with keeping β conflict) |
|
572 | 584 | BROKEN: this should result in conflict |
|
573 | 585 | |
|
574 | 586 | $ hg update --clean 'desc("merge-deleting-the-file-from-deleted")' |
|
575 | 587 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
576 | 588 | $ hg merge 'desc("merge-keeping-the-file-from-deleted")' |
|
577 | 589 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
578 | 590 | (branch merge, don't forget to commit) |
|
579 | 591 | $ ls -1 |
|
580 | 592 | other-file |
|
581 | 593 | |
|
582 | 594 | (merging a deletion with keeping β conflict) |
|
583 | 595 | BROKEN: this should result in conflict |
|
584 | 596 | |
|
585 | 597 | $ hg update --clean 'desc("merge-deleting-the-file-from-deleted")' |
|
586 | 598 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
587 | 599 | $ hg merge 'desc("merge-keeping-the-file-from-updated")' |
|
588 | 600 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
589 | 601 | (branch merge, don't forget to commit) |
|
590 | 602 | $ ls -1 |
|
591 | 603 | other-file |
|
592 | 604 | |
|
593 | 605 | (merging two deletion together β no conflict) |
|
594 | 606 | |
|
595 | 607 | $ hg update --clean 'desc("merge-deleting-the-file-from-updated")' |
|
596 | 608 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
597 | 609 | $ hg merge 'desc("merge-deleting-the-file-from-deleted")' |
|
598 | 610 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
599 | 611 | (branch merge, don't forget to commit) |
|
600 | 612 | $ ls -1 |
|
601 | 613 | other-file |
|
602 | 614 | |
|
603 | 615 | (merging a deletion with keeping β conflict) |
|
604 | 616 | BROKEN: this should result in conflict |
|
605 | 617 | |
|
606 | 618 | $ hg update --clean 'desc("merge-deleting-the-file-from-updated")' |
|
607 | 619 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
608 | 620 | $ hg merge 'desc("merge-keeping-the-file-from-deleted")' |
|
609 | 621 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
610 | 622 | (branch merge, don't forget to commit) |
|
611 | 623 | $ ls -1 |
|
612 | 624 | other-file |
|
613 | 625 | |
|
614 | 626 | (merging a deletion with keeping β conflict) |
|
615 | 627 | BROKEN: this should result in conflict |
|
616 | 628 | |
|
617 | 629 | $ hg update --clean 'desc("merge-deleting-the-file-from-updated")' |
|
618 | 630 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
619 | 631 | $ hg merge 'desc("merge-keeping-the-file-from-updated")' |
|
620 | 632 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
621 | 633 | (branch merge, don't forget to commit) |
|
622 | 634 | $ ls -1 |
|
623 | 635 | other-file |
|
624 | 636 | |
|
625 | 637 | (merging two "keeping" together β no conflict) |
|
626 | 638 | |
|
627 | 639 | $ hg update --clean 'desc("merge-keeping-the-file-from-updated")' |
|
628 | 640 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
629 | 641 | $ hg merge 'desc("merge-keeping-the-file-from-deleted")' |
|
630 | 642 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
631 | 643 | (branch merge, don't forget to commit) |
|
632 | 644 | $ ls -1 |
|
633 | 645 | other-file |
|
634 | 646 | the-file |
|
635 | 647 | |
|
636 | 648 | (merging a deletion with keeping β conflict) |
|
637 | 649 | BROKEN: this should result in conflict |
|
638 | 650 | |
|
639 | 651 | $ hg update --clean 'desc("merge-keeping-the-file-from-updated")' |
|
640 | 652 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
641 | 653 | $ hg merge 'desc("merge-deleted-the-file-from-deleted")' |
|
642 | 654 | abort: empty revision set |
|
643 | 655 | [255] |
|
644 | 656 | $ ls -1 |
|
645 | 657 | other-file |
|
646 | 658 | the-file |
|
647 | 659 | |
|
648 | 660 | (merging a deletion with keeping β conflict) |
|
649 | 661 | BROKEN: this should result in conflict |
|
650 | 662 | |
|
651 | 663 | $ hg update --clean 'desc("merge-keeping-the-file-from-updated")' |
|
652 | 664 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
653 | 665 | $ hg merge 'desc("merge-deleting-the-file-from-updated")' |
|
654 | 666 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
655 | 667 | (branch merge, don't forget to commit) |
|
656 | 668 | $ ls -1 |
|
657 | 669 | other-file |
|
658 | 670 | the-file |
|
659 | 671 | |
|
660 | 672 | (merging two "keeping" together β no conflict) |
|
661 | 673 | |
|
662 | 674 | $ hg update --clean 'desc("merge-keeping-the-file-from-deleted")' |
|
663 | 675 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
664 | 676 | $ hg merge 'desc("merge-keeping-the-file-from-updated")' |
|
665 | 677 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
666 | 678 | (branch merge, don't forget to commit) |
|
667 | 679 | $ ls -1 |
|
668 | 680 | other-file |
|
669 | 681 | the-file |
|
670 | 682 | |
|
671 | 683 | (merging a deletion with keeping β conflict) |
|
672 | 684 | BROKEN: this should result in conflict |
|
673 | 685 | |
|
674 | 686 | $ hg update --clean 'desc("merge-keeping-the-file-from-deleted")' |
|
675 | 687 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
676 | 688 | $ hg merge 'desc("merge-deleted-the-file-from-deleted")' |
|
677 | 689 | abort: empty revision set |
|
678 | 690 | [255] |
|
679 | 691 | $ ls -1 |
|
680 | 692 | other-file |
|
681 | 693 | the-file |
|
682 | 694 | |
|
683 | 695 | (merging a deletion with keeping β conflict) |
|
684 | 696 | BROKEN: this should result in conflict |
|
685 | 697 | |
|
686 | 698 | $ hg update --clean 'desc("merge-keeping-the-file-from-deleted")' |
|
687 | 699 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
688 | 700 | $ hg merge 'desc("merge-deleting-the-file-from-updated")' |
|
689 | 701 | 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
690 | 702 | (branch merge, don't forget to commit) |
|
691 | 703 | $ ls -1 |
|
692 | 704 | other-file |
|
693 | 705 | the-file |
General Comments 0
You need to be logged in to leave comments.
Login now