cmdserver: assign repo.baseui before running commands
There are places in the code that use localrepository.baseui (see hg.remoteui),
we need the ui descriptors (and possibly other things) to be set
correctly on it, so output written to the remoteui descriptors ends up at the
right place.
Before this change, tests such as 'test-bookmarks-pushpull.t' didn't work.
--- a/mercurial/commandserver.py Fri Jun 24 19:43:59 2011 +0300
+++ b/mercurial/commandserver.py Fri Jun 24 19:44:17 2011 +0300
@@ -179,8 +179,11 @@
# copy the uis so changes (e.g. --config or --verbose) don't
# persist between requests
+ copiedui = self.ui.copy()
+ self.repo.baseui = copiedui
self.repo.ui = self.repo.dirstate._ui = self.repoui.copy()
- req = dispatch.request(args, self.ui.copy(), self.repo, self.cin,
+
+ req = dispatch.request(args, copiedui, self.repo, self.cin,
self.cout, self.cerr)
ret = dispatch.dispatch(req) or 0 # might return None