hugo/hugolib
Bjørn Erik Pedersen cdcd15b6c2
Only create LazyContentProvider for the non-rendering Site
Which saves a fair amound of allocations:

```
gobench --package ./hugolib --bench "SiteNew/Regular_D" --base master
```

Before:

```
name                                  old time/op    new time/op    delta
SiteNew/Regular_Deep_content_tree-10    40.7ms ± 3%    41.2ms ± 1%    ~     (p=0.343 n=4+4)

name                                  old alloc/op   new alloc/op   delta
SiteNew/Regular_Deep_content_tree-10    27.7MB ± 0%    28.8MB ± 0%  +3.76%  (p=0.029 n=4+4)

name                                  old allocs/op  new allocs/op  delta
SiteNew/Regular_Deep_content_tree-10      304k ± 0%      329k ± 0%  +8.07%  (p=0.029 n=4+4)
```

After:

```
name                                  old time/op    new time/op    delta
SiteNew/Regular_Deep_content_tree-10    34.2ms ± 1%    34.7ms ± 1%    ~     (p=0.114 n=4+4)

name                                  old alloc/op   new alloc/op   delta
SiteNew/Regular_Deep_content_tree-10    27.7MB ± 0%    28.1MB ± 0%  +1.38%  (p=0.029 n=4+4)

name                                  old allocs/op  new allocs/op  delta
SiteNew/Regular_Deep_content_tree-10      304k ± 0%      314k ± 0%  +3.03%  (p=0.029 n=4+4)
```

Updates #8919
2022-01-12 07:45:53 +01:00
..
assets/images
filesystems Make sure we always create the /public folder 2021-12-23 15:09:27 +01:00
paths
testdata Add some basic security policies with sensible defaults 2021-12-16 09:40:22 +01:00
testsite
404_test.go
alias.go
alias_test.go
breaking_changes_test.go
cascade_test.go
case_insensitive_test.go
collections.go
collections_test.go
config.go Misc depreation updates 2022-01-04 17:10:39 +01:00
config_test.go config: Set HUGO_ENABLEGITINFO=false override in Set_in_string 2021-10-22 19:40:18 +02:00
configdir_test.go Switch to go-toml v2 2021-07-28 11:51:13 +02:00
content_factory.go Improve error when we cannot determine content directory in "hugo new" 2021-11-15 11:21:39 +01:00
content_factory_test.go Fix path resolution in hugo new 2021-11-08 14:10:46 +01:00
content_map.go hugofs: Make FileMeta a struct 2021-07-15 17:14:26 +02:00
content_map_page.go Misc depreation updates 2022-01-04 17:10:39 +01:00
content_map_test.go hugofs: Make FileMeta a struct 2021-07-15 17:14:26 +02:00
content_render_hooks_test.go markup/goldmark: Support auto links in render hook 2021-07-15 10:14:52 +02:00
datafiles_test.go
dates_test.go Fix error handling for the time func alias 2021-08-01 13:39:30 +02:00
disableKinds_test.go
embedded_shortcodes_test.go Update Twitter shortcode oEmbed endpoint 2021-11-01 15:51:00 +01:00
embedded_templates_test.go Remove empty href element from pagination template 2021-12-02 09:14:30 +01:00
fileInfo.go
fileInfo_test.go
gitinfo.go
hugo_modules_test.go Validate private use language tags 2021-12-02 16:30:53 +01:00
hugo_sites.go Add a cross process build lock and use it in the archetype content builder 2021-10-18 12:13:13 +02:00
hugo_sites_build.go Add a cross process build lock and use it in the archetype content builder 2021-10-18 12:13:13 +02:00
hugo_sites_build_errors_test.go
hugo_sites_build_test.go
hugo_sites_multihost_test.go
hugo_sites_rebuild_test.go
hugo_smoke_test.go Add hugo.Deps 2022-01-11 18:06:23 +01:00
image_test.go
js_test.go deps: Upgrade github.com/evanw/esbuild v0.14.2 => v0.14.5 2021-12-17 08:26:45 +01:00
language_content_dir_test.go
language_test.go Reduce binary size vs locale, update to CLDR v36.1 2021-08-02 19:40:32 +02:00
menu_test.go Improve handling of <nil> Params 2021-07-30 21:07:52 +02:00
minify_publisher_test.go
mount_filters_test.go Fix panic when specifying multiple excludeFiles directives 2021-10-25 19:50:18 +02:00
multilingual.go
openapi_test.go
page.go Only create LazyContentProvider for the non-rendering Site 2022-01-12 07:45:53 +01:00
page__common.go
page__content.go
page__data.go
page__menus.go Simplify "active menu" logic for section menus 2021-07-20 17:50:59 +02:00
page__meta.go Misc depreation updates 2022-01-04 17:10:39 +01:00
page__new.go
page__output.go
page__paginator.go
page__paths.go
page__per_output.go
page__position.go
page__ref.go
page__tree.go
page_kinds.go
page_permalink_test.go
page_test.go Fix missing page data for alternative formats 2022-01-12 07:45:53 +01:00
page_unwrap.go
page_unwrap_test.go
pagebundler_test.go hugofs: Make FileMeta a struct 2021-07-15 17:14:26 +02:00
pagecollections.go hugofs: Make FileMeta a struct 2021-07-15 17:14:26 +02:00
pagecollections_test.go
pages_capture.go hugofs: Make FileMeta a struct 2021-07-15 17:14:26 +02:00
pages_capture_test.go Reimplement archetypes 2021-10-16 15:22:03 +02:00
pages_language_merge_test.go
pages_process.go Fix "stuck on build" in error situations in content processing 2021-12-23 15:09:27 +01:00
pages_test.go
paginator_test.go
permalinker.go
prune_resources.go
resource_chain_babel_test.go Add some basic security policies with sensible defaults 2021-12-16 09:40:22 +01:00
resource_chain_test.go media: Also consider extension in FromContent 2021-12-22 11:35:53 +01:00
robotstxt_test.go
rss_test.go
securitypolicies_test.go Add resources.GetRemote 2021-12-17 09:33:51 +01:00
shortcode.go Add some basic security policies with sensible defaults 2021-12-16 09:40:22 +01:00
shortcode_page.go
shortcode_test.go Remove mmark 2022-01-04 17:10:39 +01:00
site.go Add hugo.Deps 2022-01-11 18:06:23 +01:00
site_benchmark_new_test.go Add a TOML front matter benchmark 2021-07-27 19:27:54 +02:00
site_output.go
site_output_test.go Fix surprise OutputFormat.Rel overwriting 2022-01-04 10:38:38 +01:00
site_render.go
site_sections.go
site_sections_test.go
site_stats_test.go
site_test.go Misc depreation updates 2022-01-04 17:10:39 +01:00
site_url_test.go
siteJSONEncode_test.go
sitemap_test.go
taxonomy.go
taxonomy_test.go
template_test.go Allow for return partials with falsy arguments (#9298) 2021-12-17 08:35:21 +01:00
testhelpers_test.go Misc depreation updates 2022-01-04 17:10:39 +01:00
translations.go