On Mon, Feb 9, 2009 at 8:17 AM, Dana <woodman.d...@gmail.com> wrote:
>
> Hi all,
>
> Wondering what the best approach would be to add my projects revision
> number to my projects admin? I would like to show the revision number
> of my SVNed project in my admin templates so I can easily see what
> version each client is running. How would one go about doing this?

Two steps:

1) Look at django.utils.version.get_svn_revision(). This method tells
you Django's SVN revision. Make a copy of this method and modify it to
point at your own code, telling you the version of your clients SVN
checkout.

2) Write a template context processor to insert that version number
into the context.

When you install the template context processor, the SVN revision will
become available to every template.

Yours,
Russ Magee %-)

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to