Releases: gohugoio/hugo
v0.36
Hugo 0.36
announces smart cropping of images, using the library created by muesli. We will work with him to improve this even more in the future, but this is now the default used when cropping images in Hugo.
Go here for a list of examples.
This release represents 7 contributions by 3 contributors to the main Hugo code base.
Many have also been busy writing and fixing the documentation in hugoDocs,
which has received 9 contributions by 4 contributors. A special thanks to @bep, @Jibec, @Nick-Rivera, and @kaushalmodi for their work on the documentation site.
Hugo now has:
- 23100+ stars
- 448+ contributors
- 197+ themes
Notes
Hugo now defaults to smart crop when cropping images, if you don't specify it when calling .Fill
.
You can get the old default by adding this to your config.toml
:
[imaging]
anchor = "center"
Also, we have removed the superflous anchor name from the processed filenames that does not use this anchor, so it can be wise to run hugo --gc
once to remove unused images.
Enhancements
Fixes
- Ensure site templates can override theme templates 084cf419 @moorereason #3505
- Add additional test to
TestTemplateLookupOrder
fc06d5c1 @moorereason #3505 - Fix broken
TestTemplateLookupOrder
9a367d9d @moorereason - Fix JSON array-based data file handling regression 4402c077 @vassudanagunta #4361
- Increase data directory test coverage 4743de0d @vassudanagunta #4138
Automated with GoReleaser
Built with go version go1.9.3 linux/amd64
v0.35
The most notable new feature in Hugo 0.35
is perhaps Headless Bundles.
This means that you in your index.md
front matter can say:
headless: true
And
- it will have no
Permalink
and no rendered HTML in/public
- it will not be part of
.Site.RegularPages
etc.
But you can get it by:
.Site.GetPage ...
The use cases are many:
- Shared media libraries
- Reusable page content "snippets"
- ...
But this release contains more goodies than possible to sum up in one paragraph, so study the release notes carefully. It represents 42 contributions by 8 contributors to the main Hugo code base.
@bep leads the Hugo development with a significant amount of contributions, but also a big shoutout to @vassudanagunta, @yanzay, and @robertbasic for their ongoing contributions.
And as always a big thanks to @digitalcraftsman for his relentless work on keeping the documentation and the themes site in pristine condition.
Many have also been busy writing and fixing the documentation in hugoDocs,
which has received 28 contributions by 5 contributors. A special thanks to @bep, @kaushalmodi, @regisphilibert, and @salim-b for their work on the documentation site.
Hugo now has:
- 22967+ stars
- 448+ contributors
- 197+ themes
Notes
- Deprecate
useModTimeAsFallback
adfd4370 @bep #4351 - Deprecate CLI flags
canonifyURLs
,pluralizeListTitles
,preserveTaxonomyNames
,uglyURLs
f08ea02d @bep #4347 - Remove undraft command 2fa70c93 @robertbasic #4353
Enhancements
Templates
- Update Twitter card to also consider images in
.Resources
25d691da @bep #4349 - Seed random on init only 83c761b7 @liguoqinjim
- Remove duplicate layout lookup layouts b2fcbb1f @bep #4319
- Add "removable-media" interface to
snapcraft.yaml
f0c0ece4 @anthonyfok #3837
Other
- Add a way to disable one or more languages 6413559f @bep #4297#4329
- Handle newly created files in Fast Render Mode 1707dae8 @yanzay #4339
- Extract the Fast Render Mode logic into a method 94e736c5 @bep #4339
- Remove unused code ae5a45be @bep
- Add the last lookup variant for the
GetPage
index 3446fe9b @bep #4312 - Simplify bundle lookup via
.Site.GetPage
,ref
,relref
517b6b62 @bep #4312 - Remove some now superflous Fast Render Mode code feeed073 @bep #4339
- Make resource counters for
name
andtitle
independent df20b054 @bep #4335 - Provide .Name to the archetype templates 863a812e @bep #4348
- Only set
url
if permalink in metadata and remove duplicate confirm msg 3752348e @lildude #1887 - Start Resources :counter first time they're used 7b472e46 @bep #4335
- Update to Go 1.9.3 a91aba1c @bep #4328
- Support pages without front matter 91bb774a @vassudanagunta #4320#4320
- Add page metadata dates tests 3f0379ad @vassudanagunta
- Re-generate CLI docs 1e27d058 @bep
- Remove and update deprecation status d418c2c2 @bep
- Shorten the stale setup 4a7c2b36 @bep
- Add a
GetPage
to the site benchmarks a1956391 @bep - Add headless bundle support 0432c64d @bep #4311
- Merge matching resources params maps 5a0819b9 @bep #4315
- Add some general code contribution criterias 78c86330 @bep
- Tighten page kind logic, introduce tests 8125b4b0 @vassudanagunta
Fixes
- Fix
robots.txt
in multihost mode 4d912e2a @bep #4193 - Fix
--uglyURLs
from comand line regression 016398ff @bep #4343 - Avoid unescape in
highlight
ebdd8cba @bep #4219 - Fix Docker build a34213f0 @skoblenick #4076#4077
- Fix language params handling ae742cb1 @bep #4356#4352
- Fix handling of top-level page bundles 4eb2fec6 @bep #4332
- Fix
baseURL
server regression for multilingual sites ed4a00e4 @bep #4333 - Fix "date" page param 322c5672 @vassudanagunta #4323
- Fix typo in comment [912147a](https://github.com/gohugoio/hu...
v0.34
Hugo 0.34
is a small release. It contains a few smaller bug-fixes, but more important is an overhaul of the API used to find images and other resources in your page bundles.
We have added two simple methods on the Resources
object:
.Match
finds every resource matching a pattern. Examples:.Match "images/*.jpg"
finds every JPEG image inimages
and.Match "**.jpg"
finds every JPEG image in the bundle..GetMatch
finds the first resource matching the pattern given.
Note: The path separators used are Unix-style forward slashes, even on Windows.
It uses standard wildcard syntax with the addition of the **
, aka super-asterisk, which matches across path boundaries.
Thanks to @gobwas for a fast and easy-to-use Glob library.
This release represents 5 contributions by 1 contributors to the main Hugo code base.
Many have also been busy writing and fixing the documentation in hugoDocs,
which has received 25 contributions by 16 contributors. A special thanks to @bep, @rmetzler, @chris-rudmin, and @stkevintan for their work on the documentation site.
Hugo now has:
- 22689+ stars
- 448+ contributors
- 197+ themes
Notes
Resources.GetByPrefix
andResources.ByPrefix
are depracated. They still work, but will eventually be removed. UseResources.Match
(many) andResources.GetMatch
(one).- When filtering bundles pages in sub-folders, you need to include the sub-folder when matching. This was a bug introduced in
0.33
and gets it in line with images and other resources.
Enhancements
Fixes
- Add validation for
defaultContentLanguage
4d5e4f37 @bep #4298 - Fix lookup of pages bundled in sub-folders in
ByPrefix
etc. 5d030869 @bep #4295
Automated with GoReleaser
Built with go version go1.9.2 linux/amd64
v0.33
Hugo 0.33
is the first main Hugo release of the new year, and it is safe to say that @bep has turned off his lazy Christmas mode 😃
This is a full makeover of the layout selection logic with full custom layout
and type
support (many have asked for this). Also, Hugo now respects the url
value in front matter for all page types, including sections. Also, you can now configure uglyURLs
per section.
But this release is also a follow-up to the 0.32
release which was all about bundles with resources and powerful image processing. With this release it is now simple to add metadata to your images and other bundle resources.
@bep has added a section with examples of both resources
configuration in both YAML
and TOML
front matter in his test site. The example below shows a sample of how it would look like in YAML
:
date: 2017-01-17
title: My Bundle With YAML Resource Metadata
resources:
- src: "image-4.png"
title: "The Fourth Image"
- src: "*.png"
name: "my-cool-image-:counter"
title: "The Image #:counter"
params:
byline: "bep"
This release represents 41 contributions by 3 contributors to the main Hugo code base.
Hugo now has:
- 22553+ stars
- 448+ contributors
- 197+ themes
Notes
- We have re-implemented and unified the template layout lookup logic. This has made it more powerful and much simpler to understand. We don't expect any sites to break because of this. We have tested lots of Hugo sites, including the 200 themes.
- The
indexes
type is removed from template lookup. It's not in the documentation, and is a legacy term inherited from very old Hugo versions. - If you have sub-dirs in your shiny new bundles (e.g.
my-bundle/images
) and use the*Prefix*
methods to find them, we have made an unintended change that affects you. See this issue.
Enhancements
Templates
Core
- Allow
url
in front matter for list type pages 8a409894 @bep #4263 - Improve
.Site.GetPage
for regular translated pages. Before this change it was not possible to say "get me the current language edition of the given content page if possible." Now you can do that by doing a lookup without any extensions:.Site.GetPage "page" "post/mypost"
9409bc0f @bep #4285 - Add front matter metadata to
Resource
20c9b6ec @bep #4244 - Implement
Resources.ByPrefix
46db900d @bep #4266 - Make
GetByPrefix
work for Page resources 60c9f3b1 @bep #4264 - Make
Resources.GetByPrefix
case insensitive db85e834 @bep #4258 - Update
Chroma
and other third-party deps 64f0e9d1 @bep #4267 - Remove superflous
BuildDate
logic 13d53b31 @bep #4272 - Run benchmarks 3 times b6ea6d07 @bep
- Support
uglyURLs
per section 57e10f17 @bep #4256 - Update CONTRIBUTING.md 1046e936 @vassudanagunta
- Support offline builds d5803da1 @vassudanagunta
Fixes
- Fix handling of mixed-case taxonomy folders with content file 2d3189b2 @bep #4238
- Fix handling of very long image file names ecaf1451 @bep #4261
- Update
Afero
to avoid panic on "file name is too long" f8a119b6 @bep #4240 - And now really fix the server watch logic d4f8f88e @bep #4275
- Fix server without watch 4e524ffc @bep #4275
Automated with GoReleaser
Built with go version go1.9.2 linux/amd64
v0.32.4
v0.32.3
Hugo 0.32
was a big and really cool release, and the Hugo Forum has been filled with questions from people wanting to upgrade their Hugo sites to be able to use the new image processing feature etc.
And with that we have discovered some issues, which this release should fix, mostly releated to multilingual sites:
- Fix multihost detection for sites without language definition 8969331f @bep #4221
- Fix hugo benchmark --renderToMemory 059e8458 @bep #4218
- Fix URLs for bundle resources in multihost mode ab82a27d @bep #4217
- Fix sub-folder baseURL handling for Page resources f25d8a9e @bep #4228
- Avoid processing and storing same image for each language 4b04db0f @bep #4231
- Resources.ByType should return Resources 97c1866e @bep #4234
- Report build time on config.toml change 6feb1387 @bep #4232#4224
- Fix handling of mixed-case taxonomy folders with content file 2d3189b2 @bep #4238
Automated with GoReleaser
Built with go version go1.9.2 linux/amd64
v0.32.2
This is a bug-fix release with one important fix.
- Handle publish of processed images to /public on fresh build with no image cache in /resources (as reported by one person in a Netlify build) 196da49c @bep #4213
Automated with GoReleaser
Built with go version go1.9.2 linux/amd64
v0.32.1
This fixes 2 bugs from the Hugo 0.32 release.
- Fix image processing from shortcodes in non-server mode. @bep #4202
- Fix broken
hugo --renderToMemory
. Note that this is only useful for benchmark testing, as there is no easy way to actually view the result. d36d71ed @bep #4212
Automated with GoReleaser
Built with go version go1.9.2 linux/amd64
v0.32
Hugo 0.32
features Page Bundles and Image Processing by @bep, which is very cool and useful on so many levels. Read about it in more detail in the Hugo documentation, but some of the highlights include:
- Automatic bundling of a content page with its resources. Resources can be anything: Images,
JSON
files ... and also other content pages. - A
Resource
will have itsRelPermalink
andPermalink
relative to the "owning page". This makes the complete article with both text and images portable (just send a ZIP file with a folder to your editor), and it can be previewed directly on GitHub. - Powerful and simple to use image processing with the new
.Resize
,.Fill
, and.Fit
methods on the newImage
resource. - Full support for symbolic links inside
/content
, both for regular files and directories.
The built-in benchmarks in Hugo show that this is also the fastest and most memory effective Hugo version to date. But note that the build time total reported in the console is now adjusted to be the real total, including the copy of static files. So, if it reports more milliseconds, it is still most likely faster ...
This release represents 30 contributions by 7 contributors to the main Hugo code base.
@bep leads the Hugo development with a significant amount of contributions, but also a big shoutout to @betaveros, @chaseadamsio, and @kropp. And as always big thanks to @digitalcraftsman for his relentless work on keeping the documentation and the themes site in pristine condition.
Many have also been busy writing and fixing the documentation in hugoDocs,
which has received 17 contributions by 7 contributors. A special thanks to @bep, @felicianotech, @maiki, and @carlchengli for their work on the documentation site.
Hugo now has:
- 22061+ stars
- 454+ contributors
- 193+ themes
Today is New Year's Eve. It is the last day of 2017, a year that have seen a string of pearls of Hugo releases, making Hugo the top choice for website development:
- 0.32, December 2017: Page Bundles and Image Processing edition.
- 0.31, November 2017: The Language Multihost Edition! with one
baseURL
per language. - 0.30, October 2017: The Race Car Edition with the Fast Render Mode.
- 0.29, September 2017: Added Template Metrics.
- 0.28, September 2017: Blistering fast and native syntax highlighting from Chroma.
- 0.27, September 2017: Fast and flexible Related Content.
- 0.26, August 2017: The Language Style Edition with AP Style or Chicago Style Title Case and « French Guillemets ».
- 0.25, July 2017: The Kinder Surprise edition added, among other cool things,
hugo server --navigateToChanged
which navigates to the content page you start editing. - 0.24, June 2017: Was The Revival of the Archetypes! Now archetype files, i.e. the content file templates, can include template syntax with all of Hugo's functions and variables.
- 0.23, June 2017: Hugo moved to it's own GitHub organization, gohugoio.
- 0.22, June 2017: Added nested sections, a long sought after feature.
- 0.21, May 2017: Full support for shortcodes per output format (think AMP).
- 0.20, April 2017: Was all about Custom Output Formats.
- 0.19, February 2017: Native Emacs Org-mode content support and lots of internal upgrades.
Notes
- The build total in the console is now the ... total (i.e. it now includes both the copy of the static files and the Hugo build). So if your Hugo site seems to build slightly slower, it is in reality probably slightly faster than before this release.
- Images and other static resources in folders with "_index.md" will have its
RelPermalink
relative to its page. - Images and other static resources in or below "index.md" folders will have its
RelPermalink
relative to its page (respecting permalink settings etc.) - Content pages in or below "index.md" will not get their own
URL
, but will be part of the.Resources
collection of its page. .Site.Files
is deprecated.- Hugo no longer minfies CSS files inside
/content
. This was an undocumented "proof of concept feature". We may revisit the "assets handling" in a future release. Page.GetParam
does not lowercase your result anymore. If you really want to lowercase your params, do it with.GetParam "myparam" | lower
or similar.
Previously deprecated that will now ERROR
:
disable404
: UsedisableKinds=["404"]
disableRSS
: UsedisableKinds=["RSS"]
disableSitemap
: UsedisableKinds=["sitemap"]
disableRobotsTXT
: UsedisableKinds=["robotsTXT"]
Enhancements
- Add
.Title
and.Page
toMenuEntry
9df3736f @rmetzler #2784 - Add
Pandoc
support e69da7a4 @betaveros #234 - Implement Page bundling and image handling 3cdf19e9 @bep #3651#3158#1014#2021#1240#3757
- Make
chomp
return the type it receives 22cd89ad @kropp #2187 - Reuse the
BlackFriday
config instance when possible db4b7a5c @bep - Remove the goroutines from the shortcode lexer 24369410 @bep
- Improve site benchmarks 051fa343 @bep
- Update
Chroma
tov0.2.0
79892101 @bep #4087 - Update
goorgeous
tov1.1.0
7f2ae3ef @chaseadamsio - Add test for homepage content for all rendering engines 407c2402 @bep #4166
- Add output formats definition to benchmarks a2d81ce9 @bep
Fixes
Templates
- Do not unescape input to
highlight
c067f345 @bep #4179 - Properly close image file in
imageConfig
6d79beb5 @bep - Fix
opengraph
video range template 23f69efb @drlogout #4136 - Fix
humanize
for multi-byte runes e7652180 @bep #4133
Other
- Fix broken live reload without a server port. 25114986 @sainaen #4141
- Make sure all language homes are always re-rendered in fast render mode 72903be5 @bep #4125
- Do not
tolower
result from Page.GetParam 1c114d53 @bep #4187
Automated with GoReleaser
Built with go version go1.9.2 linux/amd64