# HG changeset patch # User Sean Farley # Date 1484792751 28800 # Node ID 7080652af6e61c3b358115d1ef48ced155594fe6 # Parent e12553cfd0a4d3714802392efdc8dbcf72410488 ui: rename tmpdir parameter to more specific repopath This was requested by Augie and I agree that repopath is more descriptive. diff -r e12553cfd0a4 -r 7080652af6e6 hgext/histedit.py --- a/hgext/histedit.py Thu Jan 19 23:01:32 2017 +0900 +++ b/hgext/histedit.py Wed Jan 18 18:25:51 2017 -0800 @@ -1335,7 +1335,7 @@ rules += '\n\n' rules += editcomment rules = ui.edit(rules, ui.username(), {'prefix': 'histedit'}, - tmpdir=repo.path) + repopath=repo.path) # Save edit rules in .hg/histedit-last-edit.txt in case # the user needs to ask for help after something diff -r e12553cfd0a4 -r 7080652af6e6 hgext/patchbomb.py --- a/hgext/patchbomb.py Thu Jan 19 23:01:32 2017 +0900 +++ b/hgext/patchbomb.py Wed Jan 18 18:25:51 2017 -0800 @@ -271,7 +271,7 @@ else: ui.write(_('\nWrite the introductory message for the ' 'patch series.\n\n')) - body = ui.edit(defaultbody, sender, tmpdir=repo.path) + body = ui.edit(defaultbody, sender, repopath=repo.path) # Save series description in case sendmail fails msgfile = repo.vfs('last-email.txt', 'wb') msgfile.write(body) diff -r e12553cfd0a4 -r 7080652af6e6 mercurial/cmdutil.py --- a/mercurial/cmdutil.py Thu Jan 19 23:01:32 2017 +0900 +++ b/mercurial/cmdutil.py Wed Jan 18 18:25:51 2017 -0800 @@ -232,7 +232,7 @@ + fp.read()) reviewedpatch = ui.edit(patchtext, "", extra={"suffix": ".diff"}, - tmpdir=repo.path) + repopath=repo.path) fp.truncate(0) fp.write(reviewedpatch) fp.seek(0) @@ -2782,7 +2782,7 @@ editortext = repo.ui.edit(committext, ctx.user(), ctx.extra(), editform=editform, pending=pending, - tmpdir=repo.path) + repopath=repo.path) text = editortext # strip away anything below this special string (used for editors that want diff -r e12553cfd0a4 -r 7080652af6e6 mercurial/ui.py --- a/mercurial/ui.py Thu Jan 19 23:01:32 2017 +0900 +++ b/mercurial/ui.py Wed Jan 18 18:25:51 2017 -0800 @@ -1022,7 +1022,7 @@ self.write(*msg, **opts) def edit(self, text, user, extra=None, editform=None, pending=None, - tmpdir=None): + repopath=None): extra_defaults = { 'prefix': 'editor', 'suffix': '.txt', @@ -1031,12 +1031,12 @@ extra_defaults.update(extra) extra = extra_defaults - tdir = None + rdir = None if self.configbool('experimental', 'editortmpinhg'): - tdir = tmpdir + rdir = repopath (fd, name) = tempfile.mkstemp(prefix='hg-' + extra['prefix'] + '-', suffix=extra['suffix'], text=True, - dir=tdir) + dir=rdir) try: f = os.fdopen(fd, "w") f.write(text)