Mercurial > hg
annotate mercurial/configitems.py @ 33473:b78c59e41a65
configitems: register the 'progress.width' config
author | Boris Feld <boris.feld@octobus.net> |
---|---|
date | Fri, 30 Jun 2017 03:44:05 +0200 |
parents | d0869a6e83ab |
children | c514b4fb5e27 |
rev | line source |
---|---|
32983
0d757af1ea67
configitems: add a basic class to hold config item information
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
1 # configitems.py - centralized declaration of configuration option |
0d757af1ea67
configitems: add a basic class to hold config item information
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
2 # |
0d757af1ea67
configitems: add a basic class to hold config item information
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
3 # Copyright 2017 Pierre-Yves David <pierre-yves.david@octobus.net> |
0d757af1ea67
configitems: add a basic class to hold config item information
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
4 # |
0d757af1ea67
configitems: add a basic class to hold config item information
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
5 # This software may be used and distributed according to the terms of the |
0d757af1ea67
configitems: add a basic class to hold config item information
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
6 # GNU General Public License version 2 or any later version. |
0d757af1ea67
configitems: add a basic class to hold config item information
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
7 |
0d757af1ea67
configitems: add a basic class to hold config item information
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
8 from __future__ import absolute_import |
0d757af1ea67
configitems: add a basic class to hold config item information
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
9 |
33131
c2ca511c4771
configitems: extract the logic to build a registrar on any configtable
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33061
diff
changeset
|
10 import functools |
c2ca511c4771
configitems: extract the logic to build a registrar on any configtable
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33061
diff
changeset
|
11 |
32984
6d983e8af49c
configitems: introduce a central registry for config option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32983
diff
changeset
|
12 from . import ( |
6d983e8af49c
configitems: introduce a central registry for config option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32983
diff
changeset
|
13 error, |
6d983e8af49c
configitems: introduce a central registry for config option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32983
diff
changeset
|
14 ) |
6d983e8af49c
configitems: introduce a central registry for config option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32983
diff
changeset
|
15 |
33132
c467d13334ee
configitems: add an official API for extensions to register config item
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33131
diff
changeset
|
16 def loadconfigtable(ui, extname, configtable): |
c467d13334ee
configitems: add an official API for extensions to register config item
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33131
diff
changeset
|
17 """update config item known to the ui with the extension ones""" |
c467d13334ee
configitems: add an official API for extensions to register config item
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33131
diff
changeset
|
18 for section, items in configtable.items(): |
33133
bf1292c057ef
configitems: add a devel warning for extensions items overiding core one
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33132
diff
changeset
|
19 knownitems = ui._knownconfig.setdefault(section, {}) |
bf1292c057ef
configitems: add a devel warning for extensions items overiding core one
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33132
diff
changeset
|
20 knownkeys = set(knownitems) |
bf1292c057ef
configitems: add a devel warning for extensions items overiding core one
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33132
diff
changeset
|
21 newkeys = set(items) |
bf1292c057ef
configitems: add a devel warning for extensions items overiding core one
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33132
diff
changeset
|
22 for key in sorted(knownkeys & newkeys): |
bf1292c057ef
configitems: add a devel warning for extensions items overiding core one
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33132
diff
changeset
|
23 msg = "extension '%s' overwrite config item '%s.%s'" |
bf1292c057ef
configitems: add a devel warning for extensions items overiding core one
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33132
diff
changeset
|
24 msg %= (extname, section, key) |
bf1292c057ef
configitems: add a devel warning for extensions items overiding core one
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33132
diff
changeset
|
25 ui.develwarn(msg, config='warn-config') |
bf1292c057ef
configitems: add a devel warning for extensions items overiding core one
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33132
diff
changeset
|
26 |
bf1292c057ef
configitems: add a devel warning for extensions items overiding core one
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33132
diff
changeset
|
27 knownitems.update(items) |
33132
c467d13334ee
configitems: add an official API for extensions to register config item
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33131
diff
changeset
|
28 |
32983
0d757af1ea67
configitems: add a basic class to hold config item information
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
29 class configitem(object): |
0d757af1ea67
configitems: add a basic class to hold config item information
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
30 """represent a known config item |
0d757af1ea67
configitems: add a basic class to hold config item information
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
31 |
0d757af1ea67
configitems: add a basic class to hold config item information
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
32 :section: the official config section where to find this item, |
0d757af1ea67
configitems: add a basic class to hold config item information
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
33 :name: the official name within the section, |
0d757af1ea67
configitems: add a basic class to hold config item information
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
34 :default: default value for this item, |
33329
e714159860fd
configitems: add alias support in config
David Demelier <demelier.david@gmail.com>
parents:
33250
diff
changeset
|
35 :alias: optional list of tuples as alternatives. |
32983
0d757af1ea67
configitems: add a basic class to hold config item information
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
36 """ |
0d757af1ea67
configitems: add a basic class to hold config item information
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
37 |
33329
e714159860fd
configitems: add alias support in config
David Demelier <demelier.david@gmail.com>
parents:
33250
diff
changeset
|
38 def __init__(self, section, name, default=None, alias=()): |
32983
0d757af1ea67
configitems: add a basic class to hold config item information
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
39 self.section = section |
0d757af1ea67
configitems: add a basic class to hold config item information
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
40 self.name = name |
0d757af1ea67
configitems: add a basic class to hold config item information
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff
changeset
|
41 self.default = default |
33329
e714159860fd
configitems: add alias support in config
David Demelier <demelier.david@gmail.com>
parents:
33250
diff
changeset
|
42 self.alias = list(alias) |
32984
6d983e8af49c
configitems: introduce a central registry for config option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32983
diff
changeset
|
43 |
6d983e8af49c
configitems: introduce a central registry for config option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32983
diff
changeset
|
44 coreitems = {} |
6d983e8af49c
configitems: introduce a central registry for config option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32983
diff
changeset
|
45 |
33131
c2ca511c4771
configitems: extract the logic to build a registrar on any configtable
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33061
diff
changeset
|
46 def _register(configtable, *args, **kwargs): |
32984
6d983e8af49c
configitems: introduce a central registry for config option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32983
diff
changeset
|
47 item = configitem(*args, **kwargs) |
33131
c2ca511c4771
configitems: extract the logic to build a registrar on any configtable
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33061
diff
changeset
|
48 section = configtable.setdefault(item.section, {}) |
32984
6d983e8af49c
configitems: introduce a central registry for config option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32983
diff
changeset
|
49 if item.name in section: |
6d983e8af49c
configitems: introduce a central registry for config option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32983
diff
changeset
|
50 msg = "duplicated config item registration for '%s.%s'" |
6d983e8af49c
configitems: introduce a central registry for config option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32983
diff
changeset
|
51 raise error.ProgrammingError(msg % (item.section, item.name)) |
6d983e8af49c
configitems: introduce a central registry for config option
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32983
diff
changeset
|
52 section[item.name] = item |
32986
2529e2ae9f4c
configitems: register 'ui.quiet' as first example
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32984
diff
changeset
|
53 |
33471
d74141ccfd8b
configitems: handle case were the default value is not static
Boris Feld <boris.feld@octobus.net>
parents:
33329
diff
changeset
|
54 # special value for case where the default is derived from other values |
d74141ccfd8b
configitems: handle case were the default value is not static
Boris Feld <boris.feld@octobus.net>
parents:
33329
diff
changeset
|
55 dynamicdefault = object() |
d74141ccfd8b
configitems: handle case were the default value is not static
Boris Feld <boris.feld@octobus.net>
parents:
33329
diff
changeset
|
56 |
32986
2529e2ae9f4c
configitems: register 'ui.quiet' as first example
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32984
diff
changeset
|
57 # Registering actual config items |
2529e2ae9f4c
configitems: register 'ui.quiet' as first example
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32984
diff
changeset
|
58 |
33131
c2ca511c4771
configitems: extract the logic to build a registrar on any configtable
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33061
diff
changeset
|
59 def getitemregister(configtable): |
c2ca511c4771
configitems: extract the logic to build a registrar on any configtable
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33061
diff
changeset
|
60 return functools.partial(_register, configtable) |
c2ca511c4771
configitems: extract the logic to build a registrar on any configtable
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33061
diff
changeset
|
61 |
c2ca511c4771
configitems: extract the logic to build a registrar on any configtable
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33061
diff
changeset
|
62 coreconfigitem = getitemregister(coreitems) |
c2ca511c4771
configitems: extract the logic to build a registrar on any configtable
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33061
diff
changeset
|
63 |
33180
21383dbb3611
configitems: register the 'auth.cookiefile' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33179
diff
changeset
|
64 coreconfigitem('auth', 'cookiefile', |
21383dbb3611
configitems: register the 'auth.cookiefile' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33179
diff
changeset
|
65 default=None, |
21383dbb3611
configitems: register the 'auth.cookiefile' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33179
diff
changeset
|
66 ) |
33181
640a0760e666
configitems: register the 'bookmarks.pushing' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33180
diff
changeset
|
67 # bookmarks.pushing: internal hack for discovery |
640a0760e666
configitems: register the 'bookmarks.pushing' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33180
diff
changeset
|
68 coreconfigitem('bookmarks', 'pushing', |
640a0760e666
configitems: register the 'bookmarks.pushing' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33180
diff
changeset
|
69 default=list, |
640a0760e666
configitems: register the 'bookmarks.pushing' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33180
diff
changeset
|
70 ) |
33182
634997248c97
configitems: register the 'bundle.mainreporoot' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33181
diff
changeset
|
71 # bundle.mainreporoot: internal hack for bundlerepo |
634997248c97
configitems: register the 'bundle.mainreporoot' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33181
diff
changeset
|
72 coreconfigitem('bundle', 'mainreporoot', |
634997248c97
configitems: register the 'bundle.mainreporoot' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33181
diff
changeset
|
73 default='', |
634997248c97
configitems: register the 'bundle.mainreporoot' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33181
diff
changeset
|
74 ) |
33183
9f95f0bb343b
configitems: register the 'bundle.reorder' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33182
diff
changeset
|
75 # bundle.reorder: experimental config |
9f95f0bb343b
configitems: register the 'bundle.reorder' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33182
diff
changeset
|
76 coreconfigitem('bundle', 'reorder', |
9f95f0bb343b
configitems: register the 'bundle.reorder' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33182
diff
changeset
|
77 default='auto', |
9f95f0bb343b
configitems: register the 'bundle.reorder' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33182
diff
changeset
|
78 ) |
33179
95c57596b380
configitems: register the 'color.mode' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33177
diff
changeset
|
79 coreconfigitem('color', 'mode', |
95c57596b380
configitems: register the 'color.mode' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33177
diff
changeset
|
80 default='auto', |
95c57596b380
configitems: register the 'color.mode' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33177
diff
changeset
|
81 ) |
33472
d0869a6e83ab
configitems: register the 'color.pagermode' config
Boris Feld <boris.feld@octobus.net>
parents:
33471
diff
changeset
|
82 coreconfigitem('color', 'pagermode', |
d0869a6e83ab
configitems: register the 'color.pagermode' config
Boris Feld <boris.feld@octobus.net>
parents:
33471
diff
changeset
|
83 default=dynamicdefault, |
d0869a6e83ab
configitems: register the 'color.pagermode' config
Boris Feld <boris.feld@octobus.net>
parents:
33471
diff
changeset
|
84 ) |
33158
cb7140e230c8
config: register the 'devel.all-warnings' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33150
diff
changeset
|
85 coreconfigitem('devel', 'all-warnings', |
cb7140e230c8
config: register the 'devel.all-warnings' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33150
diff
changeset
|
86 default=False, |
cb7140e230c8
config: register the 'devel.all-warnings' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33150
diff
changeset
|
87 ) |
33159
0224820688ac
config: register the 'devel.bundle2.debug' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33158
diff
changeset
|
88 coreconfigitem('devel', 'bundle2.debug', |
0224820688ac
config: register the 'devel.bundle2.debug' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33158
diff
changeset
|
89 default=False, |
0224820688ac
config: register the 'devel.bundle2.debug' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33158
diff
changeset
|
90 ) |
33160
12aaade1f617
config: register the devel.check-locks config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33159
diff
changeset
|
91 coreconfigitem('devel', 'check-locks', |
12aaade1f617
config: register the devel.check-locks config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33159
diff
changeset
|
92 default=False, |
12aaade1f617
config: register the devel.check-locks config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33159
diff
changeset
|
93 ) |
33161
b1cf9bb8a5a2
config: register the 'devel.check-relroot' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33160
diff
changeset
|
94 coreconfigitem('devel', 'check-relroot', |
b1cf9bb8a5a2
config: register the 'devel.check-relroot' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33160
diff
changeset
|
95 default=False, |
b1cf9bb8a5a2
config: register the 'devel.check-relroot' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33160
diff
changeset
|
96 ) |
33162
1ad6d6cee9eb
config: register the 'devel.disableloaddefaultcerts' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33161
diff
changeset
|
97 coreconfigitem('devel', 'disableloaddefaultcerts', |
1ad6d6cee9eb
config: register the 'devel.disableloaddefaultcerts' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33161
diff
changeset
|
98 default=False, |
1ad6d6cee9eb
config: register the 'devel.disableloaddefaultcerts' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33161
diff
changeset
|
99 ) |
33184
649f3b0495c8
config: register the 'devel.legacy.exchange' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33183
diff
changeset
|
100 coreconfigitem('devel', 'legacy.exchange', |
649f3b0495c8
config: register the 'devel.legacy.exchange' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33183
diff
changeset
|
101 default=list, |
649f3b0495c8
config: register the 'devel.legacy.exchange' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33183
diff
changeset
|
102 ) |
33163
1969adf2139a
config: register the 'devel.servercafile' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33162
diff
changeset
|
103 coreconfigitem('devel', 'servercafile', |
1969adf2139a
config: register the 'devel.servercafile' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33162
diff
changeset
|
104 default='', |
1969adf2139a
config: register the 'devel.servercafile' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33162
diff
changeset
|
105 ) |
33164
f15850eff735
config: register the 'devel.serverexactprotocol' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33163
diff
changeset
|
106 coreconfigitem('devel', 'serverexactprotocol', |
f15850eff735
config: register the 'devel.serverexactprotocol' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33163
diff
changeset
|
107 default='', |
f15850eff735
config: register the 'devel.serverexactprotocol' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33163
diff
changeset
|
108 ) |
33165
1a6f28439135
config: register the 'devel.serverrequirecert' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33164
diff
changeset
|
109 coreconfigitem('devel', 'serverrequirecert', |
33177
be723e2afd3d
configitem: fix default value for 'serverrequirecert'
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33166
diff
changeset
|
110 default=False, |
33165
1a6f28439135
config: register the 'devel.serverrequirecert' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33164
diff
changeset
|
111 ) |
33166
5c9ad50fd62f
config: register the 'devel.strip-obsmarkers' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33165
diff
changeset
|
112 coreconfigitem('devel', 'strip-obsmarkers', |
5c9ad50fd62f
config: register the 'devel.strip-obsmarkers' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33165
diff
changeset
|
113 default=True, |
5c9ad50fd62f
config: register the 'devel.strip-obsmarkers' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33165
diff
changeset
|
114 ) |
33235
b838e857439d
configitems: register the 'format.aggressivemergedeltas' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33234
diff
changeset
|
115 coreconfigitem('format', 'aggressivemergedeltas', |
b838e857439d
configitems: register the 'format.aggressivemergedeltas' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33234
diff
changeset
|
116 default=False, |
b838e857439d
configitems: register the 'format.aggressivemergedeltas' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33234
diff
changeset
|
117 ) |
33236
cf6c478bc339
configitems: register the 'format.chunkcachesize' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33235
diff
changeset
|
118 coreconfigitem('format', 'chunkcachesize', |
cf6c478bc339
configitems: register the 'format.chunkcachesize' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33235
diff
changeset
|
119 default=None, |
cf6c478bc339
configitems: register the 'format.chunkcachesize' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33235
diff
changeset
|
120 ) |
33237
7043e67cc9b2
configitems: register the 'format.dotencode' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33236
diff
changeset
|
121 coreconfigitem('format', 'dotencode', |
7043e67cc9b2
configitems: register the 'format.dotencode' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33236
diff
changeset
|
122 default=True, |
7043e67cc9b2
configitems: register the 'format.dotencode' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33236
diff
changeset
|
123 ) |
33238
784f2bd96d43
configitems: register the 'format.generaldelta' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33237
diff
changeset
|
124 coreconfigitem('format', 'generaldelta', |
784f2bd96d43
configitems: register the 'format.generaldelta' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33237
diff
changeset
|
125 default=False, |
784f2bd96d43
configitems: register the 'format.generaldelta' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33237
diff
changeset
|
126 ) |
33239
a4f6dee1b9f1
configitems: register the 'format.manifestcachesize' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33238
diff
changeset
|
127 coreconfigitem('format', 'manifestcachesize', |
a4f6dee1b9f1
configitems: register the 'format.manifestcachesize' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33238
diff
changeset
|
128 default=None, |
a4f6dee1b9f1
configitems: register the 'format.manifestcachesize' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33238
diff
changeset
|
129 ) |
33240
91c1e7c974c2
configitems: register the 'format.maxchainlen' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33239
diff
changeset
|
130 coreconfigitem('format', 'maxchainlen', |
91c1e7c974c2
configitems: register the 'format.maxchainlen' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33239
diff
changeset
|
131 default=None, |
91c1e7c974c2
configitems: register the 'format.maxchainlen' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33239
diff
changeset
|
132 ) |
33244
fd50788a2d4f
configitems: register the 'format.obsstore-version' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33240
diff
changeset
|
133 coreconfigitem('format', 'obsstore-version', |
fd50788a2d4f
configitems: register the 'format.obsstore-version' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33240
diff
changeset
|
134 default=None, |
fd50788a2d4f
configitems: register the 'format.obsstore-version' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33240
diff
changeset
|
135 ) |
33245
28e8983d9ed7
configitems: register the 'format.usefncache' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33244
diff
changeset
|
136 coreconfigitem('format', 'usefncache', |
28e8983d9ed7
configitems: register the 'format.usefncache' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33244
diff
changeset
|
137 default=True, |
28e8983d9ed7
configitems: register the 'format.usefncache' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33244
diff
changeset
|
138 ) |
33246
4d9458e06ef0
configitems: register the 'format.usegeneraldelta' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33245
diff
changeset
|
139 coreconfigitem('format', 'usegeneraldelta', |
4d9458e06ef0
configitems: register the 'format.usegeneraldelta' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33245
diff
changeset
|
140 default=True, |
4d9458e06ef0
configitems: register the 'format.usegeneraldelta' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33245
diff
changeset
|
141 ) |
33247
4d5d493ea54a
configitems: register the 'format.usestore' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33246
diff
changeset
|
142 coreconfigitem('format', 'usestore', |
4d5d493ea54a
configitems: register the 'format.usestore' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33246
diff
changeset
|
143 default=True, |
4d5d493ea54a
configitems: register the 'format.usestore' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33246
diff
changeset
|
144 ) |
33217
f96c2f2f559b
configitems: register the 'hostsecurity.ciphers' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33184
diff
changeset
|
145 coreconfigitem('hostsecurity', 'ciphers', |
f96c2f2f559b
configitems: register the 'hostsecurity.ciphers' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33184
diff
changeset
|
146 default=None, |
f96c2f2f559b
configitems: register the 'hostsecurity.ciphers' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33184
diff
changeset
|
147 ) |
33218
24f3ff50736d
configitems: register the 'hostsecurity.disabletls10warning' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33217
diff
changeset
|
148 coreconfigitem('hostsecurity', 'disabletls10warning', |
24f3ff50736d
configitems: register the 'hostsecurity.disabletls10warning' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33217
diff
changeset
|
149 default=False, |
24f3ff50736d
configitems: register the 'hostsecurity.disabletls10warning' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33217
diff
changeset
|
150 ) |
33229
dd50a370c8cb
configitems: register the 'patch.eol' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33228
diff
changeset
|
151 coreconfigitem('patch', 'eol', |
dd50a370c8cb
configitems: register the 'patch.eol' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33228
diff
changeset
|
152 default='strict', |
dd50a370c8cb
configitems: register the 'patch.eol' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33228
diff
changeset
|
153 ) |
32990
1d5d7e2b7ab5
configitems: register 'patch.fuzz' as first example for 'configint'
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32986
diff
changeset
|
154 coreconfigitem('patch', 'fuzz', |
1d5d7e2b7ab5
configitems: register 'patch.fuzz' as first example for 'configint'
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32986
diff
changeset
|
155 default=2, |
1d5d7e2b7ab5
configitems: register 'patch.fuzz' as first example for 'configint'
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32986
diff
changeset
|
156 ) |
33248
be00b61e4c4a
configitems: register the 'progress.assume-tty' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33247
diff
changeset
|
157 coreconfigitem('progress', 'assume-tty', |
be00b61e4c4a
configitems: register the 'progress.assume-tty' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33247
diff
changeset
|
158 default=False, |
be00b61e4c4a
configitems: register the 'progress.assume-tty' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33247
diff
changeset
|
159 ) |
33249
391da1416038
configitems: register the 'progress.clear-complete' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33248
diff
changeset
|
160 coreconfigitem('progress', 'clear-complete', |
391da1416038
configitems: register the 'progress.clear-complete' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33248
diff
changeset
|
161 default=True, |
391da1416038
configitems: register the 'progress.clear-complete' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33248
diff
changeset
|
162 ) |
33250
bbc57a7e8823
configitems: register the 'progress.estimate' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33249
diff
changeset
|
163 coreconfigitem('progress', 'estimate', |
bbc57a7e8823
configitems: register the 'progress.estimate' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33249
diff
changeset
|
164 default=2, |
bbc57a7e8823
configitems: register the 'progress.estimate' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33249
diff
changeset
|
165 ) |
33473
b78c59e41a65
configitems: register the 'progress.width' config
Boris Feld <boris.feld@octobus.net>
parents:
33472
diff
changeset
|
166 coreconfigitem('progress', 'width', |
b78c59e41a65
configitems: register the 'progress.width' config
Boris Feld <boris.feld@octobus.net>
parents:
33472
diff
changeset
|
167 default=dynamicdefault, |
b78c59e41a65
configitems: register the 'progress.width' config
Boris Feld <boris.feld@octobus.net>
parents:
33472
diff
changeset
|
168 ) |
33219
ffb1d0f541f5
configitems: register the 'server.bundle1' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33218
diff
changeset
|
169 coreconfigitem('server', 'bundle1', |
ffb1d0f541f5
configitems: register the 'server.bundle1' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33218
diff
changeset
|
170 default=True, |
ffb1d0f541f5
configitems: register the 'server.bundle1' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33218
diff
changeset
|
171 ) |
33220
40861b2254a5
configitems: register the 'server.bundle1gd' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33219
diff
changeset
|
172 coreconfigitem('server', 'bundle1gd', |
40861b2254a5
configitems: register the 'server.bundle1gd' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33219
diff
changeset
|
173 default=None, |
40861b2254a5
configitems: register the 'server.bundle1gd' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33219
diff
changeset
|
174 ) |
33221
4237398c67c0
configitems: register the 'server.compressionengines' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33220
diff
changeset
|
175 coreconfigitem('server', 'compressionengines', |
4237398c67c0
configitems: register the 'server.compressionengines' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33220
diff
changeset
|
176 default=list, |
4237398c67c0
configitems: register the 'server.compressionengines' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33220
diff
changeset
|
177 ) |
33222
593ad8df9dd2
configitems: register the 'server.concurrent-push-mode' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33221
diff
changeset
|
178 coreconfigitem('server', 'concurrent-push-mode', |
593ad8df9dd2
configitems: register the 'server.concurrent-push-mode' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33221
diff
changeset
|
179 default='strict', |
593ad8df9dd2
configitems: register the 'server.concurrent-push-mode' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33221
diff
changeset
|
180 ) |
33223
d227451ee280
configitems: register the 'server.disablefullbundle' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33222
diff
changeset
|
181 coreconfigitem('server', 'disablefullbundle', |
d227451ee280
configitems: register the 'server.disablefullbundle' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33222
diff
changeset
|
182 default=False, |
d227451ee280
configitems: register the 'server.disablefullbundle' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33222
diff
changeset
|
183 ) |
33224
ab9121fda8d2
configitems: register the 'server.maxhttpheaderlen' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33223
diff
changeset
|
184 coreconfigitem('server', 'maxhttpheaderlen', |
ab9121fda8d2
configitems: register the 'server.maxhttpheaderlen' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33223
diff
changeset
|
185 default=1024, |
ab9121fda8d2
configitems: register the 'server.maxhttpheaderlen' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33223
diff
changeset
|
186 ) |
33225
90a1b62bdc91
configitems: register the 'server.preferuncompressed' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33224
diff
changeset
|
187 coreconfigitem('server', 'preferuncompressed', |
90a1b62bdc91
configitems: register the 'server.preferuncompressed' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33224
diff
changeset
|
188 default=False, |
90a1b62bdc91
configitems: register the 'server.preferuncompressed' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33224
diff
changeset
|
189 ) |
33226
b045344fe35e
configitems: register the 'server.uncompressedallowsecret' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33225
diff
changeset
|
190 coreconfigitem('server', 'uncompressedallowsecret', |
b045344fe35e
configitems: register the 'server.uncompressedallowsecret' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33225
diff
changeset
|
191 default=False, |
b045344fe35e
configitems: register the 'server.uncompressedallowsecret' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33225
diff
changeset
|
192 ) |
33227
86c9aa1d598f
configitems: register the 'server.validate' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33226
diff
changeset
|
193 coreconfigitem('server', 'validate', |
86c9aa1d598f
configitems: register the 'server.validate' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33226
diff
changeset
|
194 default=False, |
86c9aa1d598f
configitems: register the 'server.validate' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33226
diff
changeset
|
195 ) |
33228
35c233975b78
configitems: register the 'server.zliblevel' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33227
diff
changeset
|
196 coreconfigitem('server', 'zliblevel', |
35c233975b78
configitems: register the 'server.zliblevel' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33227
diff
changeset
|
197 default=-1, |
35c233975b78
configitems: register the 'server.zliblevel' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33227
diff
changeset
|
198 ) |
32991
03608e8d09e9
configitems: register 'ui.clonebundleprefers' as example for 'configlist'
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32990
diff
changeset
|
199 coreconfigitem('ui', 'clonebundleprefers', |
33150
77e666f943a6
configitems: support callable as a default value
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33133
diff
changeset
|
200 default=list, |
32991
03608e8d09e9
configitems: register 'ui.clonebundleprefers' as example for 'configlist'
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32990
diff
changeset
|
201 ) |
33061
c41cbe98822c
configitems: register 'ui.interactive'
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32991
diff
changeset
|
202 coreconfigitem('ui', 'interactive', |
c41cbe98822c
configitems: register 'ui.interactive'
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32991
diff
changeset
|
203 default=None, |
c41cbe98822c
configitems: register 'ui.interactive'
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32991
diff
changeset
|
204 ) |
32986
2529e2ae9f4c
configitems: register 'ui.quiet' as first example
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32984
diff
changeset
|
205 coreconfigitem('ui', 'quiet', |
2529e2ae9f4c
configitems: register 'ui.quiet' as first example
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32984
diff
changeset
|
206 default=False, |
2529e2ae9f4c
configitems: register 'ui.quiet' as first example
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
32984
diff
changeset
|
207 ) |
33329
e714159860fd
configitems: add alias support in config
David Demelier <demelier.david@gmail.com>
parents:
33250
diff
changeset
|
208 coreconfigitem('ui', 'username', |
e714159860fd
configitems: add alias support in config
David Demelier <demelier.david@gmail.com>
parents:
33250
diff
changeset
|
209 alias=[('ui', 'user')] |
e714159860fd
configitems: add alias support in config
David Demelier <demelier.david@gmail.com>
parents:
33250
diff
changeset
|
210 ) |
33234
b62d13506860
configitems: gather comment related to 'worker.backgroundclosemaxqueue'
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33233
diff
changeset
|
211 # Windows defaults to a limit of 512 open files. A buffer of 128 |
b62d13506860
configitems: gather comment related to 'worker.backgroundclosemaxqueue'
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33233
diff
changeset
|
212 # should give us enough headway. |
33230
5dcbd2045dcb
configitems: register the 'worker.backgroundclosemaxqueue' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33229
diff
changeset
|
213 coreconfigitem('worker', 'backgroundclosemaxqueue', |
5dcbd2045dcb
configitems: register the 'worker.backgroundclosemaxqueue' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33229
diff
changeset
|
214 default=384, |
5dcbd2045dcb
configitems: register the 'worker.backgroundclosemaxqueue' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33229
diff
changeset
|
215 ) |
33231
d19804c16710
configitems: register the 'worker.backgroundcloseminfilecount' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33230
diff
changeset
|
216 coreconfigitem('worker', 'backgroundcloseminfilecount', |
d19804c16710
configitems: register the 'worker.backgroundcloseminfilecount' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33230
diff
changeset
|
217 default=2048, |
d19804c16710
configitems: register the 'worker.backgroundcloseminfilecount' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33230
diff
changeset
|
218 ) |
33232
4531a967e7f1
configitems: register the 'worker.backgroundclosethreadcount' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33231
diff
changeset
|
219 coreconfigitem('worker', 'backgroundclosethreadcount', |
4531a967e7f1
configitems: register the 'worker.backgroundclosethreadcount' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33231
diff
changeset
|
220 default=4, |
4531a967e7f1
configitems: register the 'worker.backgroundclosethreadcount' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33231
diff
changeset
|
221 ) |
33233
c9849bec227a
configitems: register the 'worker.numcpus' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33232
diff
changeset
|
222 coreconfigitem('worker', 'numcpus', |
c9849bec227a
configitems: register the 'worker.numcpus' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33232
diff
changeset
|
223 default=None, |
c9849bec227a
configitems: register the 'worker.numcpus' config
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
33232
diff
changeset
|
224 ) |