mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-29 22:29:56 +02:00
@@ -492,10 +492,15 @@ func (h *HugoSites) writeBuildStats() error {
|
||||
HTMLElements: *htmlElements,
|
||||
}
|
||||
|
||||
js, err := json.MarshalIndent(stats, "", " ")
|
||||
var buf bytes.Buffer
|
||||
enc := json.NewEncoder(&buf)
|
||||
enc.SetEscapeHTML(false)
|
||||
enc.SetIndent("", " ")
|
||||
err := enc.Encode(stats)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
js := buf.Bytes()
|
||||
|
||||
filename := filepath.Join(h.Configs.LoadingInfo.BaseConfig.WorkingDir, files.FilenameHugoStatsJSON)
|
||||
|
||||
|
Reference in New Issue
Block a user