dispatch: load shared source repository config in share-safe mode
It seems to me now that there are two steps when config is loaded:
1) on dispatch
2) repository object creation
Recent patches added functionality that there can be shares in share-safe mode
where config of the source repository is shared with the the shares. However we
missed adding logic to read the source config on dispatch. This leads to
extensions not being loaded on dispatch and hence extensions command not being
recognized.
This patch fixes it by reading the shared source config on dispatch.
Differential Revision: https://phab.mercurial-scm.org/D9047
from __future__ import absolute_import
from mercurial.utils import procutil
# XXX: we should probably offer a devel option to do this in blackbox directly
def getuser():
return b'bob'
def getpid():
return 5000
# mock the date and user apis so the output is always the same
def uisetup(ui):
procutil.getuser = getuser
procutil.getpid = getpid