mkdocs-git-committers-plugin-2 icon indicating copy to clipboard operation
mkdocs-git-committers-plugin-2 copied to clipboard

Pickup the actual username instead of login name for Github

Open vrenjith opened this issue 6 months ago • 4 comments

vrenjith avatar Jun 04 '25 18:06 vrenjith

Thank you for this. Would it be possible to fallback to login if name is empty / does not exist? This will preserve earlier behavior with a nice fallback. Ideally, a setting which will allow to choose between name and login (defaulting to login to ensure backward compatibility)

Thanks!

ojacques avatar Jun 05 '25 13:06 ojacques

Thank you for this. Would it be possible to fallback to login if name is empty / does not exist? This will preserve earlier behavior with a nice fallback. Ideally, a setting which will allow to choose between name and login (defaulting to login to ensure backward compatibility)

Thanks!

  • That is a good suggestion. I just added that condition to pick up the old behaviour if the name does not exist
  • Also I added saving of the cache after every update of the internal dict. I see that it saves us because in many cases we are hitting API limits and if we have the cache saved everytime, when we rerun the whole build again, it will skip all the items which we already figured out and start from the next of files and eventually it will succeed. Let me know your comments.

vrenjith avatar Jun 05 '25 16:06 vrenjith

Again, thank you. I tried this version, but could not find "name" to be populated in the commit informations. Do you use GitHub or GitLab?

ojacques avatar Jun 15 '25 16:06 ojacques

I updated the code again.

vrenjith avatar Jun 16 '25 03:06 vrenjith