##// END OF EJS Templates
cmdserver: reload mq on each runcommand request to avoid corruption...
Yuya Nishihara -
r20628:e3d1df48 default
parent child Browse files
Show More
@@ -3269,6 +3269,11 b' def reposetup(ui, repo):'
3269 def mq(self):
3269 def mq(self):
3270 return queue(self.ui, self.baseui, self.path)
3270 return queue(self.ui, self.baseui, self.path)
3271
3271
3272 def invalidateall(self):
3273 super(mqrepo, self).invalidateall()
3274 if localrepo.hasunfilteredcache(self, 'mq'):
3275 self.mq.invalidate()
3276
3272 def abortifwdirpatched(self, errmsg, force=False):
3277 def abortifwdirpatched(self, errmsg, force=False):
3273 if self.mq.applied and self.mq.checkapplied and not force:
3278 if self.mq.applied and self.mq.checkapplied and not force:
3274 parents = self.dirstate.parents()
3279 parents = self.dirstate.parents()
@@ -274,6 +274,15 b' def obsolete(server):'
274 runcommand(server, ['log', '--hidden'])
274 runcommand(server, ['log', '--hidden'])
275 runcommand(server, ['log'])
275 runcommand(server, ['log'])
276
276
277 def mqoutsidechanges(server):
278 readchannel(server)
279
280 # load repo.mq
281 runcommand(server, ['qapplied'])
282 os.system('hg qnew 0.diff')
283 # repo.mq should be invalidated
284 runcommand(server, ['qapplied'])
285
277 if __name__ == '__main__':
286 if __name__ == '__main__':
278 os.system('hg init')
287 os.system('hg init')
279
288
@@ -304,3 +313,7 b" if __name__ == '__main__':"
304 hgrc.write('[extensions]\nobs=obs.py\n')
313 hgrc.write('[extensions]\nobs=obs.py\n')
305 hgrc.close()
314 hgrc.close()
306 check(obsolete)
315 check(obsolete)
316 hgrc = open('.hg/hgrc', 'a')
317 hgrc.write('[extensions]\nmq=\n')
318 hgrc.close()
319 check(mqoutsidechanges)
@@ -222,3 +222,9 b' user: test'
222 date: Thu Jan 01 00:00:00 1970 +0000
222 date: Thu Jan 01 00:00:00 1970 +0000
223 summary: 1
223 summary: 1
224
224
225
226 testing mqoutsidechanges:
227
228 runcommand qapplied
229 runcommand qapplied
230 0.diff
General Comments 0
You need to be logged in to leave comments. Login now