git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] git-difftool: allow skipping file by typing 'n' at prompt

From
Sitaram Chamarty <sitaramc@gmail.com>
Date
Oct 10, 2011, 23:39 UTC
Message-ID
<CAMK1S_jNhB_cuTV0u+o_RwOdMKa-xXNZp8KGQ63yqFc70zTm5g@mail.gmail.com>
In-Reply-To
<7v8voslg4l.fsf@alter.siamese.dyndns.org>
On Tue, Oct 11, 2011 at 2:26 AM, Junio C Hamano <gitster@pobox.com> wrote:
> I also wondered if this is easier to read:
>
>        pipe | stdin_contains m2 &&
>        ! pipe | stdin_contains master
> but I do not think it is (we cannot say "pipe | ! stdin_contains master").
Agreed on both counts.

"pipe | ( ! grep master )" does work, but I suspect that is an inconsistency in the shell so I didn't want to use it. IIRC the "( list )" constrict is not supposed to make *that* much difference. Have to check when I have time.

> In any case, here is what I ended up queuing.  Thanks.
> +stdin_doesnot_contain()
> +{
> +       ! stdin_contains "$1"
>  }
(facepalm) Why didn't I think of that!
Thanks :-)
Previous: Junio C Hamano
Message 14 of 14 in “git-difftool: allow skipping file by typing 'n' at prompt”
  1. git-difftool: allow skipping file by typing 'n' at promptSitaram Chamarty, Oct 4, 2011
  2. Junio C HamanoOct 4, 2011
  3. Jeff KingOct 4, 2011
  4. Phil HordOct 4, 2011
  5. Junio C HamanoOct 4, 2011
  6. Sitaram ChamartyOct 4, 2011
  7. git-difftool: allow skipping file by typing 'n' at promptSitaram Chamarty, Oct 6, 2011
  8. Junio C HamanoOct 6, 2011
  9. git-difftool: allow skipping file by typing 'n' at promptSitaram Chamarty, Oct 6, 2011
  10. Junio C HamanoOct 7, 2011
  11. git-difftool: allow skipping file by typing 'n' at promptSitaram Chamarty, Oct 8, 2011
  12. Charles BaileyOct 9, 2011
  13. Junio C HamanoOct 10, 2011
  14. Sitaram ChamartyOct 10, 2011

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.