From: Jeff King <peff@peff.net>
To: Jonathan Kamens <jkamens@quantopian.com>
Cc: git@vger.kernel.org
Subject: Re: [PATCH 3/3] stash: require a clean index to apply
Date: Sun, 7 Jun 2015 08:47:15 -0400 [thread overview]
Message-ID: <20150607124714.GA17632@peff.net> (raw)
In-Reply-To: <20150607124001.GA11042@peff.net>
On Sun, Jun 07, 2015 at 08:40:01AM -0400, Jeff King wrote:
> Are you running flake8 across the whole tree, or just on the files with
> proposed changes? Does it need to see the whole tree? If you can get
> away with feeding it single files, then it should be very efficient to
> loop over the output of "git diff-index HEAD" and feed the proposed
> updated blobs to it. If you can get away with feeding single lines, then
> feeding the actual diffs to it would be even better, but I assume that
> is not enough (I do not use flake8 myself).
Like I said, I do not use it, but peeking at the flake8 source code, it
has an "--install-hook" option to set up a pre-commit hook. It looks
like the hook runs "git diff-index --cached --name-only HEAD" to get
the list of modified files, filters that only for "*.py", and then
copies the results into a temporary directory to operate on.
-Peff
next prev parent reply other threads:[~2015-06-07 12:47 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-06-05 0:43 [PATCH 3/3] stash: require a clean index to apply Jonathan Kamens
2015-06-07 12:40 ` Jeff King
2015-06-07 12:47 ` Jeff King [this message]
2015-06-10 18:19 ` bär
2015-06-10 18:56 ` Jeff King
2015-06-10 19:16 ` Junio C Hamano
2015-06-10 19:27 ` Jeff King
2015-06-10 21:54 ` bär
2015-06-15 17:42 ` Junio C Hamano
2015-06-15 18:27 ` [PATCH] Revert "stash: require a clean index to apply" Jeff King
2015-06-15 20:11 ` Junio C Hamano
2015-06-25 21:51 ` Jonathan Kamens
[not found] ` <f06e573d-02e3-47e9-85d8-3bb6551d72f5.maildroid@localhost>
2015-06-26 0:27 ` Jeff King
2015-06-26 1:12 ` Jonathan Kamens
2015-06-26 4:03 ` Jeff King
2015-06-26 4:15 ` Junio C Hamano
-- strict thread matches above, loose matches on Subject: below --
2015-04-22 19:29 How do I resolve conflict after popping stash without adding the file to index? Jeff King
2015-04-22 19:31 ` [PATCH 3/3] stash: require a clean index to apply Jeff King
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=20150607124714.GA17632@peff.net \
--to=peff@peff.net \
--cc=git@vger.kernel.org \
--cc=jkamens@quantopian.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.