0
Fork 0
mirror of https://github.com/caddyserver/caddy.git synced 2024-12-23 22:27:38 -05:00
Commit graph

250 commits

Author SHA1 Message Date
Maxime
d1eb2ea9e2 Changed metadata variables type:
from map[string]interface{} to map[string]string
2015-07-26 18:32:34 +02:00
Matthew Holt
453d3eb567 markdown: Fix when md file has front matter but empty body 2015-07-25 15:47:33 -06:00
Matt Holt
bf47951f3a Merge pull request #196 from evermax/master
markdown, browse: Integrated Context struct for templating
2015-07-25 15:15:51 -06:00
Maxime
604c8abb59 Remove debug line, add file name as default title 2015-07-25 22:39:13 +02:00
Maxime
ef4a4b0ab8 Removed attribute not needed. 2015-07-24 22:17:14 +02:00
Maxime
24bdb433c9 Changed .Var to .Doc in Markdown templates
Put the title into the .Doc variables as well.
Changed the test template file to use new names.
2015-07-24 22:14:05 +02:00
Matthew Holt
a578c43810 browse: Add txt files to list of default files 2015-07-24 10:27:19 -06:00
Matthew Holt
74b758034e redir: Allows replacements; defaults to exact match redirects
This is a breaking change for those who expect catch-all redirects to preserve path; use {uri} variable explicitly now
2015-07-24 10:27:19 -06:00
Matthew Holt
04571ff393 NewReplacer takes third argument for empty value string 2015-07-24 10:27:19 -06:00
pyed
1589129ea1 Save sorting preferences as cookies
To be used across directories
2015-07-23 13:25:03 +03:00
Maxime
97dcc79a7f Remove undesired committed debug logs 2015-07-23 11:53:15 +02:00
Maxime
bc2feece4b Moved test files to testdata folder.
Changed the tests accordingly.
2015-07-23 09:35:46 +02:00
Maxime
2df30d186e Added a test on markdown for the default template 2015-07-21 17:45:32 +02:00
Maxime
6451e10d3e Add context to markdown template
Created a struct containing middleware.Context, Title, Markdown and the
variables from the user to use to render the template.
The title now can be accessed via {{.Title}}.
The variables can now be accessed via {{.Var.myVariableName}}.
2015-07-21 07:58:34 +02:00
Matthew Holt
00997db5ae markdown: Fix large markdown files that got truncated 2015-07-18 12:57:16 -06:00
Maxime
2d5320c454 Added test for the browse directive
Created sample files for the test
2015-07-18 11:37:05 +02:00
Maxime
2fa6e278d2 Merge branch 'master' of https://github.com/mholt/caddy 2015-07-18 09:58:27 +02:00
Maxime
f536bc94b2 Added the Context to the browse directive
Moved the Context type to middleware and exported it.
Users can use .Include and others in browse directive templating
Created test for the templates directive.
2015-07-17 20:07:24 +02:00
Matthew Holt
afc540f6b7 Updated changes 2015-07-15 09:36:34 -06:00
Matt Holt
fcf2622c26 Merge pull request #187 from evermax/master
redir: Preserve query string on catch-all redirect (fixes #180)
2015-07-13 09:42:19 -06:00
Maxime
d9ebc5398a Changes regarding review
Use path.Join and then check if the request had a slash at the end to
place it again.
2015-07-12 21:22:15 +02:00
Maxime
eea68c34ad Changes regarding comment.
Used http status code instead of a hardcoded value.
Used url.Parse instead of url.ParseRequestURI, so that you can parse
both absolute and relative URL.
2015-07-12 16:43:35 +02:00
Maxime
8a2d0890a2 Changes regarding issue 180
The get parameters are now forwarded when redirected.
Added some tests to validate this behavior.
2015-07-12 16:01:32 +02:00
Peter Hellberg
33fa29fda0 extensions: Initial tests 2015-07-10 12:05:06 -06:00
Matthew Holt
c82d7c2dd2 templates: Better error handling for missing files 2015-07-06 23:37:27 -06:00
Abiola Ibrahim
d4f0ac2303 Merge remote-tracking branch 'upstream/master' 2015-07-06 06:43:02 +01:00
Abiola Ibrahim
4588812d24 Gzip: Fix wildcard extension bug. 2015-07-06 06:36:48 +01:00
Matthew Holt
9467dbdd40 Fix errors tests 2015-07-05 23:23:35 -06:00
Matthew Holt
71c4fdbc85 errors: Prepend timestamp to log entry 2015-07-05 23:20:37 -06:00
Matthew Holt
b5579ca910 gzip: Remove mimes 2015-07-03 18:13:30 -06:00
Matthew Holt
32ef35b952 gzip: Fix tests 2015-07-01 19:05:31 -06:00
Matthew Holt
abf22909f1 gzip: Make it gzip again 2015-07-01 18:56:30 -06:00
Matt Holt
263fa064cd Merge pull request #169 from abiosoft/master
git: Remove from core (available as add-on)
2015-07-01 11:44:49 -06:00
Matthew Holt
915172e9ef templates: Close files after done including them 2015-07-01 11:36:37 -06:00
Matthew Holt
4d066b7e30 ext: Only append extension if request is not for directory (fixes #173) 2015-07-01 11:35:52 -06:00
Abiola Ibrahim
a7f0705bcf Merge remote-tracking branch 'upstream/master' 2015-07-01 14:01:45 +01:00
Matthew Holt
7a42e60bcb templates: Support for nested include files
i.e. included files are also parsed as templates
2015-06-30 18:21:18 -06:00
Abiola Ibrahim
aecdecbdf8 Merge remote-tracking branch 'upstream/master' 2015-06-30 17:31:40 +01:00
Abiola Ibrahim
4240817a3a Fix for Issue 141: index not found, 502 Bad Gateway. 2015-06-30 11:54:50 +01:00
Abiola Ibrahim
3f1f6720ee Decouple git middleware from caddy core. Now available as an add-on at https://github.com/abiosoft/caddy-git. 2015-06-28 00:31:52 +01:00
Matt Holt
47096e112a Merge pull request #156 from pyed/sort
browse: Ability to sort
2015-06-22 12:40:58 -06:00
pyed
68add78230 Implement sorting functionality for "Browse" 2015-06-21 18:04:47 +03:00
Matt Holt
6b27d4ce11 Merge pull request #131 from slav123/master
fastcgi: fix #127
2015-06-17 17:26:52 -06:00
Slawomir Jasinski
f11e136068 Update fcgiclient.go 2015-06-18 09:12:35 +10:00
Matthew Holt
c811d416a7 log: Customizable default error function 2015-06-15 10:17:09 -06:00
Simon Jefford
6c1f2af53a log: ensure the correct status is always logged
in the case of error (>=400) then no response may have been sent
2015-06-14 21:00:27 +01:00
Matt Holt
d7051e986f Merge pull request #134 from tw4452852/hijack
middleware: let middleware.responseRecorder be a http.Hijacker
2015-06-12 08:26:49 -06:00
Tw
e79a88856a let middleware.responseRecorder be a http.Hijacker
Signed-off-by: Tw <tw19881113@gmail.com>
2015-06-12 11:42:28 +08:00
Slawomir Jasinski
db2368cd0b Removed parentheses #127 2015-06-12 11:33:55 +10:00
slav123
29404e34d9 code cleanup 2015-06-11 13:17:56 +10:00