Skip to content

Instantly share code, notes, and snippets.

@burntcookie90
Last active February 23, 2021 03:51
Show Gist options
  • Save burntcookie90/c12b786e44af0df74414286c35ee79d7 to your computer and use it in GitHub Desktop.
Save burntcookie90/c12b786e44af0df74414286c35ee79d7 to your computer and use it in GitHub Desktop.
runs linguist on ever commit since a date
#!/usr/bin/bash
for commit in $(git --no-pager log --reverse --after="2016-10-01T10:36:00-07:00" --pretty=format:%H)
do
echo $commit
git checkout $commit
#write linguist data to a file
echo "" >> ~/repo-linguist-report.txt
echo "commit: $commit" >> ~/repo-linguist-report.txt
github-linguist >> ~/repo-linguist-report.txt
#write commit dates to another file, because we're lazy
echo "commit: $commit" >> ~/repo-commit-dates.txt
git show -s --format=%ci $commit >> ~/repo-commit-dates.txt
done
@burntcookie90
Copy link
Author

@nuhkoca
Copy link

nuhkoca commented Nov 11, 2019

Thanks @burntcookie90

May I ask how to view such a chart for my project after executing this command? I executed it and it finished but I don't know what to do next.

@burntcookie90
Copy link
Author

@nuhkoca, sorry for the necro reply i totally missed your comment! We ended up just sticking the data in a google sheet and charting it there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment