Commit Graph

6 Commits

Author SHA1 Message Date
Thomas Arendsen Hein
dc76f842d3 hgweb.cgi and hgwebdir.cgi fixes/cleanups for user configurable parts:
- "import os" was missing in hgwebdir.cgi, added to comments for both script.
- HGENCODING has to be set before importing hgweb, otherwise you'll get
  mixed encoding in changelog vs. file content/diffs.
- "import sys" is only needed when changing sys.path
- document purpose of cgitb.
2006-12-11 14:30:50 +01:00
Matt Mackall
cdbe57fc80 hgweb: report detected character set
Add comments on overriding charset to CGI scripts
2006-12-03 18:47:05 -06:00
Eric Hopper
4498f60ff4 This patch make several WSGI related alterations.
First, it changes the server to be almost a generic WSGI server.

Second, it changes request.py to have wsgiapplication and
_wsgirequest.  wsgiapplication is a class that creates _wsgirequests
when called by a WSGI compliant server.  It needs to know whether
or not it should create hgwebdir or hgweb requests.

Lastly, wsgicgi.py is added, and the CGI scripts are altered to
use it to launch wsgiapplications in a WSGI compliant way.

As a side effect, all the keepalive code has been removed from
request.py.  This code needs to be moved so that it is exclusively
in server.py
2006-06-27 00:09:33 -07:00
mpm@selenic.com
8098f7c792 hgweb: pull cgitb into CGI script example, where it can easily be disabled
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

hgweb: pull cgitb into CGI script example, where it can easily be disabled

This also eliminates cgitb dumps in the logging output of hg serve

manifest hash: a0aa07a706c2c388c0b49505e2960197f716920c
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)

iD8DBQFCsv9DywK+sNU5EO8RAieFAJwOjdfkz7pILNVUTvpMkRa6/OIhIQCgo2TP
I2E4hxQ0N7mTtl45pXEFLsk=
=tG0v
-----END PGP SIGNATURE-----
2005-06-17 08:50:11 -08:00
mpm@selenic.com
5c1b6c547d Call python via env in hgweb.cgi 2005-05-31 21:24:14 -08:00
mpm@selenic.com
970955c99d Add example CGI script
This gives an example of how to easily use hgweb via CGI
2005-05-25 16:28:23 -08:00