From: Joe Mooring Date: Sat, 8 Nov 2025 20:39:42 +0000 (-0800) Subject: config: Add struct tags to deprecated and unused fields X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=e1236e3d0da7daed64819ae2e602793125b2d9cc;p=brevno-suite%2Fhugo config: Add struct tags to deprecated and unused fields This will remove these fields from the output of newDocsHelper. --- diff --git a/config/privacy/privacyConfig.go b/config/privacy/privacyConfig.go index 900f73540..e837cedab 100644 --- a/config/privacy/privacyConfig.go +++ b/config/privacy/privacyConfig.go @@ -30,7 +30,7 @@ type Config struct { Disqus Disqus GoogleAnalytics GoogleAnalytics Instagram Instagram - Twitter Twitter // deprecated in favor of X in v0.141.0 + Twitter Twitter `json:"-"` // deprecated in favor of X in v0.141.0 Vimeo Vimeo YouTube YouTube X X diff --git a/config/services/servicesConfig.go b/config/services/servicesConfig.go index f9d5e1a6e..21dd7a6d9 100644 --- a/config/services/servicesConfig.go +++ b/config/services/servicesConfig.go @@ -26,12 +26,12 @@ const ( rssLimitKey = "rssLimit" ) -// Config is a privacy configuration for all the relevant services in Hugo. +// Config is a services configuration for all the relevant services in Hugo. type Config struct { Disqus Disqus GoogleAnalytics GoogleAnalytics - Instagram Instagram - Twitter Twitter // deprecated in favor of X in v0.141.0 + Instagram Instagram `json:"-"` // the embedded instagram shortcode no longer uses this + Twitter Twitter `json:"-"` // deprecated in favor of X in v0.141.0 X X RSS RSS } @@ -53,12 +53,12 @@ type Instagram struct { // The Simple variant of the Instagram is decorated with Bootstrap 4 card classes. // This means that if you use Bootstrap 4 or want to provide your own CSS, you want // to disable the inline CSS provided by Hugo. - DisableInlineCSS bool + DisableInlineCSS bool // this is no longer used by the embedded instagram shortcode // App or Client Access Token. // If you are using a Client Access Token, remember that you must combine it with your App ID // using a pipe symbol (|) otherwise the request will fail. - AccessToken string + AccessToken string // this is no longer used by the embedded instagram shortcode } // Twitter holds the functional configuration settings related to the Twitter shortcodes.