Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Incremental Build (while watching) #1643
Hugo today rebuilds the entire site each time it is rendered. This isn't necessary and Hugo could be a lot more intelligent particularly during while watching where it already has read in the entire source and built up a tree.
What would need to happen...
This issue has been automatically marked as stale because it has not been commented on for at least six months.
The resources of the Hugo team are limited, and so we are asking for your help.
If this is a bug and you can still reproduce this error on the
If this is a feature request, and you feel that it is still relevant and valuable, please tell us why.
This issue will automatically be closed in the near future if no further activity occurs. Thank you for all your contributions.
In my view this is a huge feature request. Hugo should not restrict itself to documentation sites or small blogs but to prove to the whole of the computer services that it is today the state of the art and this even for very big websites. One of the difficulties of static site generation is the management of the generation of content in real time. Workarounds exist like making exist a hugo in page mode and hugo in site mode. I think the incremental buid could solve this problem.
Because this is a much harder problem. And it would be good if @spf13 could update his description to match that reality. He may be correct saying that this is a "well-understood problem" in the general sense of it, but that is like saying "so, Java and C++ have Generics, why haven't Go added support for it?"
The core of the problem comes from the freedom we give to the template developers (you): We give you a complete site object graph to play with for every template, which makes the "is this page stale?" questions harder to answer than you might think (think
While still incredibly hard, this is easier and more possible now compared to when this issue was created. Back then there was no unified object graph. Now it is: The root is the
OK, so all of this rubber ducking actually helps. I think I may have wrapped my head around the hardest problem. I'll write down the gist of it so I don't forget.
In Hugo, we have done two recent improvements in the template area that is unrelated, but may help:
Common for all of the template executions is that they start with a
We should be able to inject a proxy in the templates so we can associate the
There is still a lot of work in the above, but now it at least looks possible.