on master help sign in
Remove warp-static (now in its own package)
commitf88c0506b62ea008e34183268b8c097902613fbd authorMichael Snoyman <michael@snoyman.com> dateThu 27 Jan 2011, 19:19 (16 years ago) parent601e1c6
4 files changed+431−28
Network/Wai/Application/Static.hs+7−2 folder.svg+424 wai-app-static.cabal−5 warp-static.hs−21
Network/Wai/Application/Static.hs+7−2
@@ -233,6 +233,11 @@ data StaticSettings = StaticSettings
233233 }
234234
235235staticApp :: StaticSettings -> W.Application
236+staticApp _ req
237+ | W.requestMethod req /= "GET" = return $ W.responseLBS
238+ W.status405
239+ [("Content-Type", "text/plain")]
240+ "Only GET is supported"
236241staticApp (StaticSettings folder indices mlisting getmime) req = liftIO $ do
237242 let pieces = decodePathInfo $ S8.unpack $ W.pathInfo req
238243 cp <- checkPieces folder indices pieces
@@ -293,7 +298,7 @@ defaultListing pieces localPath = do
293298 , "tr { background-color: white; }"
294299 , "tr.alt { background-color: #A3B5BA}"
295300 , "th { background-color: #3C4569; color: white; font-size: 1.125em; }"
296− , "h1 { width: 760px; margin: 1em auto; font-size: 1em }"
301+ , "h1 { width: 760px; margin: 1em auto; font-size: 1em; font-family: sans-serif }"
297302 , "img { width: 20px }"
298303 , "a { text-decoration: none }"
299304 ]
@@ -306,7 +311,7 @@ defaultListing pieces localPath = do
306311 haskellSrc = image "haskell"
307312 showName "" = "root"
308313 showName x = x
309− showFolder [] = H.string "FIXME: Unexpected showFolder []"
314+ showFolder [] = H.string "error: Unexpected showFolder []"
310315 showFolder [x] = H.string $ showName x
311316 showFolder (x:xs) = do
312317 let href = concat $ replicate (length xs) "../"
folder.svgnew file+424
@@ -0,0 +1,424 @@
1+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
2+<!-- Created with Inkscape (http://www.inkscape.org/) -->
3+<svg
4+ xmlns:dc="http://purl.org/dc/elements/1.1/"
5+ xmlns:cc="http://creativecommons.org/ns#"
6+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
7+ xmlns:svg="http://www.w3.org/2000/svg"
8+ xmlns="http://www.w3.org/2000/svg"
9+ xmlns:xlink="http://www.w3.org/1999/xlink"
10+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
11+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
12+ width="48.000000px"
13+ height="48.000000px"
14+ id="svg97"
15+ sodipodi:version="0.32"
16+ inkscape:version="0.46"
17+ sodipodi:docbase="/home/jimmac/src/cvs/tango-icon-theme/scalable/places"
18+ sodipodi:docname="folder.svg"
19+ inkscape:export-filename="/home/jimmac/Desktop/horlander-style3.png"
20+ inkscape:export-xdpi="90.000000"
21+ inkscape:export-ydpi="90.000000"
22+ inkscape:output_extension="org.inkscape.output.svg.inkscape">
23+ <defs
24+ id="defs3">
25+ <inkscape:perspective
26+ sodipodi:type="inkscape:persp3d"
27+ inkscape:vp_x="0 : 24 : 1"
28+ inkscape:vp_y="0 : 1000 : 0"
29+ inkscape:vp_z="48 : 24 : 1"
30+ inkscape:persp3d-origin="24 : 16 : 1"
31+ id="perspective68" />
32+ <radialGradient
33+ inkscape:collect="always"
34+ xlink:href="#linearGradient5060"
35+ id="radialGradient6719"
36+ gradientUnits="userSpaceOnUse"
37+ gradientTransform="matrix(-2.774389,0,0,1.969706,112.7623,-872.8854)"
38+ cx="605.71429"
39+ cy="486.64789"
40+ fx="605.71429"
41+ fy="486.64789"
42+ r="117.14286" />
43+ <linearGradient
44+ inkscape:collect="always"
45+ id="linearGradient5060">
46+ <stop
47+ style="stop-color:black;stop-opacity:1;"
48+ offset="0"
49+ id="stop5062" />
50+ <stop
51+ style="stop-color:black;stop-opacity:0;"
52+ offset="1"
53+ id="stop5064" />
54+ </linearGradient>
55+ <radialGradient
56+ inkscape:collect="always"
57+ xlink:href="#linearGradient5060"
58+ id="radialGradient6717"
59+ gradientUnits="userSpaceOnUse"
60+ gradientTransform="matrix(2.774389,0,0,1.969706,-1891.633,-872.8854)"
61+ cx="605.71429"
62+ cy="486.64789"
63+ fx="605.71429"
64+ fy="486.64789"
65+ r="117.14286" />
66+ <linearGradient
67+ id="linearGradient5048">
68+ <stop
69+ style="stop-color:black;stop-opacity:0;"
70+ offset="0"
71+ id="stop5050" />
72+ <stop
73+ id="stop5056"
74+ offset="0.5"
75+ style="stop-color:black;stop-opacity:1;" />
76+ <stop
77+ style="stop-color:black;stop-opacity:0;"
78+ offset="1"
79+ id="stop5052" />
80+ </linearGradient>
81+ <linearGradient
82+ inkscape:collect="always"
83+ xlink:href="#linearGradient5048"
84+ id="linearGradient6715"
85+ gradientUnits="userSpaceOnUse"
86+ gradientTransform="matrix(2.774389,0,0,1.969706,-1892.179,-872.8854)"
87+ x1="302.85715"
88+ y1="366.64789"
89+ x2="302.85715"
90+ y2="609.50507" />
91+ <linearGradient
92+ inkscape:collect="always"
93+ id="linearGradient9806">
94+ <stop
95+ style="stop-color:#000000;stop-opacity:1;"
96+ offset="0"
97+ id="stop9808" />
98+ <stop
99+ style="stop-color:#000000;stop-opacity:0;"
100+ offset="1"
101+ id="stop9810" />
102+ </linearGradient>
103+ <linearGradient
104+ id="linearGradient9766">
105+ <stop
106+ style="stop-color:#6194cb;stop-opacity:1;"
107+ offset="0"
108+ id="stop9768" />
109+ <stop
110+ style="stop-color:#729fcf;stop-opacity:1;"
111+ offset="1"
112+ id="stop9770" />
113+ </linearGradient>
114+ <linearGradient
115+ id="linearGradient3096">
116+ <stop
117+ id="stop3098"
118+ offset="0"
119+ style="stop-color:#424242;stop-opacity:1;" />
120+ <stop
121+ id="stop3100"
122+ offset="1.0000000"
123+ style="stop-color:#777777;stop-opacity:1.0000000;" />
124+ </linearGradient>
125+ <linearGradient
126+ id="linearGradient319"
127+ inkscape:collect="always">
128+ <stop
129+ id="stop320"
130+ offset="0"
131+ style="stop-color:#ffffff;stop-opacity:1;" />
132+ <stop
133+ id="stop321"
134+ offset="1"
135+ style="stop-color:#ffffff;stop-opacity:0;" />
136+ </linearGradient>
137+ <linearGradient
138+ id="linearGradient1789">
139+ <stop
140+ style="stop-color:#202020;stop-opacity:1.0000000;"
141+ offset="0.0000000"
142+ id="stop1790" />
143+ <stop
144+ style="stop-color:#b9b9b9;stop-opacity:1.0000000;"
145+ offset="1.0000000"
146+ id="stop1791" />
147+ </linearGradient>
148+ <radialGradient
149+ inkscape:collect="always"
150+ xlink:href="#linearGradient1789"
151+ id="radialGradient238"
152+ gradientUnits="userSpaceOnUse"
153+ gradientTransform="matrix(1.055022,-2.734504e-2,0.177703,1.190929,-3.572177,-7.125301)"
154+ cx="20.706017"
155+ cy="37.517986"
156+ fx="20.706017"
157+ fy="37.517986"
158+ r="30.905205" />
159+ <linearGradient
160+ id="linearGradient3983">
161+ <stop
162+ style="stop-color:#ffffff;stop-opacity:0.87628865;"
163+ offset="0.0000000"
164+ id="stop3984" />
165+ <stop
166+ style="stop-color:#fffffe;stop-opacity:0.0000000;"
167+ offset="1.0000000"
168+ id="stop3985" />
169+ </linearGradient>
170+ <linearGradient
171+ inkscape:collect="always"
172+ xlink:href="#linearGradient3983"
173+ id="linearGradient491"
174+ gradientUnits="userSpaceOnUse"
175+ gradientTransform="matrix(1.516844,0.000000,0.000000,0.708978,-0.879573,-1.318166)"
176+ x1="6.2297964"
177+ y1="13.773066"
178+ x2="9.8980894"
179+ y2="66.834053" />
180+ <linearGradient
181+ gradientUnits="userSpaceOnUse"
182+ y2="46.689312"
183+ x2="12.853771"
184+ y1="32.567184"
185+ x1="13.035696"
186+ gradientTransform="matrix(1.317489,0.000000,0.000000,0.816256,-0.879573,-1.318166)"
187+ id="linearGradient322"
188+ xlink:href="#linearGradient319"
189+ inkscape:collect="always" />
190+ <linearGradient
191+ gradientUnits="userSpaceOnUse"
192+ y2="6.1802502"
193+ x2="15.514889"
194+ y1="31.367750"
195+ x1="18.112709"
196+ id="linearGradient3104"
197+ xlink:href="#linearGradient3096"
198+ inkscape:collect="always" />
199+ <linearGradient
200+ inkscape:collect="always"
201+ xlink:href="#linearGradient9766"
202+ id="linearGradient9772"
203+ x1="22.175976"
204+ y1="36.987999"
205+ x2="22.065331"
206+ y2="32.050499"
207+ gradientUnits="userSpaceOnUse" />
208+ <radialGradient
209+ inkscape:collect="always"
210+ xlink:href="#linearGradient9806"
211+ id="radialGradient9812"
212+ cx="24.35099"
213+ cy="41.591846"
214+ fx="24.35099"
215+ fy="41.591846"
216+ r="19.136078"
217+ gradientTransform="matrix(1.000000,0.000000,0.000000,0.242494,1.565588e-16,31.50606)"
218+ gradientUnits="userSpaceOnUse" />
219+ </defs>
220+ <sodipodi:namedview
221+ fill="#729fcf"
222+ id="base"
223+ pagecolor="#ffffff"
224+ bordercolor="#666666"
225+ borderopacity="0.10196078"
226+ inkscape:pageopacity="0.0"
227+ inkscape:pageshadow="2"
228+ inkscape:zoom="4"
229+ inkscape:cx="54.359127"
230+ inkscape:cy="-13.803699"
231+ inkscape:current-layer="layer1"
232+ showgrid="false"
233+ inkscape:grid-bbox="true"
234+ inkscape:document-units="px"
235+ inkscape:window-width="1026"
236+ inkscape:window-height="818"
237+ inkscape:window-x="169"
238+ inkscape:window-y="30"
239+ inkscape:showpageshadow="false"
240+ stroke="#3465a4" />
241+ <metadata
242+ id="metadata4">
243+ <rdf:RDF>
244+ <cc:Work
245+ rdf:about="">
246+ <dc:format>image/svg+xml</dc:format>
247+ <dc:type
248+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
249+ <dc:title>Folder Icon</dc:title>
250+ <dc:date />
251+ <dc:creator>
252+ <cc:Agent>
253+ <dc:title>Jakub Steiner</dc:title>
254+ </cc:Agent>
255+ </dc:creator>
256+ <cc:license
257+ rdf:resource="http://creativecommons.org/licenses/publicdomain/" />
258+ <dc:source>http://jimmac.musichall.cz</dc:source>
259+ <dc:subject>
260+ <rdf:Bag>
261+ <rdf:li>folder</rdf:li>
262+ <rdf:li>directory</rdf:li>
263+ </rdf:Bag>
264+ </dc:subject>
265+ </cc:Work>
266+ <cc:License
267+ rdf:about="http://creativecommons.org/licenses/publicdomain/">
268+ <cc:permits
269+ rdf:resource="http://creativecommons.org/ns#Reproduction" />
270+ <cc:permits
271+ rdf:resource="http://creativecommons.org/ns#Distribution" />
272+ <cc:permits
273+ rdf:resource="http://creativecommons.org/ns#DerivativeWorks" />
274+ </cc:License>
275+ </rdf:RDF>
276+ </metadata>
277+ <g
278+ id="layer1"
279+ inkscape:label="Folder"
280+ inkscape:groupmode="layer">
281+ <g
282+ style="display:inline"
283+ transform="matrix(2.262383e-2,0,0,2.086758e-2,43.38343,36.36962)"
284+ id="g6707">
285+ <rect
286+ style="opacity:0.40206185;color:black;fill:url(#linearGradient6715);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1;stroke-linecap:round;stroke-linejoin:miter;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible"
287+ id="rect6709"
288+ width="1339.6335"
289+ height="478.35718"
290+ x="-1559.2523"
291+ y="-150.69685" />
292+ <path
293+ style="opacity:0.40206185;color:black;fill:url(#radialGradient6717);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1;stroke-linecap:round;stroke-linejoin:miter;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible"
294+ d="M -219.61876,-150.68038 C -219.61876,-150.68038 -219.61876,327.65041 -219.61876,327.65041 C -76.744594,328.55086 125.78146,220.48075 125.78138,88.454235 C 125.78138,-43.572302 -33.655436,-150.68036 -219.61876,-150.68038 z "
295+ id="path6711"
296+ sodipodi:nodetypes="cccc" />
297+ <path
298+ sodipodi:nodetypes="cccc"
299+ id="path6713"
300+ d="M -1559.2523,-150.68038 C -1559.2523,-150.68038 -1559.2523,327.65041 -1559.2523,327.65041 C -1702.1265,328.55086 -1904.6525,220.48075 -1904.6525,88.454235 C -1904.6525,-43.572302 -1745.2157,-150.68036 -1559.2523,-150.68038 z "
301+ style="opacity:0.40206185;color:black;fill:url(#radialGradient6719);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1;stroke-linecap:round;stroke-linejoin:miter;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible" />
302+ </g>
303+ <path
304+ d="M 4.5217805,38.687417 C 4.5435766,39.103721 4.9816854,39.520026 5.3979900,39.520026 L 36.725011,39.520026 C 37.141313,39.520026 37.535823,39.103721 37.514027,38.687417 L 36.577584,11.460682 C 36.555788,11.044379 36.117687,10.628066 35.701383,10.628066 L 22.430510,10.628066 C 21.945453,10.628066 21.196037,10.312477 21.028866,9.5214338 L 20.417475,6.6283628 C 20.262006,5.8926895 19.535261,5.5904766 19.118957,5.5904766 L 4.3400975,5.5904766 C 3.9237847,5.5904766 3.5292767,6.0067807 3.5510726,6.4230849 L 4.5217805,38.687417 z "
305+ id="path216"
306+ style="fill:url(#radialGradient238);fill-opacity:1.0000000;fill-rule:nonzero;stroke:url(#linearGradient3104);stroke-width:1.0000000;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4.0000000;stroke-dasharray:none;stroke-opacity:1.0000000"
307+ sodipodi:nodetypes="ccccccssssccc" />
308+ <path
309+ sodipodi:nodetypes="cc"
310+ id="path9788"
311+ d="M 5.2265927,22.5625 L 35.492173,22.5625"
312+ style="opacity:0.11363633;color:#000000;fill:#729fcf;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:1.00000024;stroke-linecap:round;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible" />
313+ <path
314+ sodipodi:nodetypes="cc"
315+ id="path9784"
316+ d="M 5.0421736,18.5625 L 35.489104,18.5625"
317+ style="opacity:0.11363633;color:#000000;fill:#729fcf;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:1.00000036;stroke-linecap:round;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible" />
318+ <path
319+ style="opacity:0.11363633;color:#000000;fill:#729fcf;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:1;stroke-linecap:round;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible"
320+ d="M 4.9806965,12.5625 L 35.488057,12.5625"
321+ id="path9778"
322+ sodipodi:nodetypes="cc" />
323+ <path
324+ style="opacity:0.11363633;color:#000000;fill:#729fcf;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:1.00000036;stroke-linecap:round;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible"
325+ d="M 5.3861577,32.5625 L 35.494881,32.5625"
326+ id="path9798"
327+ sodipodi:nodetypes="cc" />
328+ <path
329+ sodipodi:nodetypes="cc"
330+ id="path9800"
331+ d="M 5.5091398,34.5625 L 35.496893,34.5625"
332+ style="opacity:0.11363633;color:#000000;fill:#729fcf;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:1.00000024;stroke-linecap:round;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible" />
333+ <path
334+ style="opacity:0.11363633;color:#000000;fill:#729fcf;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:1.00000036;stroke-linecap:round;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible"
335+ d="M 5.0421736,16.5625 L 35.489104,16.5625"
336+ id="path9782"
337+ sodipodi:nodetypes="cc" />
338+ <path
339+ sodipodi:nodetypes="cc"
340+ id="path9780"
341+ d="M 5.0114345,14.5625 L 35.48858,14.5625"
342+ style="opacity:0.11363633;color:#000000;fill:#729fcf;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:1.00000024;stroke-linecap:round;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible" />
343+ <path
344+ sodipodi:nodetypes="cc"
345+ id="path9776"
346+ d="M 4.9220969,10.5625 L 20.202912,10.5625"
347+ style="opacity:0.11363633;color:#000000;fill:#729fcf;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:1.00000024;stroke-linecap:round;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible" />
348+ <path
349+ style="opacity:0.11363633;color:#000000;fill:#729fcf;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:0.99999982;stroke-linecap:round;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible"
350+ d="M 4.8737534,8.5624999 L 19.657487,8.5624999"
351+ id="path9774"
352+ sodipodi:nodetypes="cc" />
353+ <path
354+ style="opacity:0.11363633;color:#000000;fill:#729fcf;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:1.00000036;stroke-linecap:round;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible"
355+ d="M 5.3246666,28.5625 L 35.493876,28.5625"
356+ id="path9794"
357+ sodipodi:nodetypes="cc" />
358+ <path
359+ sodipodi:nodetypes="cc"
360+ id="path9792"
361+ d="M 5.2880638,26.5625 L 35.493184,26.5625"
362+ style="opacity:0.11363633;color:#000000;fill:#729fcf;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:1;stroke-linecap:round;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible" />
363+ <path
364+ style="opacity:0.11363633;color:#000000;fill:#729fcf;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:1.00000024;stroke-linecap:round;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible"
365+ d="M 5.2265927,24.5625 L 35.492173,24.5625"
366+ id="path9790"
367+ sodipodi:nodetypes="cc" />
368+ <path
369+ style="opacity:0.11363633;color:#000000;fill:#729fcf;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:1.00000012;stroke-linecap:round;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible"
370+ d="M 5.1958537,20.5625 L 35.491649,20.5625"
371+ id="path9786"
372+ sodipodi:nodetypes="cc" />
373+ <path
374+ sodipodi:nodetypes="cc"
375+ id="path9796"
376+ d="M 5.3246666,30.5625 L 35.493876,30.5625"
377+ style="opacity:0.11363633;color:#000000;fill:#729fcf;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:1.00000036;stroke-linecap:round;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible" />
378+ <path
379+ style="opacity:0.11363633;color:#000000;fill:#729fcf;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:1.00000024;stroke-linecap:round;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible"
380+ d="M 5.5091398,36.5625 L 35.496893,36.5625"
381+ id="path9802"
382+ sodipodi:nodetypes="cc" />
383+ <path
384+ style="color:#000000;fill:url(#linearGradient491);fill-opacity:1.0000000;fill-rule:nonzero;stroke:none;stroke-width:1.2138050;stroke-linecap:butt;stroke-linejoin:miter;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4.0000000;stroke-dashoffset:0.0000000;stroke-opacity:1.0000000;visibility:visible;display:block;overflow:visible;opacity:0.45142857"
385+ d="M 6.0683430,38.864023 C 6.0846856,39.176251 5.8874317,39.384402 5.5697582,39.280326 L 5.5697582,39.280326 C 5.2520766,39.176251 5.0330270,38.968099 5.0166756,38.655870 L 4.0689560,6.5913839 C 4.0526131,6.2791558 4.2341418,6.0906134 4.5463699,6.0906134 L 18.968420,6.0429196 C 19.280648,6.0429196 19.900363,6.3433923 20.101356,7.3651014 L 20.674845,10.180636 C 20.247791,9.7153790 20.255652,9.7010175 20.037287,9.0239299 L 19.631192,7.7647478 C 19.412142,7.0371009 18.932991,6.9328477 18.620763,6.9328477 L 5.7329889,6.9328477 C 5.4207613,6.9328477 5.2235075,7.1409999 5.2398583,7.4532364 L 6.1778636,38.968099 L 6.0683430,38.864023 z "
386+ id="path219"
387+ sodipodi:nodetypes="cccccccccscccccc" />
388+ <g
389+ style="stroke-miterlimit:4.0000000;stroke-width:0.99946535;stroke:none;fill-rule:nonzero;fill-opacity:0.75706214;fill:#ffffff"
390+ id="g220"
391+ transform="matrix(1.040764,0.000000,5.449252e-2,1.040764,-8.670199,2.670594)"
392+ inkscape:export-filename="/home/jimmac/ximian_art/icons/nautilus/suse93/gnome-fs-directory.png"
393+ inkscape:export-xdpi="74.800003"
394+ inkscape:export-ydpi="74.800003">
395+ <path
396+ style="fill-opacity:0.50847459;fill:#ffffff"
397+ d="M 42.417183,8.5151772 C 42.422267,8.4180642 42.289022,8.2681890 42.182066,8.2681716 L 29.150665,8.2660527 C 29.150665,8.2660527 30.062379,8.8540072 31.352477,8.8622963 L 42.405974,8.9333167 C 42.417060,8.7215889 42.408695,8.6772845 42.417183,8.5151772 z "
398+ id="path221"
399+ sodipodi:nodetypes="cscscs" />
400+ </g>
401+ <path
402+ style="color:#000000;fill:url(#linearGradient9772);fill-opacity:1.0;fill-rule:nonzero;stroke:#3465a4;stroke-width:1.0000000;stroke-linecap:butt;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4.0000000;stroke-dasharray:none;stroke-dashoffset:0.0000000;stroke-opacity:1;visibility:visible;display:block"
403+ d="M 39.783532,39.510620 C 40.927426,39.466556 41.746608,38.414321 41.830567,37.189615 C 42.622354,25.640928 43.489927,15.957666 43.489927,15.957666 C 43.562082,15.710182 43.322016,15.462699 43.009787,15.462699 L 8.6386304,15.462699 C 8.6386304,15.462699 6.7883113,37.329591 6.7883113,37.329591 C 6.6737562,38.311657 6.3223038,39.134309 5.2384755,39.513304 L 39.783532,39.510620 z "
404+ id="path233"
405+ sodipodi:nodetypes="cscccscc"
406+ inkscape:export-filename="/home/jimmac/ximian_art/icons/nautilus/suse93/gnome-fs-directory.png"
407+ inkscape:export-xdpi="74.800003"
408+ inkscape:export-ydpi="74.800003" />
409+ <path
410+ sodipodi:nodetypes="ccsscsc"
411+ id="path304"
412+ d="M 9.6202444,16.463921 L 42.411343,16.528735 L 40.837297,36.530714 C 40.752975,37.602225 40.386619,37.958929 38.964641,37.958929 C 37.093139,37.958929 10.286673,37.926522 7.569899,37.926522 C 7.8034973,37.605711 7.9036547,36.937899 7.9049953,36.92191 L 9.6202444,16.463921 z "
413+ style="opacity:0.46590909;fill:none;fill-opacity:1.0000000;fill-rule:evenodd;stroke:url(#linearGradient322);stroke-width:0.99999970px;stroke-linecap:round;stroke-linejoin:miter;stroke-opacity:1.0000000" />
414+ <path
415+ sodipodi:nodetypes="ccccc"
416+ id="path323"
417+ d="M 9.6202481,16.223182 L 8.4536014,31.866453 C 8.4536014,31.866453 16.749756,27.718375 27.119949,27.718375 C 37.490142,27.718375 42.675239,16.223182 42.675239,16.223182 L 9.6202481,16.223182 z "
418+ style="fill:#ffffff;fill-opacity:0.089285679;fill-rule:evenodd;stroke:none;stroke-width:1.0000000px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1.0000000" />
419+ </g>
420+ <g
421+ inkscape:groupmode="layer"
422+ id="layer2"
423+ inkscape:label="pattern" />
424+</svg>
wai-app-static.cabal−5
@@ -29,11 +29,6 @@ library
2929 exposed-modules: Network.Wai.Application.Static
3030 ghc-options: -Wall
3131
32−executable warp-static
33− build-depends: warp >= 0.3 && < 0.4
34− main-is: warp-static.hs
35− ghc-options: -Wall -threaded
36−
3732source-repository head
3833 type: git
3934 location: git://github.com/snoyberg/wai-app-static.git
warp-static.hsdeleted−21
@@ -1,21 +0,0 @@
1−import Network.Wai.Application.Static
2− ( StaticSettings (..), staticApp, defaultMimeTypeByExt, defaultListing
3− )
4−import Network.Wai.Handler.Warp (run)
5−import System.Environment (getArgs)
6−
7−main :: IO ()
8−main = do
9− args <- getArgs
10− (folder, port) <- return $
11− case args of
12− [] -> (".", 3000)
13− [f] -> (f, 3000)
14− [f, p] -> (f, read p)
15− _ -> error "Usage: warp-static [root [port]]"
16− run port $ staticApp StaticSettings
17− { ssFolder = folder
18− , ssIndices = ["index.html", "index.htm"]
19− , ssListing = Just defaultListing
20− , ssGetMimeType = return . defaultMimeTypeByExt
21− }