Permalink
Browse files

Documentation for the project as a whole.

  • Loading branch information...
1 parent 2c2b375 commit 34b63dcf90a34e61c551f4127218dcf392c50b22 @justinabrahms justinabrahms committed Sep 12, 2012
Showing with 22 additions and 0 deletions.
  1. +20 −0 README.rst
  2. +2 −0 robotars/templatetags/robotars_tags.py
View
@@ -1,3 +1,23 @@
========
robotars
========
+
+Generate robot avatars with optional support for being a gravatar
+fallback.
+
+Usage:
+
+::
+
+ {% load robotars_tags %}
+ {% robotar "bob@example.org" %}
+ {# with gravatar fallback and size #}
+ {% robotar "bob@example.org" "63x63" 1 1 %}
+
+You can optionally pass the following arguments:
+
+* size: The size of the robohash to be generated. eg "63x63"
+* gravatar_fallback: whether robohash should be the fallback for the
+ gravatar service
+* hashed: whether your user's email address should be obscured from
+ robohash.
@@ -3,8 +3,10 @@
from django import template
from md5 import md5
+
register = template.Library()
+
@register.inclusion_tag("robotars/robotar.html")
def robotar(user, size=None, gravatar_fallback=False, hashed=False):
_user = user

0 comments on commit 34b63dc

Please sign in to comment.