Git development
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: git@vger.kernel.org
Subject: [RFD] not grep but not log -S
Date: Mon, 13 Apr 2026 14:19:49 -0700	[thread overview]
Message-ID: <xmqq4ileh822.fsf@gitster.g> (raw)

If you have a series of commits that record the contents of "what's
cooking" reports (i.e., "git log origin/todo -- whats-cooking.txt" in
your clone of this project), and have a specific topic name you are
interested in (e.g., "jc/test-set-e-clean"), what's the easiest way
to find out in which issues of the "what's cooking" report the topic
appeared?

   $ git log -Sjc/test-set-e-clean -p whats-cooking.txt

would tell you when it appeared and when it went away, but does not
mention anything about the (potentially) multiple issues the topic
stayed in the report in between.  Git being a tool to track contents
but is primarily used to track _changes_ in contents, this may be
unavoidable, but it is not very satisfying.

Looking for the string in each and every version, e.g.,

    $ git grep jc/test-set-e-clean $(printf "HEAD~%d " $(seq 0 20)) \
			whats-cooking.txt

may give something close to what I want, but it makes me feel dirty
that I have to _guess_ how many is sufficient.

             reply	other threads:[~2026-04-13 21:19 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-04-13 21:19 Junio C Hamano [this message]
2026-04-13 22:04 ` [RFD] not grep but not log -S Mirko Faina

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=xmqq4ileh822.fsf@gitster.g \
    --to=gitster@pobox.com \
    --cc=git@vger.kernel.org \
    /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