OpenDataScotland / jkan

A lightweight, backend-free open data portal, powered by Jekyll, based on the JKAN project
https://opendata.scot
MIT License
7 stars 13 forks source link

Investigate Jekyll build improvements #40

Open JackGilmore opened 1 year ago

JackGilmore commented 1 year ago

Is your feature request related to a problem? Please describe. Jekyll builds currently take about a minute on a good PC at the moment. We should see if we can cut this down. Output stats from a build:

Filename Occurrences in build Bytes Time (s)
 analytics_la_categories.html 1     83.74K 20.443
 _layouts/dataset.html 1697  51051.82K 14.421
 _includes/dataset-form.html 1698  39005.19K 11.584
 _includes/form/organization.html 1698  18805.58K 4.669
 _includes/dataset-form-resource.html 6563   8338.45K 3.031
 _layouts/default.html 1910  71050.41K 2.969
 _includes/head.html 1910   7584.38K 1.563
 _includes/header.html 1910   7575.97K 1.219
 data.json 1   2825.11K 1.05
 sitemap.xml 1    291.94K 1.022
 _includes/form/text.html 27044   6079.75K 0.936
 _includes/form/dropdown.html 6758   3398.73K 0.849
 _includes/breadcrumbs.html 1909    477.27K 0.562
 _layouts/organization.html 194   1399.37K 0.562
 _includes/form/category.html 1698   1719.94K 0.528
 _includes/form/license.html 1698   3323.18K 0.437
 _includes/organization-form.html 195    888.75K 0.435
 datasets.json 1   2714.95K 0.305
 organizations.html 1    163.61K 0.235
 _includes/addons/twittercard.html 1910   1088.24K 0.198
 _includes/display/category.html 1697    424.59K 0.178
 _includes/addons/opengraph.html 1910    882.33K 0.177
 _includes/form/org_type.html 195    219.29K 0.068
 _includes/form/textarea.html 1698   1256.97K 0.062
 _includes/display/link.html 1697    495.88K 0.048
 admin.html 1     41.77K 0.038
 analytics_platform_health.html 1    286.88K 0.037
 analytics_la_coverage.html 1      4.04K 0.036
 data/local_authorities.json 1     16.42K 0.036
 organizations.json 1     89.52K 0.021
 _includes/admin-form-category.html 18     21.03K 0.016
 _includes/footer.html 1910   2100.25K 0.013
 add-dataset.html 1     18.76K 0.006
 add-organization.html 1      4.82K 0.002
 _includes/admin-form-license.html 14     10.05K 0.002
 index.html 1      6.29K 0.002
 _includes/form/checkbox.html 18      3.01K 0.001
 analytics_portal_types.html 1      2.20K 0
 about_opendata.html 1      4.14K 0
 analytics_file_types.html 1      2.53K 0
 analytics_licensing.html 1      2.37K 0
 about_siteanalytics.html 1      0.89K 0
 resources.html 1     12.76K 0
 jekyll-redirect-from-0.16.0/lib/jekyll-redirect-from/redirect.html 3      1.70K 0
 datasets.html 1      0.96K 0
 soocon23.html 1      1.72K 0
 suggest_dataset.html 1      1.74K 0
 about_project.html 1      4.41K 0
 analytics.html 1      4.85K 0

Done in 65.089 seconds.

Describe the solution you'd like Investigate if build can be optimised with any of the techniques in this article: https://forestry.io/blog/how-i-reduced-my-jekyll-build-time-by-61/

Describe alternatives you've considered N/A

Additional context N/A