Mercurial > public > mercurial-scm > hg
diff hgext/mq.py @ 2791:f4d916351366
Add portable shell-quoting function; teach mq to use it.
author | Brendan Cully <brendan@kublai.com> |
---|---|
date | Sat, 05 Aug 2006 15:23:26 -0700 |
parents | ae726521717c |
children | 8ec1b1f0a5f7 |
line wrap: on
line diff
--- a/hgext/mq.py Sun Aug 06 16:03:02 2006 +0200 +++ b/hgext/mq.py Sat Aug 05 15:23:26 2006 -0700 @@ -272,8 +272,8 @@ patchfile: file name of patch''' try: pp = util.find_in_path('gpatch', os.environ.get('PATH', ''), 'patch') - f = os.popen("%s -d '%s' -p1 --no-backup-if-mismatch < '%s'" % - (pp, repo.root, patchfile)) + f = os.popen("%s -d %s -p1 --no-backup-if-mismatch < %s" % + (pp, util.shellquote(repo.root), util.shellquote(patchfile))) except: self.ui.warn("patch failed, unable to continue (try -v)\n") return (None, [], False)