Login

Snippets by felix_the_third

Snippet List

DebugMiddleware footer with links to quick open file/line# in TextMate on local machine

Adds a hidden footer to the bottom of every text/html page containing a list of SQL queries executed, the view function that was used and all templates that were loaded. Each template path is a clickable URL of the type txmt://open/?url=file://FILENAME&line=LINENO as is the view function. This lets you open the file very quickly in TextMate which speeds up development considerably and relieves the mind of much fetching-lookup tedium. This version works on SVN 12002 (1.2 alpha) and earlier. The previous version was: http://www.djangosnippets.org/snippets/1033/ which got caught but some edge case in certain modules. It is based on the original by Simon http://www.djangosnippets.org/snippets/766/ To use save this as 'debug_middleware.py' somewhere on your PYTHONPATH and add 'debug_middleware.DebugFooter' to your MIDDLEWARE_CLASSES setting. - Felix (the Third) hey wouldn't it be great if you could retrieve your password on djangosnippets ? somebody should volunteer to upgrade it

  • middleware
  • debug
  • textmate
Read More

felix_the_third has posted 1 snippet.