Bitbucket is a code hosting site with unlimited public and private repositories. We're also free for small teams!

Close
A modified version of the SimpleHTTPRequestHandler to serve source code highlighted versions of files that are understood by Pygments (http://pygments.org)

Requires a working installation of pygments.

run the script in the root directory of the source tree that you wish to browse.  Connect to http://localhost:8000 and
navigate the tree.  Files that can be displayed should be displayed with appropriate formating.

Change the server address at line 107 if you want to host it somewhere other than localhost.  The port can be changed on the commandline (pygments-server.py <portnumber>) when running the script.

May not correctly handle some non-ASCII encodings.  

Gordon
gordon.mcgregor@verilab.com


Recent activity

Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.