Re: [PATCH v2 2/2] diff: generate prettier filenames when using GIT_EXTERNAL_DIFF
- From
Jeff King <peff@peff.net>
- Date
- May 28, 2009, 22:06 UTC
- Message-ID
- <20090528220606.GA24148@coredump.intra.peff.net>
- In-Reply-To
- <20090528213049.GA55167@gmail.com>
On Thu, May 28, 2009 at 02:30:49PM -0700, David Aguilar wrote:
Show 9 quoted lines
> > FWIW, I find this name not very descriptive. From the name, I would > > expect it to do the exact same thing as mkstemps, but be our own > > personal implementation. But it is actually a wrapper that behaves > > somewhat differently. So I wonder if "mkstemps_tmpdir" or something > > would be a better name. > > It does exactly what git_mkstemp() does, plus the extra > suffix_len parameter. If we rename this function we have to > rename both.
Ah. Well, I think that is a crappy name, too, then, but it is not your fault. ;) So if there is precedent, I guess somebody else thought it was a good idea, and you should leave your patch as-is.
Show 7 quoted lines
> I was not aware of the other code paths and only wanted to > affect the one that I knew about. I agree that making that the > default behavior would be great, meaning we could drop the > pretty_filename flag altogether. > > If you and others agree that the user-friendly names are a good > thing to have by default then I can rework patch 2/2.
Switching to user-friendly temp filenames for textconv was on my todo list, so I definitely think it is a good idea.
-Peff