URI: 
       Don't re-render aliases on server rebuilds - hugo - [fork] hugo port for 9front
  HTML git clone git@git.drkhsh.at/hugo.git
   DIR Log
   DIR Files
   DIR Refs
   DIR Submodules
   DIR README
   DIR LICENSE
       ---
   DIR commit 778f0d90024fa9ad6e436b99b333248074c7d5d8
   DIR parent 13b208e2f70fd0bfad8a4ae33a30afb5fd4b7477
  HTML Author: Bjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>
       Date:   Wed, 29 Jan 2025 20:13:25 +0100
       
       Don't re-render aliases on server rebuilds
       
       This can lead to stale aliases when rebuilding, but that's a trade-off we need to take for snappier rebuilds on bigger sites.
       
       Note that it should be possible to detect alias changes, but I'm not sure it's worth it.
       
       Diffstat:
         M hugolib/site.go                     |       2 +-
       
       1 file changed, 1 insertion(+), 1 deletion(-)
       ---
   DIR diff --git a/hugolib/site.go b/hugolib/site.go
       @@ -1542,7 +1542,7 @@ func (s *Site) render(ctx *siteRenderContext) (err error) {
                        return err
                }
        
       -        if ctx.outIdx == 0 {
       +        if ctx.outIdx == 0 && s.h.buildCounter.Load() == 0 {
                        // Note that even if disableAliases is set, the aliases themselves are
                        // preserved on page. The motivation with this is to be able to generate
                        // 301 redirects in a .htaccess file and similar using a custom output format.