anuraghazra / github-readme-stats

:zap: Dynamically generated stats for your github readmes
https://github-readme-stats.vercel.app
MIT License
68.47k stars 22.47k forks source link

Display number of co-authors #2244

Open CaedenPH opened 1 year ago

CaedenPH commented 1 year ago

Is your feature request related to a problem? Please describe.

I'm always frustrated when I don't know how many commits I have co-authored or how many discussions I have answered...

Describe the solution you'd like

Perhaps more fields in the github-stats-card containing information about the number of discussions answered and total co-authors

Describe alternatives you've considered

No response

Additional context

image You don't know how many co-authors you have after you hit 4x

rickstaa commented 1 year ago

@CaedenPH Thanks for your feature request. I am also curious to know how much PR I have co-authored. However, I'm unsure how interested others are in seeing a user's co-authored count 🤔. It would make more sense to add a feature request to https://github.com/community/community asking whether GitHub can show the co-authored count on the badge overview. I think similar stats should be shown on the Galaxy Brain, Galaxy Brain and StarGazer badges. Alternatively, we could make a small web API on which users can retrieve this data. What do you think?

rickstaa commented 1 year ago

@CaedenPH I just saw that https://github.com/anuraghazra/github-readme-stats/issues/1991 already requests the discussion information to be added to the stats card. You can add your support for that feature there.

Regarding the co-authored information, I'm happy to merge a PR into the main branch if enough interest is expressed for his feature from the community (see https://github.com/anuraghazra/github-readme-stats/issues/1935). I, however, could not find an easy way to find the number of co-authored commits using the GraphQL API. This information only seems to be available on the commit level (see https://docs.github.com/en/graphql/reference/objects#commit). Showing this information on the stats card will be too costly since we need to go through all PR commits of all PRs to retrieve it. Before implementing such a feature, we should add a feature request to https://github.com/community/community in which we request this information to be included under the GraphQL user object.