Thread (2 messages) 2 messages, 2 authors, 2025-12-08

Re: [PATCH] repo: add new flag --keys to git-repo-info

From: Lucas Seiki Oshiro <hidden>
Date: 2025-12-08 16:34:14

We do not need to say "Currently," but other than that the above is
very well written.  Easy to grok and to the point.
Thanks!
Shouldn't "--keys" be explicitly marked incompatible with "--all"
and remaining keys in argc/argv[]?
Yes, I'll work on that.
While there is no strong reason why anybody must use NUL-terminated
output format, simply because repo_info_fields[] contains no tokens
with strange byte values, but just as principle, shouldn't

   "git repo info --keys -z"

do what is naturally expected?
Hmmm... Perhaps it's too much for this simple flag. `-z` is tied to
--format here, and if we want to support -z we'll also need to 
support --format.

What about adding a "default" format for --format? This way, it
would translate to:

- keyvalue, when using info without --keys
- table, when using structure
- using puts, when using info with --keys

Another solution, of course, would be aborting when --format, -z or
--all are used with --keys.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help