jimhester / jimhester.com

15 stars 8 forks source link

How can I integrate the github contributions to my blog #2

Open luiscachog opened 4 years ago

luiscachog commented 4 years ago

Hello Jim,

This is not an issue, I just want to know how can I implement the GitHub contributions calendar on my own blog. It is pretty awesome!!!

I'm not familiar with R, but if you can give me some light I will apreciate

jimhester commented 4 years ago

The code is at https://github.com/jimhester/jimhester.com/blob/388e8048ac5f24db2bed19ba6bf961ca8432c905/content/home/demo.Rmd#L26-L37

GitHub doesn't have an API to get the calendar data, so I just pull my personal landing page and extract the SVG from it, which contains the count data, I then aggregate the rest of the non-github information with it and recreate the plot.