Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Exporting the change log from a commit on GitHub

Tags:

git

github

I've got a collaborator that's not GH-friendly and not likely to become so in the near future.

I'd like to show him line-by-line the changes I've made to a paper, and the commit comparison is the perfect way to do so.

But they've no account and the repository is (and will remain) private.

Is there any way to export the track changes log from GitHub to another format which could be sent to my collaborator more readily?

like image 650
MichaelChirico Avatar asked Oct 06 '15 20:10

MichaelChirico


People also ask

How do I export a commit?

Tower allows you to export a project's complete file tree at any given revision. To do so, right-click the revision in a commit listing and choose Export Files from <commit hash>… from the contextual menu.

How do I export data from GitHub to excel?

In Excel, on Ribbon, click Data > Get Data > From JSON. In dialog box, enter API URL ... in format similar to (add parms as you wish): https://api.github.com/repos/{owner}/{repo}/issues. A dialog box labeled "Access Web content" will appear. On the left-hand side, click the Basic tab.


2 Answers

So for the colored output you need some additional tool like aha - it's ansi to html adapter. The final version might look like this. git log -p -n 2 --color=always | aha --black > output.html

like image 130
grimsock Avatar answered Oct 23 '22 03:10

grimsock


If you like the GitHub diff, you can view it on GitHub from your browser, use your browser's "save page" to get an HTML file to send to your collaborator.

To get an all-in-one diff from GitHub, append /compare to the URL of your repository (more details GitHub's documentation). Then pick the view you like, and save it to HTML.

like image 44
Matthieu Moy Avatar answered Oct 23 '22 04:10

Matthieu Moy