* Git Notes - Search Functionality
@ 2013-02-27 15:34 krishna chaitanya kurnala
2013-02-27 15:44 ` Johan Herland
2013-02-27 15:57 ` Thomas Rast
0 siblings, 2 replies; 3+ messages in thread
From: krishna chaitanya kurnala @ 2013-02-27 15:34 UTC (permalink / raw)
To: git
Hello All
I working on Git Notes. I want to know if there is an easy way to
obtain a list of all "namespaces"(For eg., git notes --ref=namespace
... ) with notes objects in a specific git repository. We can easily
create, edit, merge git notes with commands if we know the namespaces
and/or the sha. But, for example, Has anyone tried to search for a
string in a git notes objects for that project etc?
The closest i can think of is using some options with git logs, for
example, git log --show-notes=* --format="%H %N" etc.
Appreciate your time.
thanks
Krishna Chaitanya
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Git Notes - Search Functionality
2013-02-27 15:34 Git Notes - Search Functionality krishna chaitanya kurnala
@ 2013-02-27 15:44 ` Johan Herland
2013-02-27 15:57 ` Thomas Rast
1 sibling, 0 replies; 3+ messages in thread
From: Johan Herland @ 2013-02-27 15:44 UTC (permalink / raw)
To: krishna chaitanya kurnala; +Cc: git
On Wed, Feb 27, 2013 at 4:34 PM, krishna chaitanya kurnala
<kkc4al@gmail.com> wrote:
> Hello All
>
> I working on Git Notes. I want to know if there is an easy way to
> obtain a list of all "namespaces"(For eg., git notes --ref=namespace
> ... ) with notes objects in a specific git repository.
The notes namespaces are stored as regular refs under refs/notes/*.
Here's one way to list the available namespaces:
git for-each-ref refs/notes/
Hope this helps,
...Johan
> We can easily
> create, edit, merge git notes with commands if we know the namespaces
> and/or the sha. But, for example, Has anyone tried to search for a
> string in a git notes objects for that project etc?
> The closest i can think of is using some options with git logs, for
> example, git log --show-notes=* --format="%H %N" etc.
>
> Appreciate your time.
>
> thanks
> Krishna Chaitanya
> --
> To unsubscribe from this list: send the line "unsubscribe git" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
--
Johan Herland, <johan@herland.net>
www.herland.net
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Git Notes - Search Functionality
2013-02-27 15:34 Git Notes - Search Functionality krishna chaitanya kurnala
2013-02-27 15:44 ` Johan Herland
@ 2013-02-27 15:57 ` Thomas Rast
1 sibling, 0 replies; 3+ messages in thread
From: Thomas Rast @ 2013-02-27 15:57 UTC (permalink / raw)
To: krishna chaitanya kurnala; +Cc: git
krishna chaitanya kurnala <kkc4al@gmail.com> writes:
> I working on Git Notes. I want to know if there is an easy way to
> obtain a list of all "namespaces"(For eg., git notes --ref=namespace
> ... ) with notes objects in a specific git repository. We can easily
> create, edit, merge git notes with commands if we know the namespaces
> and/or the sha. But, for example, Has anyone tried to search for a
> string in a git notes objects for that project etc?
> The closest i can think of is using some options with git logs, for
> example, git log --show-notes=* --format="%H %N" etc.
>
> Appreciate your time.
An easy way to list everything in refs/notes/ is
git for-each-ref refs/notes/
but that of course won't figure out if you have more notes e.g. in
refs/remotes/origin/notes/* or some such. I think this more general
problem can be solved only by heuristics, since the notes trees are
actually "just trees" -- the only distinction is that they have fairly
funny filenames in them.
--
Thomas Rast
trast@{inf,student}.ethz.ch
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-02-27 16:23 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-02-27 15:34 Git Notes - Search Functionality krishna chaitanya kurnala
2013-02-27 15:44 ` Johan Herland
2013-02-27 15:57 ` Thomas Rast
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).