git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* PostScript files: textconv and "git add -p"
@ 2011-01-04 15:50 Matthieu Moy
  2011-01-05  5:18 ` Jeff King
  0 siblings, 1 reply; 7+ messages in thread
From: Matthieu Moy @ 2011-01-04 15:50 UTC (permalink / raw)
  To: git

Hi (and happy new year everybody !),

I have trouble setting up a comfortable configuration to version
PostScript files. The particularity they have is that they are "text
files" (i.e. git does not detect them as binary files by default, and
neither do tools like less, diff, ...), but not meant to be
human-readable.

If I do this:

,----[ .gitattributes ]
| *.ps diff=ps
`----

,----[ .gitconfig ]
| [diff "ps"]
|       textconv=ps2ascii
`----

then I get the textconv niceness when running "git diff", which is
cool, but "git add -p" still proposes me to stage hunks one by one,
which isn't.

If I set "*.ps binary" in .gitattributes, "git add -p" becomes quiet,
but textconv is disabled.

I want "git diff" to run the textconv filter, and "git add -p" to
consider the file as binary. Is there a way to do this?

Thanks,

-- 
Matthieu Moy
http://www-verimag.imag.fr/~moy/

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2011-01-11  6:11 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-01-04 15:50 PostScript files: textconv and "git add -p" Matthieu Moy
2011-01-05  5:18 ` Jeff King
2011-01-09 18:55   ` Matthieu Moy
2011-01-09 20:10     ` [PATCH] docs: explain diff.*.binary option Jeff King
2011-01-09 20:31       ` Matthieu Moy
2011-01-10 17:59       ` Junio C Hamano
2011-01-11  6:11         ` Jeff King

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).