mirror of
https://github.com/gohugoio/hugo.git
synced 2024-11-21 20:46:30 -05:00
deps: Update github.com/tdewolff/minify/v2 v2.20.7 => v2.20.8
Closes #5748
This commit is contained in:
parent
36a60f65d0
commit
bfc325f561
4 changed files with 58 additions and 6 deletions
|
@ -824,6 +824,8 @@ chroma:
|
||||||
- Aliases:
|
- Aliases:
|
||||||
- typoscripthtmldata
|
- typoscripthtmldata
|
||||||
Name: TypoScriptHtmlData
|
Name: TypoScriptHtmlData
|
||||||
|
- Aliases: null
|
||||||
|
Name: ucode
|
||||||
- Aliases:
|
- Aliases:
|
||||||
- v
|
- v
|
||||||
- vlang
|
- vlang
|
||||||
|
@ -1254,6 +1256,9 @@ config:
|
||||||
keepEndTags: true
|
keepEndTags: true
|
||||||
keepQuotes: false
|
keepQuotes: false
|
||||||
keepWhitespace: false
|
keepWhitespace: false
|
||||||
|
templateDelims:
|
||||||
|
- ""
|
||||||
|
- ""
|
||||||
js:
|
js:
|
||||||
keepVarNames: false
|
keepVarNames: false
|
||||||
precision: 0
|
precision: 0
|
||||||
|
@ -2741,6 +2746,21 @@ tpl:
|
||||||
map[string]interface {}{
|
map[string]interface {}{
|
||||||
"Hugo": "Rocks!",
|
"Hugo": "Rocks!",
|
||||||
}
|
}
|
||||||
|
TestDeprecationErr:
|
||||||
|
Aliases: null
|
||||||
|
Args: null
|
||||||
|
Description: ""
|
||||||
|
Examples: null
|
||||||
|
TestDeprecationInfo:
|
||||||
|
Aliases: null
|
||||||
|
Args: null
|
||||||
|
Description: ""
|
||||||
|
Examples: null
|
||||||
|
TestDeprecationWarn:
|
||||||
|
Aliases: null
|
||||||
|
Args: null
|
||||||
|
Description: ""
|
||||||
|
Examples: null
|
||||||
Timer:
|
Timer:
|
||||||
Aliases: null
|
Aliases: null
|
||||||
Args: null
|
Args: null
|
||||||
|
@ -4364,6 +4384,16 @@ tpl:
|
||||||
- - '{{ "hello = \"Hello World\"" | resources.FromString "data/greetings.toml"
|
- - '{{ "hello = \"Hello World\"" | resources.FromString "data/greetings.toml"
|
||||||
| transform.Unmarshal }}'
|
| transform.Unmarshal }}'
|
||||||
- map[hello:Hello World]
|
- map[hello:Hello World]
|
||||||
|
XMLEscape:
|
||||||
|
Aliases: null
|
||||||
|
Args:
|
||||||
|
- s
|
||||||
|
Description: |-
|
||||||
|
XMLEscape returns the given string, removing disallowed characters then
|
||||||
|
escaping the result to its XML equivalent.
|
||||||
|
Examples:
|
||||||
|
- - '{{ transform.XMLEscape "<p>abc</p>" }}'
|
||||||
|
- '<p>abc</p>'
|
||||||
urls:
|
urls:
|
||||||
AbsLangURL:
|
AbsLangURL:
|
||||||
Aliases:
|
Aliases:
|
||||||
|
|
4
go.mod
4
go.mod
|
@ -61,8 +61,8 @@ require (
|
||||||
github.com/spf13/cobra v1.8.0
|
github.com/spf13/cobra v1.8.0
|
||||||
github.com/spf13/fsync v0.9.0
|
github.com/spf13/fsync v0.9.0
|
||||||
github.com/spf13/pflag v1.0.5
|
github.com/spf13/pflag v1.0.5
|
||||||
github.com/tdewolff/minify/v2 v2.20.7
|
github.com/tdewolff/minify/v2 v2.20.8
|
||||||
github.com/tdewolff/parse/v2 v2.7.5
|
github.com/tdewolff/parse/v2 v2.7.6
|
||||||
github.com/yuin/goldmark v1.6.0
|
github.com/yuin/goldmark v1.6.0
|
||||||
github.com/yuin/goldmark-emoji v1.0.2
|
github.com/yuin/goldmark-emoji v1.0.2
|
||||||
go.uber.org/atomic v1.11.0
|
go.uber.org/atomic v1.11.0
|
||||||
|
|
8
go.sum
8
go.sum
|
@ -326,10 +326,10 @@ github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO
|
||||||
github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4=
|
github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4=
|
||||||
github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk=
|
github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk=
|
||||||
github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo=
|
github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo=
|
||||||
github.com/tdewolff/minify/v2 v2.20.7 h1:NUkuzJ9dvQUNJjSdmmrfELa/ZpnMdyMR/ZKU2bw7N/E=
|
github.com/tdewolff/minify/v2 v2.20.8 h1:OqDc95F0OK239T7P5g5oL5XthQtOtKbhbhM9GKc2W9g=
|
||||||
github.com/tdewolff/minify/v2 v2.20.7/go.mod h1:bj2NpP3zoUhsPzE4oM4JYwuUyVCU/uMaCYZ6/riEjIo=
|
github.com/tdewolff/minify/v2 v2.20.8/go.mod h1:hZnNtFqXVQ5QIAR05tdgvS7h6E80jyRwHSGVmM4jbzQ=
|
||||||
github.com/tdewolff/parse/v2 v2.7.5 h1:RdcN3Ja6zAMSvnxxO047xRoWexX3RrXKi3H6EQHzXto=
|
github.com/tdewolff/parse/v2 v2.7.6 h1:PGZH2b/itDSye9RatReRn4GBhsT+KFEMtAMjHRuY1h8=
|
||||||
github.com/tdewolff/parse/v2 v2.7.5/go.mod h1:3FbJWZp3XT9OWVN3Hmfp0p/a08v4h8J9W1aghka0soA=
|
github.com/tdewolff/parse/v2 v2.7.6/go.mod h1:3FbJWZp3XT9OWVN3Hmfp0p/a08v4h8J9W1aghka0soA=
|
||||||
github.com/tdewolff/test v1.0.11-0.20231101010635-f1265d231d52 h1:gAQliwn+zJrkjAHVcBEYW/RFvd2St4yYimisvozAYlA=
|
github.com/tdewolff/test v1.0.11-0.20231101010635-f1265d231d52 h1:gAQliwn+zJrkjAHVcBEYW/RFvd2St4yYimisvozAYlA=
|
||||||
github.com/tdewolff/test v1.0.11-0.20231101010635-f1265d231d52/go.mod h1:6DAvZliBAAnD7rhVgwaM7DE5/d9NMOAJ09SqYqeK4QE=
|
github.com/tdewolff/test v1.0.11-0.20231101010635-f1265d231d52/go.mod h1:6DAvZliBAAnD7rhVgwaM7DE5/d9NMOAJ09SqYqeK4QE=
|
||||||
github.com/ugorji/go/codec v1.2.7 h1:YPXUKf7fYbp/y8xloBqZOw2qaVggbfwMlI8WM3wZUJ0=
|
github.com/ugorji/go/codec v1.2.7 h1:YPXUKf7fYbp/y8xloBqZOw2qaVggbfwMlI8WM3wZUJ0=
|
||||||
|
|
|
@ -689,3 +689,25 @@ title: "p1"
|
||||||
|
|
||||||
b.AssertFileContentExact("public/p1/index.html", "<p>:x:</p>")
|
b.AssertFileContentExact("public/p1/index.html", "<p>:x:</p>")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Issue #5748
|
||||||
|
func TestGoldmarkTemplateDelims(t *testing.T) {
|
||||||
|
t.Parallel()
|
||||||
|
|
||||||
|
files := `
|
||||||
|
-- config.toml --
|
||||||
|
[minify]
|
||||||
|
minifyOutput = true
|
||||||
|
[minify.tdewolff.html]
|
||||||
|
templateDelims = ["<?php","?>"]
|
||||||
|
-- layouts/index.html --
|
||||||
|
<div class="foo">
|
||||||
|
{{ safeHTML "<?php" }}
|
||||||
|
echo "hello";
|
||||||
|
{{ safeHTML "?>" }}
|
||||||
|
</div>
|
||||||
|
`
|
||||||
|
|
||||||
|
b := hugolib.Test(t, files)
|
||||||
|
b.AssertFileContent("public/index.html", "<div class=foo><?php\necho \"hello\";\n?>\n</div>")
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in a new issue