Merging GitHub accounts - contributions and stats

。_饼干妹妹 提交于 2021-02-10 20:21:07

问题


I want to merge my two GitHub accounts (meaning transferring repositories ownership to one account, and deleting the other, according to https://help.github.com/articles/transferring-a-repository/). Do my other account will inherit the contributions number (and therefore contribution graph and activity overview) from my old account? In other words, what determines the number of contributions in a GitHub account: is it when the email address of the commit correspond to one of the email adresses associated with my GitHub account?

I have read Merging two github accounts but it doesn't answer the number of contributions question.


回答1:


Transferred repos will inherit issues, pull request, contribution history, stars, watches.

The contribution history is a different story, and how it's calculated is explained here: https://help.github.com/articles/viewing-contributions-on-your-profile/ To quote from there:

What counts as a contribution

On your profile page, certain actions count as contributions:

  • Committing to a repository's default branch or gh-pages branch
  • Opening an issue
  • Proposing a pull request
  • Submitting a pull request review
  • Co-authoring commits in a repository's default branch or gh-pages branch

Assume you have 2 users: A <a@gmail.com>, B <b@gmail.com> and you're merging B into A:

  • Events like "opening a PR", "opening an issue", "commenting on issue/PR", "making code review on a PR" which count as contribution on B's profile will be lost
  • Events like "commits" on the master branch will be added to A –if you add b@gmail.com as one of your emails in A’s account settings

when you transfer B's repos to A, and then delete account B.



来源:https://stackoverflow.com/questions/54262958/merging-github-accounts-contributions-and-stats

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!