jbon / Github-Social-Network-Analysis

Social Network Analisys of GitHub
1 stars 2 forks source link

Extract more commit properties #3

Closed jbon closed 7 years ago

jbon commented 7 years ago

...and store them as a node attribute How to do this:

In the header of the XML tree, add: SubElement(graphml, 'key', { "for":"node", "id":"<anyUniqueId>", "attr.name":"<AttrName>", "attr.type":"<dataType>"}) And in the XML node description, add:

attributeData = SubElement(node, "data", {"key":"<attrName>"})
attributeData.text = <DataContent>

Example of commit property to extract: github.GitCommit.GitCommit.date

Extract all data that may help further analysis of the commit network

kerstinopen commented 7 years ago

I included the commit url and information about the comments on commits. Up to now, the script can extract the body, date of creation and creator of comments on commits, but it would be possible to extract more (https://developer.github.com/v3/repos/comments/), Im not sure if thats necessary, what do you think?

kerstinopen commented 7 years ago

( see pull request "Update #2 branch-network-mining.py")

jbon commented 7 years ago

Property github.GitCommit.GitCommit.date isn't extracted for the moment

jbon commented 7 years ago

http://stackoverflow.com/questions/14909110/github-api-for-python-pygithub-get-a-list-of-all-commits-for-a-particular-re https://github.com/PyGithub/PyGithub/issues/54