- Nov 06, 2020
-
-
Gregory Szorc authored
Python 3 is the future. We want Python scripts to be using Python 3 by default. This change updates all `#!/usr/bin/env python` shebangs to use `python3`. Does this mean all scripts use or require Python 3: no. In the test environment, the `PATH` environment variable in tests is updated to guarantee that the Python executable used to run run-tests.py is used. Since test scripts all now use `#!/usr/bin/env python3`, we had to update this code to install a `python3` symlink instead of `python`. It is possible there are some random scripts now executed with the incorrect Python interpreter in some contexts. However, I would argue that this was a pre-existing bug: we should almost always be executing new Python processes using the `sys.executable` from the originating Python script, as `python` or `python3` won't guarantee we'll use the same interpreter. Differential Revision: https://phab.mercurial-scm.org/D9273
-
- Sep 02, 2020
-
-
haraldkl authored
When running Mercurial on Python 3 hgweb expects the config variable to be a bytestring. The solution proposed by Anton Shestakov is to use a byteprefix to the literal string defined cgi script as provided in this patch for hgweb.cgi, contrib/hgweb.fcgi and contrib/hgweb.wsgi. I am not sure whether this covers all relevant templates, but I couldn't find others. Differential Revision: https://phab.mercurial-scm.org/D8978
-
- Nov 16, 2019
-
-
Gregory Szorc authored
These scripts weren't blackened. I found these as part of adding script checking to test-check-format.t. # skip-blame black Differential Revision: https://phab.mercurial-scm.org/D7446
-
- Sep 30, 2015
-
-
Matt Mackall authored
-
- Nov 10, 2011
-
-
Matt Mackall authored
-
- Jul 03, 2010
-
-
Martin Geisler authored
-
- Apr 26, 2010
-
-
Matt Mackall authored
- move important config to the top - add help pointer - drop encoding hack comment (use web.encoding) - simplify imports - use unified hgweb interface
-
- Feb 18, 2008
-
-
Thomas Arendsen Hein authored
-
Thomas Arendsen Hein authored
-
- Feb 12, 2008
-
-
Maxim Dounin authored
-
- Feb 01, 2008
-
-
Bryan O'Sullivan authored
-
- Nov 30, 2007
-
-
Dirkjan Ochtman authored
Less indirection in the WSGI web interface. This simplifies some code, and makes it more compliant with WSGI.
-
- Aug 25, 2007
-
-
Benoit Boissinot authored
thanks to R. Burke
-
- Aug 18, 2007
-
-
Thomas Arendsen Hein authored
This way other applications can choose if and when they want this feature, because it might be problematic if those applications rely on ImportError.
-
- Dec 11, 2006
-
-
Thomas Arendsen Hein authored
- "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.
-
- Dec 04, 2006
-
-
Matt Mackall authored
Add comments on overriding charset to CGI scripts
-
- Jun 27, 2006
-
-
Eric Hopper authored
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
-
- Jun 17, 2005
-
-
mpm authored
-----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-----
-
- Jun 01, 2005
-
-
mpm authored
-
- May 26, 2005
-
-
mpm authored
This gives an example of how to easily use hgweb via CGI
-