From: Lucas Seiki Oshiro Date: Mon, 08 Dec 2025 16:33:59 GMT Subject: Re: [PATCH] repo: add new flag --keys to git-repo-info Message-ID: <5A4D4433-FD38-4BB0-81B6-3BAD33A30A74@gmail.com> In-Reply-To: > 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.