Commit Graph

211 Commits

Author SHA1 Message Date
Thomas Arendsen Hein
128a411ed1 merge with crew-stable 2007-09-07 17:54:38 +02:00
Dirkjan Ochtman
a80e1eb528 Prevent WSGI apps from touching sys.stdin by setting ui.interactive to False. 2007-09-07 17:38:52 +02:00
Thomas Arendsen Hein
23916758e6 hgweb: Show date of last change for each file in manifest 2007-08-31 11:18:29 +02:00
Robert Bachmann
ecb337b8cb Added support for the Atom syndication format 2007-08-30 16:42:17 +02:00
Thomas Arendsen Hein
90d76a6ec9 Enable demandimport only in scripts, not in importable modules (issue605)
This way other applications can choose if and when they want this feature,
because it might be problematic if those applications rely on ImportError.
2007-08-18 11:37:08 +02:00
Benoit Boissinot
5c3e74025c merge with -stable 2007-08-09 01:07:11 +02:00
Benoit Boissinot
25ee8ea56b unobfuscate part of fec055ae35cc 2007-08-09 01:04:27 +02:00
Benoit Boissinot
258f71b5a3 merge with -stable 2007-08-08 23:00:01 +02:00
Eric Hopper
e7f6d77433 Fix hgwebdir after aaaee74b883fc144cc3472c81c61157bc69374b6 broke it. 2007-08-08 22:47:30 +02:00
Alexis S. L. Carvalho
9107d93d2f merge with crew-stable 2007-08-06 01:00:10 -03:00
Alexis S. L. Carvalho
ed3d96430e hgweb: don't use os.path.join to build URL parts 2007-08-05 22:36:39 -03:00
Alexis S. L. Carvalho
cba13b82f6 hgwebdir: change os.sep in the name of repos to "/" 2007-08-05 22:36:39 -03:00
Matt Mackall
cd72dc7f1b Merge with crew 2007-07-21 16:44:38 -05:00
Matt Mackall
3e13c68628 Use try/finally pattern to cleanup locks and transactions 2007-07-21 16:02:10 -05:00
Thomas Arendsen Hein
d9d3256252 removed trailing whitespace 2007-07-21 10:30:51 +02:00
Alexis S. L. Carvalho
3b07689b6a serve: respect settings from .hg/hgrc
create_server was looking only at the root ui object, ignoring any
settings from .hg/hgrc.  To keep respecting command-line arguments,
commands.serve must also call repo.ui.setconfig.
2007-07-11 19:56:16 -03:00
Christian Ebert
7a47878736 Use isinstance instead of type == type 2007-07-06 12:02:43 +02:00
Wesley J. Landaker
49f06e37cf Use wsgi.url_scheme instead of ad-hoc CGI checks.
Instead of each place in hgweb_mod that needs to check for SSL or get
the protocol scheme (http vs. https) doing it ad-hoc, make them just
look at the wsgi.url_scheme which because of previous patches is now
always set correctly.
2007-07-12 22:55:44 -07:00
Brendan Cully
a0b3ae0fbb cosmetics 2007-07-12 22:44:16 -07:00
Wesley J. Landaker
90ae651c49 Make hg serve set the wsgi.url_scheme property correctly.
This fixes the bug where hg serve with SSL will always detect the wrong
urlbase for templates. This is also part of unifying the CGI interface
and hg serve interface to both use standard wsgi.
2007-07-12 13:58:36 -06:00
Wesley J. Landaker
feb6c32251 Handle CGI SSL detection via HTTPS environment better.
Some servers send on/off, 0/1, yes/no, and may be upper or lower case.
This fix will handle all of those permutations. It was inspired by the
detection done in in some other wsgi python web applications I looked at.
2007-07-12 13:55:20 -06:00
Alexis S. L. Carvalho
05dd580e30 merge with crew-stable 2007-07-11 20:15:03 -03:00
Wesley J. Landaker
034dcaed92 Make {urlbase} work in templates when https is used. 2007-07-10 10:54:54 -06:00
Brendan Cully
4654693aa4 Add SSL support to hg serve, activated via --certificate option 2007-07-09 22:12:28 -07:00
Brendan Cully
d2d845d908 hgwebdir: check for repo foo before browsing subdirectories of foo/ 2007-07-07 21:55:56 -07:00
Brendan Cully
5d30097ec4 hgweb: browse subdirectories before checking whether parent directory is also a repository 2007-07-07 15:09:08 -07:00
Brendan Cully
4750025032 Last change broke new-style URLs 2007-07-06 10:11:48 -07:00
Brendan Cully
d31b7d1fa4 hgwebdir: do not walk up the given path looking for a repository. It is there or it isn't. 2007-07-06 09:15:17 -07:00
Brendan Cully
2216ff4225 hgwebdir: show only trailing part of path when browsing subdirectories 2007-07-05 19:56:16 -07:00
Brendan Cully
10f4d33bdf hgweb: let hgwebdir browse subdirectories 2007-07-05 19:44:06 -07:00
Alexis S. L. Carvalho
f9b8c79d22 hgweb: use lrwxrwxrwx as the permissions of a symlink 2007-07-03 03:06:40 -03:00
Markus F.X.J. Oberhumer
974b7c5201 Add option "hidden" to hgwebdir.
TODO: should this option be renamed to 'hide_from_index' or
maybe to 'index_ignore' (like Apache's mod_autoindex) ?
2007-06-25 14:46:20 +02:00
OHASHI Hideya
83f32e7ff9 Enable to select encoding in hgrc web section
This patch provides character encoding setting in each repository. After this
patch, You can use multi encoding repositories with one mercurial server.
2007-06-13 18:18:06 +09:00
Thomas Arendsen Hein
1b20c30e25 hgweb_mod.archive(): Use 'key' instead of builtin 'id'. 2007-06-21 19:38:44 +02:00
Thomas Arendsen Hein
4d29c6dc8e Updated copyright notices and add "and others" to "hg version" 2007-06-19 08:51:34 +02:00
Thomas Arendsen Hein
483231d996 Cleanup of whitespace, indentation and line continuation. 2007-06-19 08:06:37 +02:00
Brendan Cully
73b9a0fd82 Small cleanups for the new tag code 2007-06-11 11:06:42 -07:00
Josef "Jeff" Sipek
066eaf6a84 gitweb: Display branch and tag labels
Pages which display labels:
- summary
- shortlog
- changelog
- changeset
- search
2007-06-01 19:56:39 -04:00
Matt Mackall
934033161c hg serve: don't lookup user-supplied names/addresses 2007-06-10 19:16:20 -05:00
Thomas Arendsen Hein
49220695bc Removed trailing whitespace and tabs from python files 2007-06-06 20:22:52 +02:00
Alexis S. L. Carvalho
ae21f631dc merge with crew-stable 2007-06-04 00:26:53 -03:00
Alexis S. L. Carvalho
0e52789888 wsgicgi: change stdin to binary mode 2007-06-04 00:24:48 -03:00
Josef "Jeff" Sipek
77b18ca042 gitweb: Fixed-up search template
It seems that the search template has been forgoten over time, and needed
major revamping.
2007-05-31 20:12:40 -04:00
Thomas Arendsen Hein
3005b8655d hgweb: use generator to count parity of horizontal stripes for easier reading.
- use web.stripes in all places and consistently
- start with parity0 for lists generated in reverse (e.g. changelog)
2007-05-29 16:42:05 +02:00
Josef "Jeff" Sipek
0e1bc7bd9a hgweb: manifest: pass parity for the '[up]' link 2007-05-29 05:08:01 -04:00
Edouard Gomez
52552f6c05 Fix inconsistency for the stream_out capability in hgweb
During some experiments of mine, the uncompressed cloning could not
be enabled for hgweb.cgi nor hgwebdir.cgi though the server claimed
to be stream_out capable.

The only solution was to enable it using the user's .hgrc file.
This solution is not acceptable when publishing the repos through
an HTTP server because the CGI runs as a www dedicated user whose's
home hgrc file may not be accessible to users publishing their repos
through their userdir.

For such cases we could end up with this typical debug output:
hg --debug clone --uncompressed http://server/hg/project
destination directory: project
sending capabilities command
capabilities: lookup changegroupsubset stream=1
unbundle=HG10GZ,HG10BZ,HG10UN
sending stream_out command
abort: operation forbidden by server

The error lies in the fact the hgweb object defines new accessors
to the repo configuration that trust things by default (untrusted=True)
but the streamclone:stream_out function uses the usual accessors to the
repo.ui object, which do not trust by default (untrusted=False)

Fix this inconsistency, adding a new parameter to the stream_out function.
hgweb then forces a "trust by default" behavior.
2007-05-12 00:41:30 +02:00
Matt Mackall
6f71aab47d Merge with stable 2007-04-26 18:41:18 -05:00
Matt Mackall
584e6c9643 hg serve: don't do DNS lookups 2007-04-25 13:35:18 -05:00
Matt Mackall
765aba6082 Merge with stable 2007-04-16 09:52:37 -05:00
Matt Mackall
8392cf0d15 hgweb: fix rfind bug in PATH_INFO handling 2007-04-16 09:51:50 -05:00