Skip to content
Browse files

Added gravatar to the achievements

  • Loading branch information...
1 parent e323a7c commit 7541a6460accbbe15ae4fc8662bedbc0cfd3969c @acasajus acasajus committed with icefox Jun 8, 2011
Showing with 6 additions and 1 deletion.
  1. +2 −1 git-achievements
  2. +4 −0 style.css
View
3 git-achievements
@@ -386,7 +386,8 @@ echo "
</head>
<body>
" > index.html
- echo "<h2>${user}'s Git Achievements</h2>" >> index.html
+ mailhash=`git config --global user.email | xargs echo -n | tr '[A-Z]' '[a-z]' | openssl md5`
+ echo "<h2>${user}'s Git Achievements <img src='http://www.gravatar.com/avatar/${mailhash}'/></h2>" >> index.html
# STATS
cat git-achievements | grep 'unlock_achievement ' | grep -v ' sed ' | grep -v '\${' | sed -e 's/.*unlock_achievement //g' -e 's/^"//g' -e 's/"$//g' -e 's/\$power/X/g' -e 's/\$count/X/g' -e 's/\$hooks/X/g' | sort | awk -F"\" \"" '{ print "<li><div class=\"title\">" $1 "</div><div class=\"info\">" $2 "</div></li>" }' | link_to_git_docs > all.html
View
4 style.css
@@ -11,6 +11,10 @@ body {
width: 700px;
text-align: center;
}
+img {
+ float : right;
+ height : 50px;
+}
li {
background-color: #1E2024;
border: 1px solid gray;

0 comments on commit 7541a64

Please sign in to comment.
Something went wrong with that request. Please try again.