Re: [GSoC RFC PATCH v2 1/7] repo-info: declare the repo-info command
- From
Lucas Seiki Oshiro <lucasseikioshiro@gmail.com>
- Date
- Jul 4, 2025, 21:40 UTC
- Message-ID
- <AD2EE71A-1395-4665-BB9C-38DD4B941574@gmail.com>
- In-Reply-To
- <aGZqK5eBA18vHAa_@pks.im>
> One thing I wondered: Justin is currently iterating on git-survey(1), > which is the command Stolee proposed a while ago to gather repository > metrics.
I didn't find it in the mailing list, but I remember seeing it in the the GitLab's fork. Is it this unmerged MR? https://gitlab.com/gitlab-org/git/-/merge_requests/369
> Would it make sense to maybe have such whole-repo commands > grouped together in a `git repo` top-level command? E.g. `git repo info` > for your command, `git repo size` to gather information about the repo > size.
It seems to be very nice for me! In fact, this being a home also for statistics is something I considered while writing the first versions of my GSoC proposal.
And what about merging the two codes into a single API? Something like:
```
git repo-info layout.bare references.format survey.commit-count
{
"layout": {
"bare": true
},
"references": {
"format": "files"
},
"survey": {
"commit-count": 42
}
}?
During our meetings, Karthik suggested (I'm planning to it later) to also allow to request an entire category instead of only the fields. Then, this would also be possible:
```
$ git repo-info survey
{
"survey": {
"commit-count": 42,
"blob-count": 1234
}
```But I don't know what are Justin's plans for git-survey, if it would be a porcelain command for showing those stats to the user of if it is targeted for being parsed like this `repo-info`.
I'm just brainstorming because I liked the idea :-)
> Nit: missing colon. It's also present in subsequent patches.
Oops
> Patrick