You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
f.AddOpt(&htmlMinifier.KeepEndTags, "", "html-keep-end-tags", "Preserve all end tags")
237
237
f.AddOpt(&htmlMinifier.KeepWhitespace, "", "html-keep-whitespace", "Preserve whitespace characters but still collapse multiple into one")
238
238
f.AddOpt(&htmlMinifier.KeepQuotes, "", "html-keep-quotes", "Preserve quotes around attribute values")
239
+
//f.AddOpt(&htmlMinifier.TemplateDelims, "", "html-template-delims", "Set template delimiters explicitly, for example <?,?> for PHP or {{,}} for Go templates") // TODO: fix parsing {{ }} in tdewolff/argp
239
240
f.AddOpt(&jsMinifier.Precision, "", "js-precision", "Number of significant digits to preserve in numbers, 0 is all")
240
241
f.AddOpt(&jsMinifier.KeepVarNames, "", "js-keep-var-names", "Preserve original variable names")
241
242
f.AddOpt(&jsMinifier.Version, "", "js-version", "ECMAScript version to toggle supported optimizations (e.g. 2019, 2020), by default 0 is the latest version")
@@ -280,8 +281,8 @@ func run() int {
280
281
281
282
iflen(inputs) ==1&&inputs[0] =="-" {
282
283
inputs=inputs[:0] // stdin
283
-
} elseifoutput=="-" {
284
-
output=""// stdout
284
+
} elseif!inplace&&output=="" {
285
+
output="-"// stdout
285
286
}
286
287
useStdin:=len(inputs) ==0
287
288
@@ -344,7 +345,7 @@ func run() int {
344
345
Error.Println("cannot specify both --inplace and --output")
0 commit comments