Mercurial > hg
annotate tests/test-hgweb.t @ 25727:b8245386ab40
templatekw: make {latesttag} a hybrid list
This maintains the previous behavior of expanding {latesttag} to a string
containing all of the tags, joined by ':'. But now it also allows list type
operations.
I'm unsure if the plural handling is correct (i.e. it seems like it is usually
"{foos % '{foo}'}"), but I guess we are stuck with this because the singular
form previously existed.
author | Matt Harbison <matt_harbison@yahoo.com> |
---|---|
date | Mon, 06 Jul 2015 23:23:22 -0400 |
parents | 63be46407a50 |
children | 1c2a8db33b8f |
rev | line source |
---|---|
22046
7a9cbb315d84
tests: replace exit 80 with #require
Matt Mackall <mpm@selenic.com>
parents:
20256
diff
changeset
|
1 #require serve |
15446
c5c9ca3719f9
tests: use 'hghave serve' to guard tests that requires serve daemon management
Mads Kiilerich <mads@kiilerich.com>
parents:
14046
diff
changeset
|
2 |
12432 | 3 Some tests for hgweb. Tests static files, plain files and different 404's. |
4 | |
5 $ hg init test | |
6 $ cd test | |
7 $ mkdir da | |
8 $ echo foo > da/foo | |
9 $ echo foo > foo | |
10 $ hg ci -Ambase | |
11 adding da/foo | |
12 adding foo | |
13 $ hg serve -n test -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log | |
14 $ cat hg.pid >> $DAEMON_PIDS | |
15 | |
16 manifest | |
3942 | 17 |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
24303
diff
changeset
|
18 $ (get-with-headers.py localhost:$HGPORT 'file/tip/?style=raw') |
12432 | 19 200 Script output follows |
20 | |
21 | |
22 drwxr-xr-x da | |
23 -rw-r--r-- 4 foo | |
24 | |
25 | |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
24303
diff
changeset
|
26 $ (get-with-headers.py localhost:$HGPORT 'file/tip/da?style=raw') |
12432 | 27 200 Script output follows |
28 | |
29 | |
30 -rw-r--r-- 4 foo | |
31 | |
32 | |
33 | |
34 plain file | |
35 | |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
24303
diff
changeset
|
36 $ get-with-headers.py localhost:$HGPORT 'file/tip/foo?style=raw' |
12432 | 37 200 Script output follows |
38 | |
39 foo | |
40 | |
41 should give a 404 - static file that does not exist | |
9842
d3dbdca92458
hgweb: don't choke when an inexistent style is requested (issue1901)
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents:
8167
diff
changeset
|
42 |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
24303
diff
changeset
|
43 $ get-with-headers.py localhost:$HGPORT 'static/bogus' |
12432 | 44 404 Not Found |
45 | |
46 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> | |
47 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US"> | |
48 <head> | |
49 <link rel="icon" href="/static/hgicon.png" type="image/png" /> | |
50 <meta name="robots" content="index, nofollow" /> | |
51 <link rel="stylesheet" href="/static/style-paper.css" type="text/css" /> | |
14046
b24e5a708fad
web: Made elapsed time calculation dynamic (javascript).
Benoit Allard <benoit@aeteurope.nl>
parents:
13863
diff
changeset
|
52 <script type="text/javascript" src="/static/mercurial.js"></script> |
12432 | 53 |
54 <title>test: error</title> | |
55 </head> | |
56 <body> | |
57 | |
58 <div class="container"> | |
59 <div class="menu"> | |
60 <div class="logo"> | |
61 <a href="http://mercurial.selenic.com/"> | |
62 <img src="/static/hglogo.png" width=75 height=90 border=0 alt="mercurial" /></a> | |
63 </div> | |
64 <ul> | |
65 <li><a href="/shortlog">log</a></li> | |
66 <li><a href="/graph">graph</a></li> | |
67 <li><a href="/tags">tags</a></li> | |
13597
38c9837b1f75
hgweb: add separate page with bookmarks listing
Alexander Solovyov <alexander@solovyov.net>
parents:
12846
diff
changeset
|
68 <li><a href="/bookmarks">bookmarks</a></li> |
12432 | 69 <li><a href="/branches">branches</a></li> |
17290
7a9246abf9fe
hgweb: make paper:error consistent with template
Ross Lagerwall <rosslagerwall@gmail.com>
parents:
17243
diff
changeset
|
70 </ul> |
7a9246abf9fe
hgweb: make paper:error consistent with template
Ross Lagerwall <rosslagerwall@gmail.com>
parents:
17243
diff
changeset
|
71 <ul> |
12680
d664547ef540
hgweb: add help link to templates missed in ead4e21f49f1
Augie Fackler <durin42@gmail.com>
parents:
12666
diff
changeset
|
72 <li><a href="/help">help</a></li> |
12432 | 73 </ul> |
74 </div> | |
75 | |
76 <div class="main"> | |
77 | |
18264
d6ebdbdd70a5
tests: update hgweb tests to include breadcrumbs
Bryan O'Sullivan <bryano@fb.com>
parents:
17466
diff
changeset
|
78 <h2 class="breadcrumb"><a href="/">Mercurial</a> </h2> |
12432 | 79 <h3>error</h3> |
80 | |
81 <form class="search" action="/log"> | |
82 | |
83 <p><input name="rev" id="search1" type="text" size="30"></p> | |
19796
544848ef65f2
paper: edit search hint to include new feature description
Alexander Plavin <alexander@plav.in>
parents:
19795
diff
changeset
|
84 <div id="hint">Find changesets by keywords (author, files, the commit message), revision |
544848ef65f2
paper: edit search hint to include new feature description
Alexander Plavin <alexander@plav.in>
parents:
19795
diff
changeset
|
85 number or hash, or <a href="/help/revsets">revset expression</a>.</div> |
12432 | 86 </form> |
87 | |
88 <div class="description"> | |
89 <p> | |
90 An error occurred while processing your request: | |
91 </p> | |
92 <p> | |
93 Not Found | |
94 </p> | |
95 </div> | |
96 </div> | |
97 </div> | |
98 | |
14046
b24e5a708fad
web: Made elapsed time calculation dynamic (javascript).
Benoit Allard <benoit@aeteurope.nl>
parents:
13863
diff
changeset
|
99 <script type="text/javascript">process_dates()</script> |
12432 | 100 |
101 | |
102 </body> | |
103 </html> | |
104 | |
105 [1] | |
106 | |
107 should give a 404 - bad revision | |
108 | |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
24303
diff
changeset
|
109 $ get-with-headers.py localhost:$HGPORT 'file/spam/foo?style=raw' |
12432 | 110 404 Not Found |
111 | |
112 | |
113 error: revision not found: spam | |
114 [1] | |
115 | |
116 should give a 400 - bad command | |
9842
d3dbdca92458
hgweb: don't choke when an inexistent style is requested (issue1901)
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents:
8167
diff
changeset
|
117 |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
24303
diff
changeset
|
118 $ get-with-headers.py localhost:$HGPORT 'file/tip/foo?cmd=spam&style=raw' |
12432 | 119 400* (glob) |
120 | |
121 | |
122 error: no such method: spam | |
123 [1] | |
124 | |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
24303
diff
changeset
|
125 $ get-with-headers.py --headeronly localhost:$HGPORT '?cmd=spam' |
22506
6e1fbcb18a75
hgweb: fail if an invalid command was supplied in url path (issue4071)
Anton Shestakov <engored@ya.ru>
parents:
20256
diff
changeset
|
126 400 no such method: spam |
6e1fbcb18a75
hgweb: fail if an invalid command was supplied in url path (issue4071)
Anton Shestakov <engored@ya.ru>
parents:
20256
diff
changeset
|
127 [1] |
6e1fbcb18a75
hgweb: fail if an invalid command was supplied in url path (issue4071)
Anton Shestakov <engored@ya.ru>
parents:
20256
diff
changeset
|
128 |
6e1fbcb18a75
hgweb: fail if an invalid command was supplied in url path (issue4071)
Anton Shestakov <engored@ya.ru>
parents:
20256
diff
changeset
|
129 should give a 400 - bad command as a part of url path (issue4071) |
6e1fbcb18a75
hgweb: fail if an invalid command was supplied in url path (issue4071)
Anton Shestakov <engored@ya.ru>
parents:
20256
diff
changeset
|
130 |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
24303
diff
changeset
|
131 $ get-with-headers.py --headeronly localhost:$HGPORT 'spam' |
22506
6e1fbcb18a75
hgweb: fail if an invalid command was supplied in url path (issue4071)
Anton Shestakov <engored@ya.ru>
parents:
20256
diff
changeset
|
132 400 no such method: spam |
6e1fbcb18a75
hgweb: fail if an invalid command was supplied in url path (issue4071)
Anton Shestakov <engored@ya.ru>
parents:
20256
diff
changeset
|
133 [1] |
6e1fbcb18a75
hgweb: fail if an invalid command was supplied in url path (issue4071)
Anton Shestakov <engored@ya.ru>
parents:
20256
diff
changeset
|
134 |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
24303
diff
changeset
|
135 $ get-with-headers.py --headeronly localhost:$HGPORT 'raw-spam' |
22506
6e1fbcb18a75
hgweb: fail if an invalid command was supplied in url path (issue4071)
Anton Shestakov <engored@ya.ru>
parents:
20256
diff
changeset
|
136 400 no such method: spam |
6e1fbcb18a75
hgweb: fail if an invalid command was supplied in url path (issue4071)
Anton Shestakov <engored@ya.ru>
parents:
20256
diff
changeset
|
137 [1] |
6e1fbcb18a75
hgweb: fail if an invalid command was supplied in url path (issue4071)
Anton Shestakov <engored@ya.ru>
parents:
20256
diff
changeset
|
138 |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
24303
diff
changeset
|
139 $ get-with-headers.py --headeronly localhost:$HGPORT 'spam/tip/foo' |
22506
6e1fbcb18a75
hgweb: fail if an invalid command was supplied in url path (issue4071)
Anton Shestakov <engored@ya.ru>
parents:
20256
diff
changeset
|
140 400 no such method: spam |
6e1fbcb18a75
hgweb: fail if an invalid command was supplied in url path (issue4071)
Anton Shestakov <engored@ya.ru>
parents:
20256
diff
changeset
|
141 [1] |
6e1fbcb18a75
hgweb: fail if an invalid command was supplied in url path (issue4071)
Anton Shestakov <engored@ya.ru>
parents:
20256
diff
changeset
|
142 |
12432 | 143 should give a 404 - file does not exist |
5561
22713dce19f6
hgweb: return meaningful HTTP status codes instead of nonsense
Bryan O'Sullivan <bos@serpentine.com>
parents:
5384
diff
changeset
|
144 |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
24303
diff
changeset
|
145 $ get-with-headers.py localhost:$HGPORT 'file/tip/bork?style=raw' |
12432 | 146 404 Not Found |
147 | |
148 | |
149 error: bork@2ef0ac749a14: not found in manifest | |
150 [1] | |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
24303
diff
changeset
|
151 $ get-with-headers.py localhost:$HGPORT 'file/tip/bork' |
12432 | 152 404 Not Found |
153 | |
154 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> | |
155 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US"> | |
156 <head> | |
157 <link rel="icon" href="/static/hgicon.png" type="image/png" /> | |
158 <meta name="robots" content="index, nofollow" /> | |
159 <link rel="stylesheet" href="/static/style-paper.css" type="text/css" /> | |
14046
b24e5a708fad
web: Made elapsed time calculation dynamic (javascript).
Benoit Allard <benoit@aeteurope.nl>
parents:
13863
diff
changeset
|
160 <script type="text/javascript" src="/static/mercurial.js"></script> |
12432 | 161 |
162 <title>test: error</title> | |
163 </head> | |
164 <body> | |
165 | |
166 <div class="container"> | |
167 <div class="menu"> | |
168 <div class="logo"> | |
169 <a href="http://mercurial.selenic.com/"> | |
170 <img src="/static/hglogo.png" width=75 height=90 border=0 alt="mercurial" /></a> | |
171 </div> | |
172 <ul> | |
173 <li><a href="/shortlog">log</a></li> | |
174 <li><a href="/graph">graph</a></li> | |
175 <li><a href="/tags">tags</a></li> | |
13597
38c9837b1f75
hgweb: add separate page with bookmarks listing
Alexander Solovyov <alexander@solovyov.net>
parents:
12846
diff
changeset
|
176 <li><a href="/bookmarks">bookmarks</a></li> |
12432 | 177 <li><a href="/branches">branches</a></li> |
17290
7a9246abf9fe
hgweb: make paper:error consistent with template
Ross Lagerwall <rosslagerwall@gmail.com>
parents:
17243
diff
changeset
|
178 </ul> |
7a9246abf9fe
hgweb: make paper:error consistent with template
Ross Lagerwall <rosslagerwall@gmail.com>
parents:
17243
diff
changeset
|
179 <ul> |
12680
d664547ef540
hgweb: add help link to templates missed in ead4e21f49f1
Augie Fackler <durin42@gmail.com>
parents:
12666
diff
changeset
|
180 <li><a href="/help">help</a></li> |
12432 | 181 </ul> |
182 </div> | |
183 | |
184 <div class="main"> | |
185 | |
18264
d6ebdbdd70a5
tests: update hgweb tests to include breadcrumbs
Bryan O'Sullivan <bryano@fb.com>
parents:
17466
diff
changeset
|
186 <h2 class="breadcrumb"><a href="/">Mercurial</a> </h2> |
12432 | 187 <h3>error</h3> |
188 | |
189 <form class="search" action="/log"> | |
190 | |
191 <p><input name="rev" id="search1" type="text" size="30"></p> | |
19796
544848ef65f2
paper: edit search hint to include new feature description
Alexander Plavin <alexander@plav.in>
parents:
19795
diff
changeset
|
192 <div id="hint">Find changesets by keywords (author, files, the commit message), revision |
544848ef65f2
paper: edit search hint to include new feature description
Alexander Plavin <alexander@plav.in>
parents:
19795
diff
changeset
|
193 number or hash, or <a href="/help/revsets">revset expression</a>.</div> |
12432 | 194 </form> |
195 | |
196 <div class="description"> | |
197 <p> | |
198 An error occurred while processing your request: | |
199 </p> | |
200 <p> | |
201 bork@2ef0ac749a14: not found in manifest | |
202 </p> | |
203 </div> | |
204 </div> | |
205 </div> | |
206 | |
14046
b24e5a708fad
web: Made elapsed time calculation dynamic (javascript).
Benoit Allard <benoit@aeteurope.nl>
parents:
13863
diff
changeset
|
207 <script type="text/javascript">process_dates()</script> |
12432 | 208 |
209 | |
210 </body> | |
211 </html> | |
212 | |
213 [1] | |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
24303
diff
changeset
|
214 $ get-with-headers.py localhost:$HGPORT 'diff/tip/bork?style=raw' |
12432 | 215 404 Not Found |
216 | |
217 | |
218 error: bork@2ef0ac749a14: not found in manifest | |
219 [1] | |
5561
22713dce19f6
hgweb: return meaningful HTTP status codes instead of nonsense
Bryan O'Sullivan <bos@serpentine.com>
parents:
5384
diff
changeset
|
220 |
12432 | 221 try bad style |
5561
22713dce19f6
hgweb: return meaningful HTTP status codes instead of nonsense
Bryan O'Sullivan <bos@serpentine.com>
parents:
5384
diff
changeset
|
222 |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
24303
diff
changeset
|
223 $ (get-with-headers.py localhost:$HGPORT 'file/tip/?style=foobar') |
12432 | 224 200 Script output follows |
225 | |
226 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> | |
227 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US"> | |
228 <head> | |
229 <link rel="icon" href="/static/hgicon.png" type="image/png" /> | |
230 <meta name="robots" content="index, nofollow" /> | |
231 <link rel="stylesheet" href="/static/style-paper.css" type="text/css" /> | |
14046
b24e5a708fad
web: Made elapsed time calculation dynamic (javascript).
Benoit Allard <benoit@aeteurope.nl>
parents:
13863
diff
changeset
|
232 <script type="text/javascript" src="/static/mercurial.js"></script> |
12432 | 233 |
234 <title>test: 2ef0ac749a14 /</title> | |
235 </head> | |
236 <body> | |
237 | |
238 <div class="container"> | |
239 <div class="menu"> | |
240 <div class="logo"> | |
241 <a href="http://mercurial.selenic.com/"> | |
242 <img src="/static/hglogo.png" alt="mercurial" /></a> | |
243 </div> | |
244 <ul> | |
25606
3bb6f5f478a7
hgweb: don't dereference symbolic revision in paper & coal style (issue2296)
Anton Shestakov <av6@dwimlabs.net>
parents:
25474
diff
changeset
|
245 <li><a href="/shortlog/tip">log</a></li> |
3bb6f5f478a7
hgweb: don't dereference symbolic revision in paper & coal style (issue2296)
Anton Shestakov <av6@dwimlabs.net>
parents:
25474
diff
changeset
|
246 <li><a href="/graph/tip">graph</a></li> |
12432 | 247 <li><a href="/tags">tags</a></li> |
13597
38c9837b1f75
hgweb: add separate page with bookmarks listing
Alexander Solovyov <alexander@solovyov.net>
parents:
12846
diff
changeset
|
248 <li><a href="/bookmarks">bookmarks</a></li> |
12432 | 249 <li><a href="/branches">branches</a></li> |
250 </ul> | |
251 <ul> | |
25606
3bb6f5f478a7
hgweb: don't dereference symbolic revision in paper & coal style (issue2296)
Anton Shestakov <av6@dwimlabs.net>
parents:
25474
diff
changeset
|
252 <li><a href="/rev/tip">changeset</a></li> |
12432 | 253 <li class="active">browse</li> |
254 </ul> | |
255 <ul> | |
256 | |
257 </ul> | |
12666
ead4e21f49f1
web: add a help view for getting hg help output
Augie Fackler <durin42@gmail.com>
parents:
12432
diff
changeset
|
258 <ul> |
ead4e21f49f1
web: add a help view for getting hg help output
Augie Fackler <durin42@gmail.com>
parents:
12432
diff
changeset
|
259 <li><a href="/help">help</a></li> |
ead4e21f49f1
web: add a help view for getting hg help output
Augie Fackler <durin42@gmail.com>
parents:
12432
diff
changeset
|
260 </ul> |
12432 | 261 </div> |
262 | |
263 <div class="main"> | |
18264
d6ebdbdd70a5
tests: update hgweb tests to include breadcrumbs
Bryan O'Sullivan <bryano@fb.com>
parents:
17466
diff
changeset
|
264 <h2 class="breadcrumb"><a href="/">Mercurial</a> </h2> |
25617
63be46407a50
hgweb: link to revision by node hash in paper & coal
Anton Shestakov <av6@dwimlabs.net>
parents:
25606
diff
changeset
|
265 <h3> |
63be46407a50
hgweb: link to revision by node hash in paper & coal
Anton Shestakov <av6@dwimlabs.net>
parents:
25606
diff
changeset
|
266 directory / @ 0:<a href="/rev/2ef0ac749a14">2ef0ac749a14</a> |
63be46407a50
hgweb: link to revision by node hash in paper & coal
Anton Shestakov <av6@dwimlabs.net>
parents:
25606
diff
changeset
|
267 <span class="tag">tip</span> |
63be46407a50
hgweb: link to revision by node hash in paper & coal
Anton Shestakov <av6@dwimlabs.net>
parents:
25606
diff
changeset
|
268 </h3> |
12432 | 269 |
270 <form class="search" action="/log"> | |
271 | |
272 <p><input name="rev" id="search1" type="text" size="30" /></p> | |
19796
544848ef65f2
paper: edit search hint to include new feature description
Alexander Plavin <alexander@plav.in>
parents:
19795
diff
changeset
|
273 <div id="hint">Find changesets by keywords (author, files, the commit message), revision |
544848ef65f2
paper: edit search hint to include new feature description
Alexander Plavin <alexander@plav.in>
parents:
19795
diff
changeset
|
274 number or hash, or <a href="/help/revsets">revset expression</a>.</div> |
12432 | 275 </form> |
276 | |
277 <table class="bigtable"> | |
24054
fdf7794be41d
hgweb: replace implicit <tbody> with explicit <thead> where appropriate
Anton Shestakov <engored@ya.ru>
parents:
23952
diff
changeset
|
278 <thead> |
12432 | 279 <tr> |
280 <th class="name">name</th> | |
281 <th class="size">size</th> | |
282 <th class="permissions">permissions</th> | |
283 </tr> | |
24054
fdf7794be41d
hgweb: replace implicit <tbody> with explicit <thead> where appropriate
Anton Shestakov <engored@ya.ru>
parents:
23952
diff
changeset
|
284 </thead> |
19447
182942b38d24
hgweb: make stripes in directory view with CSS
Alexander Plavin <me@aplavin.ru>
parents:
19076
diff
changeset
|
285 <tbody class="stripes2"> |
182942b38d24
hgweb: make stripes in directory view with CSS
Alexander Plavin <me@aplavin.ru>
parents:
19076
diff
changeset
|
286 <tr class="fileline"> |
25606
3bb6f5f478a7
hgweb: don't dereference symbolic revision in paper & coal style (issue2296)
Anton Shestakov <av6@dwimlabs.net>
parents:
25474
diff
changeset
|
287 <td class="name"><a href="/file/tip/">[up]</a></td> |
12432 | 288 <td class="size"></td> |
289 <td class="permissions">drwxr-xr-x</td> | |
290 </tr> | |
291 | |
19447
182942b38d24
hgweb: make stripes in directory view with CSS
Alexander Plavin <me@aplavin.ru>
parents:
19076
diff
changeset
|
292 <tr class="fileline"> |
12432 | 293 <td class="name"> |
25606
3bb6f5f478a7
hgweb: don't dereference symbolic revision in paper & coal style (issue2296)
Anton Shestakov <av6@dwimlabs.net>
parents:
25474
diff
changeset
|
294 <a href="/file/tip/da"> |
12432 | 295 <img src="/static/coal-folder.png" alt="dir."/> da/ |
296 </a> | |
25606
3bb6f5f478a7
hgweb: don't dereference symbolic revision in paper & coal style (issue2296)
Anton Shestakov <av6@dwimlabs.net>
parents:
25474
diff
changeset
|
297 <a href="/file/tip/da/"> |
12432 | 298 |
299 </a> | |
300 </td> | |
301 <td class="size"></td> | |
302 <td class="permissions">drwxr-xr-x</td> | |
303 </tr> | |
304 | |
19447
182942b38d24
hgweb: make stripes in directory view with CSS
Alexander Plavin <me@aplavin.ru>
parents:
19076
diff
changeset
|
305 <tr class="fileline"> |
12432 | 306 <td class="filename"> |
25606
3bb6f5f478a7
hgweb: don't dereference symbolic revision in paper & coal style (issue2296)
Anton Shestakov <av6@dwimlabs.net>
parents:
25474
diff
changeset
|
307 <a href="/file/tip/foo"> |
12432 | 308 <img src="/static/coal-file.png" alt="file"/> foo |
309 </a> | |
310 </td> | |
311 <td class="size">4</td> | |
312 <td class="permissions">-rw-r--r--</td> | |
313 </tr> | |
19447
182942b38d24
hgweb: make stripes in directory view with CSS
Alexander Plavin <me@aplavin.ru>
parents:
19076
diff
changeset
|
314 </tbody> |
12432 | 315 </table> |
316 </div> | |
317 </div> | |
14046
b24e5a708fad
web: Made elapsed time calculation dynamic (javascript).
Benoit Allard <benoit@aeteurope.nl>
parents:
13863
diff
changeset
|
318 <script type="text/javascript">process_dates()</script> |
12432 | 319 |
320 | |
321 </body> | |
322 </html> | |
323 | |
5561
22713dce19f6
hgweb: return meaningful HTTP status codes instead of nonsense
Bryan O'Sullivan <bos@serpentine.com>
parents:
5384
diff
changeset
|
324 |
12432 | 325 stop and restart |
326 | |
25474
8c14f87bd0ae
tests: drop DAEMON_PIDS from killdaemons calls
Matt Mackall <mpm@selenic.com>
parents:
25472
diff
changeset
|
327 $ killdaemons.py |
12432 | 328 $ hg serve -p $HGPORT -d --pid-file=hg.pid -A access.log |
329 $ cat hg.pid >> $DAEMON_PIDS | |
5561
22713dce19f6
hgweb: return meaningful HTTP status codes instead of nonsense
Bryan O'Sullivan <bos@serpentine.com>
parents:
5384
diff
changeset
|
330 |
12432 | 331 Test the access/error files are opened in append mode |
332 | |
22947
c63a09b6b337
tests: use $PYTHON instead of hardcoding python
Augie Fackler <raf@durin42.com>
parents:
22578
diff
changeset
|
333 $ $PYTHON -c "print len(file('access.log').readlines()), 'log lines written'" |
22506
6e1fbcb18a75
hgweb: fail if an invalid command was supplied in url path (issue4071)
Anton Shestakov <engored@ya.ru>
parents:
20256
diff
changeset
|
334 14 log lines written |
12432 | 335 |
336 static file | |
5561
22713dce19f6
hgweb: return meaningful HTTP status codes instead of nonsense
Bryan O'Sullivan <bos@serpentine.com>
parents:
5384
diff
changeset
|
337 |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
24303
diff
changeset
|
338 $ get-with-headers.py --twice localhost:$HGPORT 'static/style-gitweb.css' - date etag server |
12432 | 339 200 Script output follows |
23744
d1933c2e3c8c
templates: use CSS classes for diff styling
Gregory Szorc <gregory.szorc@gmail.com>
parents:
23409
diff
changeset
|
340 content-length: 5372 |
18380
a4d7fd7ad1f7
serve: don't send any content headers with 304 responses
Mads Kiilerich <madski@unity3d.com>
parents:
18264
diff
changeset
|
341 content-type: text/css |
12432 | 342 |
19076
93493746c89a
css: remove repeated property
Alexander Plavin <me@aplavin.ru>
parents:
18380
diff
changeset
|
343 body { font-family: sans-serif; font-size: 12px; border:solid #d9d8d1; border-width:1px; margin:10px; } |
12432 | 344 a { color:#0000cc; } |
345 a:hover, a:visited, a:active { color:#880000; } | |
346 div.page_header { height:25px; padding:8px; font-size:18px; font-weight:bold; background-color:#d9d8d1; } | |
347 div.page_header a:visited { color:#0000cc; } | |
348 div.page_header a:hover { color:#880000; } | |
349 div.page_nav { padding:8px; } | |
350 div.page_nav a:visited { color:#0000cc; } | |
351 div.page_path { padding:8px; border:solid #d9d8d1; border-width:0px 0px 1px} | |
352 div.page_footer { padding:4px 8px; background-color: #d9d8d1; } | |
353 div.page_footer_text { float:left; color:#555555; font-style:italic; } | |
354 div.page_body { padding:8px; } | |
355 div.title, a.title { | |
356 display:block; padding:6px 8px; | |
357 font-weight:bold; background-color:#edece6; text-decoration:none; color:#000000; | |
358 } | |
359 a.title:hover { background-color: #d9d8d1; } | |
360 div.title_text { padding:6px 0px; border: solid #d9d8d1; border-width:0px 0px 1px; } | |
361 div.log_body { padding:8px 8px 8px 150px; } | |
362 .age { white-space:nowrap; } | |
363 span.age { position:relative; float:left; width:142px; font-style:italic; } | |
364 div.log_link { | |
365 padding:0px 8px; | |
366 font-size:10px; font-family:sans-serif; font-style:normal; | |
367 position:relative; float:left; width:136px; | |
368 } | |
369 div.list_head { padding:6px 8px 4px; border:solid #d9d8d1; border-width:1px 0px 0px; font-style:italic; } | |
370 a.list { text-decoration:none; color:#000000; } | |
371 a.list:hover { text-decoration:underline; color:#880000; } | |
372 table { padding:8px 4px; } | |
373 th { padding:2px 5px; font-size:12px; text-align:left; } | |
374 tr.light:hover, .parity0:hover { background-color:#edece6; } | |
375 tr.dark, .parity1 { background-color:#f6f6f0; } | |
376 tr.dark:hover, .parity1:hover { background-color:#edece6; } | |
377 td { padding:2px 5px; font-size:12px; vertical-align:top; } | |
378 td.closed { background-color: #99f; } | |
379 td.link { padding:2px 5px; font-family:sans-serif; font-size:10px; } | |
380 td.indexlinks { white-space: nowrap; } | |
381 td.indexlinks a { | |
382 padding: 2px 5px; line-height: 10px; | |
383 border: 1px solid; | |
384 color: #ffffff; background-color: #7777bb; | |
385 border-color: #aaaadd #333366 #333366 #aaaadd; | |
386 font-weight: bold; text-align: center; text-decoration: none; | |
387 font-size: 10px; | |
388 } | |
389 td.indexlinks a:hover { background-color: #6666aa; } | |
390 div.pre { font-family:monospace; font-size:12px; white-space:pre; } | |
391 div.diff_info { font-family:monospace; color:#000099; background-color:#edece6; font-style:italic; } | |
392 div.index_include { border:solid #d9d8d1; border-width:0px 0px 1px; padding:12px 8px; } | |
393 div.search { margin:4px 8px; position:absolute; top:56px; right:12px } | |
394 .linenr { color:#999999; text-decoration:none } | |
395 div.rss_logo { float: right; white-space: nowrap; } | |
396 div.rss_logo a { | |
397 padding:3px 6px; line-height:10px; | |
398 border:1px solid; border-color:#fcc7a5 #7d3302 #3e1a01 #ff954e; | |
399 color:#ffffff; background-color:#ff6600; | |
400 font-weight:bold; font-family:sans-serif; font-size:10px; | |
401 text-align:center; text-decoration:none; | |
402 } | |
403 div.rss_logo a:hover { background-color:#ee5500; } | |
404 pre { margin: 0; } | |
405 span.logtags span { | |
406 padding: 0px 4px; | |
407 font-size: 10px; | |
408 font-weight: normal; | |
409 border: 1px solid; | |
410 background-color: #ffaaff; | |
411 border-color: #ffccff #ff00ee #ff00ee #ffccff; | |
412 } | |
413 span.logtags span.tagtag { | |
414 background-color: #ffffaa; | |
415 border-color: #ffffcc #ffee00 #ffee00 #ffffcc; | |
416 } | |
417 span.logtags span.branchtag { | |
418 background-color: #aaffaa; | |
419 border-color: #ccffcc #00cc33 #00cc33 #ccffcc; | |
420 } | |
421 span.logtags span.inbranchtag { | |
422 background-color: #d5dde6; | |
423 border-color: #e3ecf4 #9398f4 #9398f4 #e3ecf4; | |
424 } | |
13863
b602ac02f1ba
hgweb: add bookmark labels to gitweb theme (based on 270f57d35525)
Yuya Nishihara <yuya@tcha.org>
parents:
13597
diff
changeset
|
425 span.logtags span.bookmarktag { |
b602ac02f1ba
hgweb: add bookmark labels to gitweb theme (based on 270f57d35525)
Yuya Nishihara <yuya@tcha.org>
parents:
13597
diff
changeset
|
426 background-color: #afdffa; |
b602ac02f1ba
hgweb: add bookmark labels to gitweb theme (based on 270f57d35525)
Yuya Nishihara <yuya@tcha.org>
parents:
13597
diff
changeset
|
427 border-color: #ccecff #46ace6 #46ace6 #ccecff; |
b602ac02f1ba
hgweb: add bookmark labels to gitweb theme (based on 270f57d35525)
Yuya Nishihara <yuya@tcha.org>
parents:
13597
diff
changeset
|
428 } |
23744
d1933c2e3c8c
templates: use CSS classes for diff styling
Gregory Szorc <gregory.szorc@gmail.com>
parents:
23409
diff
changeset
|
429 span.difflineplus { color:#008800; } |
d1933c2e3c8c
templates: use CSS classes for diff styling
Gregory Szorc <gregory.szorc@gmail.com>
parents:
23409
diff
changeset
|
430 span.difflineminus { color:#cc0000; } |
d1933c2e3c8c
templates: use CSS classes for diff styling
Gregory Szorc <gregory.szorc@gmail.com>
parents:
23409
diff
changeset
|
431 span.difflineat { color:#990099; } |
12432 | 432 |
433 /* Graph */ | |
434 div#wrapper { | |
435 position: relative; | |
436 margin: 0; | |
437 padding: 0; | |
438 margin-top: 3px; | |
439 } | |
440 | |
441 canvas { | |
442 position: absolute; | |
443 z-index: 5; | |
444 top: -0.9em; | |
445 margin: 0; | |
446 } | |
447 | |
448 ul#nodebgs { | |
449 list-style: none inside none; | |
450 padding: 0; | |
451 margin: 0; | |
452 top: -0.7em; | |
453 } | |
454 | |
455 ul#graphnodes li, ul#nodebgs li { | |
456 height: 39px; | |
457 } | |
458 | |
459 ul#graphnodes { | |
460 position: absolute; | |
461 z-index: 10; | |
462 top: -0.8em; | |
463 list-style: none inside none; | |
464 padding: 0; | |
465 } | |
466 | |
467 ul#graphnodes li .info { | |
468 display: block; | |
469 font-size: 100%; | |
470 position: relative; | |
471 top: -3px; | |
472 font-style: italic; | |
473 } | |
17202
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
474 |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
475 /* Comparison */ |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
476 .legend { |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
477 padding: 1.5% 0 1.5% 0; |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
478 } |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
479 |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
480 .legendinfo { |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
481 border: 1px solid #d9d8d1; |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
482 font-size: 80%; |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
483 text-align: center; |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
484 padding: 0.5%; |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
485 } |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
486 |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
487 .equal { |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
488 background-color: #ffffff; |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
489 } |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
490 |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
491 .delete { |
17243
106cdea0183d
hgweb: improve colors for comparison page
Matt Mackall <mpm@selenic.com>
parents:
17202
diff
changeset
|
492 background-color: #faa; |
106cdea0183d
hgweb: improve colors for comparison page
Matt Mackall <mpm@selenic.com>
parents:
17202
diff
changeset
|
493 color: #333; |
17202
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
494 } |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
495 |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
496 .insert { |
17243
106cdea0183d
hgweb: improve colors for comparison page
Matt Mackall <mpm@selenic.com>
parents:
17202
diff
changeset
|
497 background-color: #ffa; |
17202
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
498 } |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
499 |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
500 .replace { |
17243
106cdea0183d
hgweb: improve colors for comparison page
Matt Mackall <mpm@selenic.com>
parents:
17202
diff
changeset
|
501 background-color: #e8e8e8; |
17202
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
502 } |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
503 |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
504 .comparison { |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
505 overflow-x: auto; |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
506 } |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
507 |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
508 .header th { |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
509 text-align: center; |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
510 } |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
511 |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
512 .block { |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
513 border-top: 1px solid #d9d8d1; |
1ae119269ddc
hgweb: side-by-side comparison functionality
wujek srujek
parents:
17017
diff
changeset
|
514 } |
20256
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
515 |
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
516 .scroll-loading { |
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
517 -webkit-animation: change_color 1s linear 0s infinite alternate; |
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
518 -moz-animation: change_color 1s linear 0s infinite alternate; |
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
519 -o-animation: change_color 1s linear 0s infinite alternate; |
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
520 animation: change_color 1s linear 0s infinite alternate; |
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
521 } |
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
522 |
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
523 @-webkit-keyframes change_color { |
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
524 from { background-color: #A0CEFF; } to { } |
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
525 } |
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
526 @-moz-keyframes change_color { |
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
527 from { background-color: #A0CEFF; } to { } |
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
528 } |
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
529 @-o-keyframes change_color { |
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
530 from { background-color: #A0CEFF; } to { } |
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
531 } |
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
532 @keyframes change_color { |
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
533 from { background-color: #A0CEFF; } to { } |
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
534 } |
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
535 |
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
536 .scroll-loading-error { |
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
537 background-color: #FFCCCC !important; |
b786754ba604
test-hgweb-*: output change fixes from b1d65cb8
Augie Fackler <raf@durin42.com>
parents:
19796
diff
changeset
|
538 } |
12432 | 539 304 Not Modified |
540 | |
9842
d3dbdca92458
hgweb: don't choke when an inexistent style is requested (issue1901)
Dirkjan Ochtman <dirkjan@ochtman.nl>
parents:
8167
diff
changeset
|
541 |
22577
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
542 phase changes are refreshed (issue4061) |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
543 |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
544 $ echo bar >> foo |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
545 $ hg ci -msecret --secret |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
24303
diff
changeset
|
546 $ get-with-headers.py localhost:$HGPORT 'log?style=raw' |
22577
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
547 200 Script output follows |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
548 |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
549 |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
550 # HG changelog |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
551 # Node ID 2ef0ac749a14e4f57a5a822464a0902c6f7f448f |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
552 |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
553 changeset: 2ef0ac749a14e4f57a5a822464a0902c6f7f448f |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
554 revision: 0 |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
555 user: test |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
556 date: Thu, 01 Jan 1970 00:00:00 +0000 |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
557 summary: base |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
558 branch: default |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
559 tag: tip |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
560 |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
561 |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
562 $ hg phase --draft tip |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
24303
diff
changeset
|
563 $ get-with-headers.py localhost:$HGPORT 'log?style=raw' |
22577
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
564 200 Script output follows |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
565 |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
566 |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
567 # HG changelog |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
568 # Node ID a084749e708a9c4c0a5b652a2a446322ce290e04 |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
569 |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
570 changeset: a084749e708a9c4c0a5b652a2a446322ce290e04 |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
571 revision: 1 |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
572 user: test |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
573 date: Thu, 01 Jan 1970 00:00:00 +0000 |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
574 summary: secret |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
575 branch: default |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
576 tag: tip |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
577 |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
578 changeset: 2ef0ac749a14e4f57a5a822464a0902c6f7f448f |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
579 revision: 0 |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
580 user: test |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
581 date: Thu, 01 Jan 1970 00:00:00 +0000 |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
582 summary: base |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
583 |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
584 |
a111e460318a
hgweb: refresh hgweb.repo on phase change (issue4061)
Anton Shestakov <engored@ya.ru>
parents:
22506
diff
changeset
|
585 |
24296
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
586 no style can be loaded from directories other than the specified paths |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
587 |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
588 $ mkdir -p x/templates/fallback |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
589 $ cat <<EOF > x/templates/fallback/map |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
590 > default = 'shortlog' |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
591 > shortlog = 'fall back to default\n' |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
592 > mimetype = 'text/plain' |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
593 > EOF |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
594 $ cat <<EOF > x/map |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
595 > default = 'shortlog' |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
596 > shortlog = 'access to outside of templates directory\n' |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
597 > mimetype = 'text/plain' |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
598 > EOF |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
599 |
25474
8c14f87bd0ae
tests: drop DAEMON_PIDS from killdaemons calls
Matt Mackall <mpm@selenic.com>
parents:
25472
diff
changeset
|
600 $ killdaemons.py |
24296
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
601 $ hg serve -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log \ |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
602 > --config web.style=fallback --config web.templates=x/templates |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
603 $ cat hg.pid >> $DAEMON_PIDS |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
604 |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
24303
diff
changeset
|
605 $ get-with-headers.py localhost:$HGPORT "?style=`pwd`/x" |
24296
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
606 200 Script output follows |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
607 |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
608 fall back to default |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
609 |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
24303
diff
changeset
|
610 $ get-with-headers.py localhost:$HGPORT '?style=..' |
24296
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
611 200 Script output follows |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
612 |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
613 fall back to default |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
614 |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
24303
diff
changeset
|
615 $ get-with-headers.py localhost:$HGPORT '?style=./..' |
24296
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
616 200 Script output follows |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
617 |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
618 fall back to default |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
619 |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
24303
diff
changeset
|
620 $ get-with-headers.py localhost:$HGPORT '?style=.../.../' |
24296
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
621 200 Script output follows |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
622 |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
623 fall back to default |
b73a22d1d9bf
hgweb: prevent loading style map from directories other than specified paths
Yuya Nishihara <yuya@tcha.org>
parents:
23952
diff
changeset
|
624 |
12432 | 625 errors |
5690
1b365c5723bc
server: append to logfiles
Mirko Friedenhagen <mirko-lists@friedenhagen.de>
parents:
5580
diff
changeset
|
626 |
12432 | 627 $ cat errors.log |
16913
f2719b387380
tests: add missing trailing 'cd ..'
Mads Kiilerich <mads@kiilerich.com>
parents:
15446
diff
changeset
|
628 |
23409
dc4d2cd3aa3e
hgweb: send proper HTTP response after uncaught exception
Gregory Szorc <gregory.szorc@gmail.com>
parents:
22947
diff
changeset
|
629 Uncaught exceptions result in a logged error and canned HTTP response |
dc4d2cd3aa3e
hgweb: send proper HTTP response after uncaught exception
Gregory Szorc <gregory.szorc@gmail.com>
parents:
22947
diff
changeset
|
630 |
25474
8c14f87bd0ae
tests: drop DAEMON_PIDS from killdaemons calls
Matt Mackall <mpm@selenic.com>
parents:
25472
diff
changeset
|
631 $ killdaemons.py |
23409
dc4d2cd3aa3e
hgweb: send proper HTTP response after uncaught exception
Gregory Szorc <gregory.szorc@gmail.com>
parents:
22947
diff
changeset
|
632 $ hg --config extensions.hgweberror=$TESTDIR/hgweberror.py serve -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log |
dc4d2cd3aa3e
hgweb: send proper HTTP response after uncaught exception
Gregory Szorc <gregory.szorc@gmail.com>
parents:
22947
diff
changeset
|
633 $ cat hg.pid >> $DAEMON_PIDS |
dc4d2cd3aa3e
hgweb: send proper HTTP response after uncaught exception
Gregory Szorc <gregory.szorc@gmail.com>
parents:
22947
diff
changeset
|
634 |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
24303
diff
changeset
|
635 $ get-with-headers.py localhost:$HGPORT 'raiseerror' transfer-encoding content-type |
23409
dc4d2cd3aa3e
hgweb: send proper HTTP response after uncaught exception
Gregory Szorc <gregory.szorc@gmail.com>
parents:
22947
diff
changeset
|
636 500 Internal Server Error |
dc4d2cd3aa3e
hgweb: send proper HTTP response after uncaught exception
Gregory Szorc <gregory.szorc@gmail.com>
parents:
22947
diff
changeset
|
637 transfer-encoding: chunked |
dc4d2cd3aa3e
hgweb: send proper HTTP response after uncaught exception
Gregory Szorc <gregory.szorc@gmail.com>
parents:
22947
diff
changeset
|
638 |
dc4d2cd3aa3e
hgweb: send proper HTTP response after uncaught exception
Gregory Szorc <gregory.szorc@gmail.com>
parents:
22947
diff
changeset
|
639 Internal Server Error (no-eol) |
dc4d2cd3aa3e
hgweb: send proper HTTP response after uncaught exception
Gregory Szorc <gregory.szorc@gmail.com>
parents:
22947
diff
changeset
|
640 [1] |
dc4d2cd3aa3e
hgweb: send proper HTTP response after uncaught exception
Gregory Szorc <gregory.szorc@gmail.com>
parents:
22947
diff
changeset
|
641 |
25474
8c14f87bd0ae
tests: drop DAEMON_PIDS from killdaemons calls
Matt Mackall <mpm@selenic.com>
parents:
25472
diff
changeset
|
642 $ killdaemons.py |
23409
dc4d2cd3aa3e
hgweb: send proper HTTP response after uncaught exception
Gregory Szorc <gregory.szorc@gmail.com>
parents:
22947
diff
changeset
|
643 $ head -1 errors.log |
dc4d2cd3aa3e
hgweb: send proper HTTP response after uncaught exception
Gregory Szorc <gregory.szorc@gmail.com>
parents:
22947
diff
changeset
|
644 .* Exception happened during processing request '/raiseerror': (re) |
dc4d2cd3aa3e
hgweb: send proper HTTP response after uncaught exception
Gregory Szorc <gregory.szorc@gmail.com>
parents:
22947
diff
changeset
|
645 |
dc4d2cd3aa3e
hgweb: send proper HTTP response after uncaught exception
Gregory Szorc <gregory.szorc@gmail.com>
parents:
22947
diff
changeset
|
646 Uncaught exception after partial content sent |
dc4d2cd3aa3e
hgweb: send proper HTTP response after uncaught exception
Gregory Szorc <gregory.szorc@gmail.com>
parents:
22947
diff
changeset
|
647 |
23952
ea61e278ae92
test-hgweb: fix shutdown race
Matt Mackall <mpm@selenic.com>
parents:
23744
diff
changeset
|
648 $ hg --config extensions.hgweberror=$TESTDIR/hgweberror.py serve -p $HGPORT -d --pid-file=hg.pid -A access.log -E errors.log |
ea61e278ae92
test-hgweb: fix shutdown race
Matt Mackall <mpm@selenic.com>
parents:
23744
diff
changeset
|
649 $ cat hg.pid >> $DAEMON_PIDS |
25472
4d2b9b304ad0
tests: drop explicit $TESTDIR from executables
Matt Mackall <mpm@selenic.com>
parents:
24303
diff
changeset
|
650 $ get-with-headers.py localhost:$HGPORT 'raiseerror?partialresponse=1' transfer-encoding content-type |
23409
dc4d2cd3aa3e
hgweb: send proper HTTP response after uncaught exception
Gregory Szorc <gregory.szorc@gmail.com>
parents:
22947
diff
changeset
|
651 200 Script output follows |
dc4d2cd3aa3e
hgweb: send proper HTTP response after uncaught exception
Gregory Szorc <gregory.szorc@gmail.com>
parents:
22947
diff
changeset
|
652 transfer-encoding: chunked |
dc4d2cd3aa3e
hgweb: send proper HTTP response after uncaught exception
Gregory Szorc <gregory.szorc@gmail.com>
parents:
22947
diff
changeset
|
653 content-type: text/plain |
dc4d2cd3aa3e
hgweb: send proper HTTP response after uncaught exception
Gregory Szorc <gregory.szorc@gmail.com>
parents:
22947
diff
changeset
|
654 |
dc4d2cd3aa3e
hgweb: send proper HTTP response after uncaught exception
Gregory Szorc <gregory.szorc@gmail.com>
parents:
22947
diff
changeset
|
655 partial content |
dc4d2cd3aa3e
hgweb: send proper HTTP response after uncaught exception
Gregory Szorc <gregory.szorc@gmail.com>
parents:
22947
diff
changeset
|
656 Internal Server Error (no-eol) |
dc4d2cd3aa3e
hgweb: send proper HTTP response after uncaught exception
Gregory Szorc <gregory.szorc@gmail.com>
parents:
22947
diff
changeset
|
657 |
25474
8c14f87bd0ae
tests: drop DAEMON_PIDS from killdaemons calls
Matt Mackall <mpm@selenic.com>
parents:
25472
diff
changeset
|
658 $ killdaemons.py |
16913
f2719b387380
tests: add missing trailing 'cd ..'
Mads Kiilerich <mads@kiilerich.com>
parents:
15446
diff
changeset
|
659 $ cd .. |