Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/gohugoio/hugo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhil Pennock <pdp@spodhuis.org>2014-01-04 03:36:53 +0400
committerspf13 <steve.francia@gmail.com>2014-01-13 19:06:12 +0400
commit438c2198923022a3e4d299b06a7df18268041dd8 (patch)
tree2e0a27b4db0a03817921eb7b7e5a90590b7bb01b /transform/chain.go
parent2ff108fcb7059dd9b73526b1bfce42b43579fc25 (diff)
Add `canonifyurls` config option.
Be able to inhibit AbsURL canonicalization of content, on a site configuration basis. Advantages of being able to inhibit this include making it easier to rendering on other hostnames, and being able to include resources on http or https depending on how this page was retrieved, avoiding mixed-mode client complaints without adding latency for plain http.
Diffstat (limited to 'transform/chain.go')
-rw-r--r--transform/chain.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/transform/chain.go b/transform/chain.go
index fb3c2985c..c673c5d6a 100644
--- a/transform/chain.go
+++ b/transform/chain.go
@@ -15,6 +15,10 @@ func NewChain(trs ...link) chain {
return trs
}
+func NewEmptyTransforms() []link {
+ return make([]link, 0, 20)
+}
+
func (c *chain) Apply(w io.Writer, r io.Reader) (err error) {
buffer := new(bytes.Buffer)