Details
Details
- Reviewers
lothiraldan - Group Reviewers
hg-reviewers - Commits
- rHG057d31ceace3: pushvars: add a coreconfigitem for push.pushvars.server
Diff Detail
Diff Detail
- Repository
- rHG Mercurial
- Lint
Lint Skipped - Unit
Unit Tests Skipped
lothiraldan |
hg-reviewers |
Lint Skipped |
Unit Tests Skipped |
Path | Packages | |||
---|---|---|---|---|
M | mercurial/bundle2.py (2 lines) | |||
M | mercurial/configitems.py (3 lines) |
cache.write() | cache.write() | ||||
op.ui.debug('applied %i hgtags fnodes cache entries\n' % count) | op.ui.debug('applied %i hgtags fnodes cache entries\n' % count) | ||||
@parthandler('pushvars') | @parthandler('pushvars') | ||||
def bundle2getvars(op, part): | def bundle2getvars(op, part): | ||||
'''unbundle a bundle2 containing shellvars on the server''' | '''unbundle a bundle2 containing shellvars on the server''' | ||||
# An option to disable unbundling on server-side for security reasons | # An option to disable unbundling on server-side for security reasons | ||||
if op.ui.configbool('push', 'pushvars.server', False): | if op.ui.configbool('push', 'pushvars.server'): | ||||
hookargs = {} | hookargs = {} | ||||
for key, value in part.advisoryparams: | for key, value in part.advisoryparams: | ||||
key = key.upper() | key = key.upper() | ||||
# We want pushed variables to have USERVAR_ prepended so we know | # We want pushed variables to have USERVAR_ prepended so we know | ||||
# they came from the --pushvar flag. | # they came from the --pushvar flag. | ||||
key = "USERVAR_" + key | key = "USERVAR_" + key | ||||
hookargs[key] = value | hookargs[key] = value | ||||
op.addhookargs(hookargs) | op.addhookargs(hookargs) |
default=2, | default=2, | ||||
) | ) | ||||
coreconfigitem('progress', 'refresh', | coreconfigitem('progress', 'refresh', | ||||
default=0.1, | default=0.1, | ||||
) | ) | ||||
coreconfigitem('progress', 'width', | coreconfigitem('progress', 'width', | ||||
default=dynamicdefault, | default=dynamicdefault, | ||||
) | ) | ||||
coreconfigitem('push', 'pushvars.server', | |||||
default=False, | |||||
) | |||||
coreconfigitem('server', 'bundle1', | coreconfigitem('server', 'bundle1', | ||||
default=True, | default=True, | ||||
) | ) | ||||
coreconfigitem('server', 'bundle1gd', | coreconfigitem('server', 'bundle1gd', | ||||
default=None, | default=None, | ||||
) | ) | ||||
coreconfigitem('server', 'compressionengines', | coreconfigitem('server', 'compressionengines', | ||||
default=list, | default=list, |