summaryrefslogtreecommitdiffstats
path: root/hugolib/hugo_sites_build.go
diff options
context:
space:
mode:
authorBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2023-10-26 09:38:13 +0200
committerBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2023-10-26 20:41:19 +0200
commit71fd79a3f44101ef515349a24527e6c0b566f368 (patch)
tree4bd1763b0b09a5767ee5501b6df298fd12efc6d2 /hugolib/hugo_sites_build.go
parentc4a530f104f2b0d1dd82211b77b603a07db7c181 (diff)
Revise the deprecation logging
This introduces a more automatic way of increasing the log levels for deprecation log statements based on the version it was deprecated. The thresholds are a little arbitrary, but * We log INFO for 6 releases * We log WARN for another 6 releases * THen ERROR (failing the build) This should give theme authors plenty of time to catch up without having the log filled with warnings.
Diffstat (limited to 'hugolib/hugo_sites_build.go')
-rw-r--r--hugolib/hugo_sites_build.go7
1 files changed, 0 insertions, 7 deletions
diff --git a/hugolib/hugo_sites_build.go b/hugolib/hugo_sites_build.go
index 27fde5822..72b5fe771 100644
--- a/hugolib/hugo_sites_build.go
+++ b/hugolib/hugo_sites_build.go
@@ -25,7 +25,6 @@ import (
"github.com/bep/logg"
"github.com/gohugoio/hugo/hugofs/files"
- "github.com/gohugoio/hugo/langs"
"github.com/gohugoio/hugo/publisher"
"github.com/gohugoio/hugo/tpl"
@@ -40,14 +39,8 @@ import (
"github.com/gohugoio/hugo/output"
"github.com/fsnotify/fsnotify"
- "github.com/gohugoio/hugo/helpers"
)
-func init() {
- // To avoid circular dependencies, we set this here.
- langs.DeprecationFunc = helpers.Deprecated
-}
-
// Build builds all sites. If filesystem events are provided,
// this is considered to be a potential partial rebuild.
func (h *HugoSites) Build(config BuildCfg, events ...fsnotify.Event) error {