comparison mercurial/subrepo.py @ 12930:9bb180abc4d0 stable

subrepo: test & fix svn subrepo removal
author Ronny Pfannschmidt <Ronny.Pfannschmidt@gmx.de>
date Fri, 05 Nov 2010 15:13:22 +0100
parents 5dbff89cf107
children 2b73a3279a9f 92b0d669637f
comparison
equal deleted inserted replaced
12911:f766882000c7 12930:9bb180abc4d0
547 if self.dirty(): 547 if self.dirty():
548 self._ui.warn(_('not removing repo %s because ' 548 self._ui.warn(_('not removing repo %s because '
549 'it has changes.\n' % self._path)) 549 'it has changes.\n' % self._path))
550 return 550 return
551 self._ui.note(_('removing subrepo %s\n') % self._path) 551 self._ui.note(_('removing subrepo %s\n') % self._path)
552 shutil.rmtree(self._ctx.repo.join(self._path)) 552 shutil.rmtree(self._ctx._repo.wjoin(self._path))
553 553
554 def get(self, state): 554 def get(self, state):
555 status = self._svncommand(['checkout', state[0], '--revision', state[1]]) 555 status = self._svncommand(['checkout', state[0], '--revision', state[1]])
556 if not re.search('Checked out revision [0-9]+.', status): 556 if not re.search('Checked out revision [0-9]+.', status):
557 raise util.Abort(status.splitlines()[-1]) 557 raise util.Abort(status.splitlines()[-1])