From: Johannes Schindelin <Johannes.Schindelin@gmx.de>
To: Jeff King <peff@peff.net>
Cc: Avery Pennarun <apenwarr@gmail.com>,
Peter Karlsson <peter@softwolves.pp.se>,
git@vger.kernel.org
Subject: Re: Git on Windows, CRLF issues
Date: Wed, 23 Apr 2008 11:13:27 +0100 (BST) [thread overview]
Message-ID: <alpine.DEB.1.00.0804231110080.4181@eeepc-johanness> (raw)
In-Reply-To: <20080423080826.GA11935@sigill.intra.peff.net>
Hi,
On Wed, 23 Apr 2008, Jeff King wrote:
> On Tue, Apr 22, 2008 at 12:51:14PM -0400, Avery Pennarun wrote:
>
> > Do you think git would benefit from having a generalized version of
> > this script? Basically, the user provides a "munge" script on the
> > command line, and there's a git-filter-branch mode for auto-munging
> > (with a cache) every file in every checkin. Even if it's *only* ever
> > used for CRLF, I can imagine this being useful to a lot of people.
>
> It was easy enough to work up the patch below, which allows
>
> git filter-branch --blob-filter 'tr a-z A-Z'
>
> However, it's _still_ horribly slow.
You create a quite huge blob-cache, so you are pretty heavy on disk-I/O.
Have you tried (as suggested in the man page) to run this on a huge RAM
disk? That should blow you away.
> Shell script is nice and flexible, but running a tight loop like this is
> just painful. I suspect filter-branch in something like perl would be a
> lot faster and just as flexible (you could even do it in C, but you'd
> probably have to invent a little domain-specific scripting language).
I hoped that the rewrite-commits attempt was more than just that: an
attempt. So there is a point you could start from, doing things in C.
But I doubt that you get any joy: either your language is too limited, or
you will get the same problems (fork() overhead) again.
> Anyway, here is the patch. I don't know if it is even worth applying,
> since it is still painfully slow.
I like your patch:
Acked-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Ciao,
Dscho
next prev parent reply other threads:[~2008-04-23 10:14 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-04-21 19:48 Git on Windows, CRLF issues Peter Karlsson
2008-04-21 20:07 ` Johannes Schindelin
2008-04-21 21:53 ` Avery Pennarun
2008-04-22 2:39 ` Jeff King
2008-04-22 16:51 ` Avery Pennarun
2008-04-23 7:11 ` Peter Karlsson
2008-04-23 8:10 ` Jeff King
2008-04-23 13:47 ` Peter Karlsson
2008-04-23 14:24 ` Johan Herland
2008-04-23 15:12 ` Johannes Sixt
2008-04-23 8:08 ` Jeff King
2008-04-23 10:13 ` Johannes Schindelin [this message]
2008-04-23 10:58 ` Jeff King
2008-04-23 10:58 ` Johannes Sixt
2008-04-23 11:04 ` Jeff King
2008-04-23 11:46 ` Johannes Sixt
2008-04-23 21:47 ` Jeff King
2008-04-23 23:01 ` Junio C Hamano
2008-04-23 23:04 ` Avery Pennarun
2008-04-24 8:11 ` Johannes Schindelin
2008-04-24 16:56 ` Avery Pennarun
2008-04-24 1:37 ` Jeff King
2008-04-23 20:02 ` Avery Pennarun
2008-04-24 6:25 ` Johannes Sixt
2008-04-22 6:41 ` Johannes Sixt
2008-04-21 21:51 ` Jakub Narebski
2008-04-22 6:52 ` Peter Karlsson
2008-04-22 9:04 ` Johannes Sixt
2008-04-22 6:31 ` Johannes Sixt
2008-04-22 8:42 ` Peter Karlsson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=alpine.DEB.1.00.0804231110080.4181@eeepc-johanness \
--to=johannes.schindelin@gmx.de \
--cc=apenwarr@gmail.com \
--cc=git@vger.kernel.org \
--cc=peff@peff.net \
--cc=peter@softwolves.pp.se \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox