Zach Bayoff [Sat, 12 Oct 2019 16:10:14 +0000 (12:10 -0400)]
tpl: Add optional "title" attribute to iframe in Vimeo shortcode
Add an optional "title" attribute to the iframe in the vimeo shortcode. If one is not given, the title attribute will default to "vimeo video". It is imperative for iframes to have a non-empty "title" attribute in order to meet WCAG2.0 accessibility guidelines https://www.w3.org/TR/WCAG20-TECHS/H64.
Baibhav Vatsa [Fri, 11 Oct 2019 18:51:24 +0000 (13:51 -0500)]
tpl: Modify error messages of after, first, and last
Modified the messages functions after, first, and last threw on being passed invalid parameters (index or limit) to be more standardised and resemble what Go compiler would throw.
Fixes #6415
Baibhav Vatsa [Fri, 11 Oct 2019 18:15:39 +0000 (13:15 -0500)]
tpl: Last now accepts 0 as limit
Modified the if conditional because of which last threw an error if 0 was passed as limit. The function now returns an empty slice if it is called with 0 as limit. The behavior of first and last is now the same when 0 is passed as limit. Also added tests to test the new behavior.
Fixes #6419
Bjørn Erik Pedersen [Fri, 11 Oct 2019 14:43:00 +0000 (16:43 +0200)]
Update feature_request.md
Vazrupe (HyeonGyu Lee) [Wed, 9 Oct 2019 09:36:25 +0000 (18:36 +0900)]
common: Fix elements are doubling when append a not assignable type
Fixes #6188
Baibhav Vatsa [Fri, 11 Oct 2019 01:16:15 +0000 (20:16 -0500)]
tpl: After now accepts 0 as index
Modified the if conditional because of which after threw an error if called with 0 as index. The function now returns the whole original slice if 0 is passed as an index. Also added tests to test the new behavior.
Fixes #6388
Bjørn Erik Pedersen [Thu, 10 Oct 2019 12:14:55 +0000 (14:14 +0200)]
helpers: Fix data race in global logger init
Fixes #6409
Bjørn Erik Pedersen [Thu, 10 Oct 2019 08:18:30 +0000 (10:18 +0200)]
tpl: Make getJSON/getCVS accept non-string args
This broke for the Twitter simple shortcode now that Shortcodes accepts typed arguments.
Fixes #6382
Bjørn Erik Pedersen [Wed, 9 Oct 2019 17:57:05 +0000 (19:57 +0200)]
Update to Go 1.12.10 and 1.13.1
Fixes #6406
Bjørn Erik Pedersen [Wed, 9 Oct 2019 08:49:52 +0000 (10:49 +0200)]
Simplify test output to simplify diffing
Bjørn Erik Pedersen [Wed, 9 Oct 2019 08:30:09 +0000 (10:30 +0200)]
hugofs: Add FileMeta.String
To make the page listing easier to compare.
Anthony Fok [Wed, 9 Oct 2019 05:46:04 +0000 (23:46 -0600)]
deps: Update minify to v2.5.2
- v2.5.1 removes import comments, solving a build error with Go 1.13
in GOPATH mode (used Debian packaging for example)
- v2.5.2 no longer converts polyline/rect/polygon/line to path
as it has been reported to break a SVG referenced by CSS,
see tdewolff/minify#260
The test case for Min SVG in TestResourceChains is updated accordingly.
Fixes pocc/tshark.dev#33
Anthony Fok [Mon, 7 Oct 2019 18:35:00 +0000 (12:35 -0600)]
resources: Fix image test error on s390x, ppc64* and arm64
In TestImageOperationsGolden, tolerate slight floating-point rounding
differences due to the use or non-use of "fused multiply and add" (FMA)
instruction on different architectures.
Special thanks to @disintegration for the solution in goldenEqual();
see https://github.com/disintegration/gift/issues/20
Fixes #6387
Niklas Fasching [Thu, 3 Oct 2019 21:27:51 +0000 (23:27 +0200)]
Add BaseFs to RenderingContext
The org mode renderer supports including other files [1]. We don't want to
allow reading of arbitrary files (go-org defaults to ioutil.ReadFile [2]) but want
to make use of the FileSystem abstractions hugo provides. For starters we will
allow reading from the content directory only
[1]: e.g. `#+INCLUDE: ./foo.py src python` includes `foo.py` as a python source
block.
Niklas Fasching [Tue, 1 Oct 2019 21:37:47 +0000 (23:37 +0200)]
deps: Update go-org
- add support for latex fragments
- allow customization of ReadFile method for includes (#+INCLUDE: ...)
Bjørn Erik Pedersen [Sun, 6 Oct 2019 19:22:10 +0000 (21:22 +0200)]
media: Use + to create the Type string
Jamie Tanna [Sat, 5 Oct 2019 18:08:45 +0000 (19:08 +0100)]
deps: Upgrade to latest version of emoji dependency
To add support for new emojis in Hugo, we need to upgrade our internal
dependency on the emoji package.
Note that we also need to update our tests, as the underlying emoji that
is rendered has changed.
Follow-up to #6391. (
170f18d9352d39213170dd9d5e947eb45854c84b and
2df5d202c6fc6eb18ee0b259c3dd1156094947c5)
Bjørn Erik Pedersen [Sat, 5 Oct 2019 17:25:25 +0000 (19:25 +0200)]
Revert "deps: Upgrade to latest version of emoji dependency"
This reverts commit
170f18d9352d39213170dd9d5e947eb45854c84b.
Jamie Tanna [Sat, 5 Oct 2019 16:27:32 +0000 (17:27 +0100)]
deps: Upgrade to latest version of emoji dependency
To add support for new emojis in Hugo, we need to upgrade our internal
dependency on the emoji package.
Bjørn Erik Pedersen [Fri, 4 Oct 2019 18:55:10 +0000 (20:55 +0200)]
readme: Update Architectures
Garret Kelly [Thu, 3 Oct 2019 12:46:27 +0000 (08:46 -0400)]
deploy: Add ability to invalidate Google Cloud CDN
Anthony Fok [Thu, 3 Oct 2019 05:40:22 +0000 (23:40 -0600)]
resources: Ensure same dirinfos sort order in TestImageOperationsGolden
Fix filename mismatch errors on Debian auto-building machines
possibly due to different directory order on ext4 vs tmpfs file systems.
Bjørn Erik Pedersen [Mon, 30 Sep 2019 18:09:49 +0000 (20:09 +0200)]
Update bug_report.md
Bjørn Erik Pedersen [Sun, 29 Sep 2019 12:51:51 +0000 (14:51 +0200)]
Support typed bool, int and float in shortcode params
This means that you now can do:
{{< vidur 9KvBeKu false true 32 3.14 >}}
And the boolean and numeric values will be converted to `bool`, `int` and `float64`.
If you want these to be strings, they must be quoted:
{{< vidur 9KvBeKu "false" "true" "32" "3.14" >}}
Fixes #6371
Bjørn Erik Pedersen [Wed, 25 Sep 2019 06:42:15 +0000 (08:42 +0200)]
deps: Update Chroma
Closes #6279
Brian MacKinney [Wed, 25 Sep 2019 06:40:04 +0000 (23:40 -0700)]
github: Add issue templates and action
J. Ansorg [Sat, 21 Sep 2019 14:50:27 +0000 (16:50 +0200)]
resources: Support output image format in image operations
The image format is defined as the image extension of the known formats,
excluding the dot.
All of 'img.Resize "600x jpeg"', 'img.Resize "600x jpg"',
and 'img.Resize "600x png"' are valid format definitions.
If the target format is defined in the operation definition string,
then the converted image will be stored in this format. Permalinks and
media type are updated correspondingly.
Unknown image extensions in the operation definition have not effect.
See #6298
XhmikosR [Sat, 21 Sep 2019 08:08:47 +0000 (11:08 +0300)]
tpl: Add `rel="noopener"` for external links
This could be a security and performance issue.
See https://developers.google.com/web/tools/lighthouse/audits/noopener
XhmikosR [Sat, 21 Sep 2019 08:06:15 +0000 (11:06 +0300)]
tpl: Remove unneeded space
hugoreleaser [Thu, 19 Sep 2019 15:36:35 +0000 (15:36 +0000)]
releaser: Prepare repository for 0.59.0-DEV
[ci skip]
hugoreleaser [Thu, 19 Sep 2019 15:28:26 +0000 (15:28 +0000)]
releaser: Add release notes to /docs for release of 0.58.3
[ci skip]
hugoreleaser [Thu, 19 Sep 2019 15:28:26 +0000 (15:28 +0000)]
releaser: Bump versions for release of 0.58.3
[ci skip]
hugoreleaser [Thu, 19 Sep 2019 15:28:26 +0000 (15:28 +0000)]
releaser: Add release notes for 0.58.3
[ci skip]
Bjørn Erik Pedersen [Thu, 19 Sep 2019 14:58:14 +0000 (16:58 +0200)]
Add some more resource transform tests
See #6348
Bjørn Erik Pedersen [Thu, 19 Sep 2019 08:12:29 +0000 (10:12 +0200)]
Fix cache key transformed resources
Fixes #6348
Fazal Majid [Fri, 13 Sep 2019 12:53:36 +0000 (05:53 -0700)]
deploy: Do not compile in Azure on Solaris
See #6324
hugoreleaser [Fri, 13 Sep 2019 08:12:38 +0000 (08:12 +0000)]
releaser: Prepare repository for 0.59.0-DEV
[ci skip]
hugoreleaser [Fri, 13 Sep 2019 08:04:20 +0000 (08:04 +0000)]
releaser: Add release notes to /docs for release of 0.58.2
[ci skip]
hugoreleaser [Fri, 13 Sep 2019 08:04:20 +0000 (08:04 +0000)]
releaser: Bump versions for release of 0.58.2
[ci skip]
hugoreleaser [Fri, 13 Sep 2019 08:04:20 +0000 (08:04 +0000)]
releaser: Add release notes for 0.58.2
[ci skip]
Bjørn Erik Pedersen [Thu, 12 Sep 2019 17:53:31 +0000 (19:53 +0200)]
Fix cache keys for bundled resoures in transform.Unmarshal
Fixes #6327
Bjørn Erik Pedersen [Thu, 12 Sep 2019 15:24:34 +0000 (17:24 +0200)]
filecache: Ignore "does not exist" errors in prune
Fixes #6326
Fixes #5745
hugoreleaser [Fri, 6 Sep 2019 09:26:46 +0000 (09:26 +0000)]
releaser: Prepare repository for 0.59.0-DEV
[ci skip]
hugoreleaser [Fri, 6 Sep 2019 09:18:56 +0000 (09:18 +0000)]
releaser: Add release notes to /docs for release of 0.58.1
[ci skip]
hugoreleaser [Fri, 6 Sep 2019 09:18:56 +0000 (09:18 +0000)]
releaser: Bump versions for release of 0.58.1
[ci skip]
hugoreleaser [Fri, 6 Sep 2019 09:18:56 +0000 (09:18 +0000)]
releaser: Add release notes for 0.58.1
[ci skip]
Bjørn Erik Pedersen [Fri, 6 Sep 2019 07:28:43 +0000 (09:28 +0200)]
Avoid writing the same processed image to /public twice
Fixes #6307
Bjørn Erik Pedersen [Fri, 6 Sep 2019 09:03:23 +0000 (11:03 +0200)]
hugolib: Fix broken bundle live reload logic
Fixes #6315
Updates #6308
Bjørn Erik Pedersen [Fri, 6 Sep 2019 08:39:21 +0000 (10:39 +0200)]
deps: Update github.com/bep/gitmap
Fixes #6313
Bjørn Erik Pedersen [Thu, 5 Sep 2019 16:03:00 +0000 (18:03 +0200)]
Fix concat with fingerprint regression
In Hugo 0.58 we optimized the transformers that only adjusted metadata, e.g. the fingerprint.
This depended on the source readers implementing `io.ReadSeeker`.
The reader produced by `concat` did that, but the implementation was buggy.
This commit fixes that.
Fixes #6309
Vazrupe (HyeonGyu Lee) [Tue, 3 Sep 2019 12:20:20 +0000 (21:20 +0900)]
tpl: Remove eq argument limitation
Fixes #6237
hugoreleaser [Wed, 4 Sep 2019 15:51:16 +0000 (15:51 +0000)]
releaser: Prepare repository for 0.59.0-DEV
[ci skip]
hugoreleaser [Wed, 4 Sep 2019 15:41:58 +0000 (15:41 +0000)]
releaser: Add release notes to /docs for release of 0.58.0
[ci skip]
hugoreleaser [Wed, 4 Sep 2019 15:41:58 +0000 (15:41 +0000)]
releaser: Bump versions for release of 0.58.0
[ci skip]
Bjørn Erik Pedersen [Wed, 4 Sep 2019 15:33:42 +0000 (17:33 +0200)]
Release 0.58.0
Bjørn Erik Pedersen [Wed, 4 Sep 2019 12:07:10 +0000 (14:07 +0200)]
Allow slices in the image Filter funcs, not just varargs
[ci skip]
See #6255
Bjørn Erik Pedersen [Wed, 4 Sep 2019 11:05:50 +0000 (13:05 +0200)]
Update 0.58.0-relnotes.md
[ci skip]
hugoreleaser [Wed, 4 Sep 2019 10:39:05 +0000 (10:39 +0000)]
releaser: Add release notes for 0.58.0
Rename to *-ready.md to continue.
[ci skip]
Bjørn Erik Pedersen [Wed, 4 Sep 2019 07:50:32 +0000 (09:50 +0200)]
hugolib: Adjust Go version specific test
See #6304
Bjørn Erik Pedersen [Tue, 3 Sep 2019 22:54:41 +0000 (00:54 +0200)]
Update to Go 1.13
Fixes #6304
Bjørn Erik Pedersen [Tue, 3 Sep 2019 19:36:28 +0000 (21:36 +0200)]
hugolib: Remove the old and slow site benchmarks
Bjørn Erik Pedersen [Tue, 3 Sep 2019 08:36:09 +0000 (10:36 +0200)]
Cache processed images by their source path
Fixes #6269
Bjørn Erik Pedersen [Tue, 3 Sep 2019 15:18:18 +0000 (17:18 +0200)]
Remove test artifact
Bjørn Erik Pedersen [Tue, 3 Sep 2019 10:58:02 +0000 (12:58 +0200)]
Make the "is this a Hugo Module" logic more lenient
Now we only try to load modules via Go if there is one or more modules imported in project config.
Fixes #6299
Bjørn Erik Pedersen [Tue, 3 Sep 2019 10:25:41 +0000 (12:25 +0200)]
hugolib: Add a Sass includePaths test
See #6274
Bjørn Erik Pedersen [Tue, 3 Sep 2019 08:04:06 +0000 (10:04 +0200)]
Update to Go 1.11.13 and 1.12.9
Fixes #6228
Bjørn Erik Pedersen [Mon, 2 Sep 2019 15:34:02 +0000 (17:34 +0200)]
Make home.Pages work like any other section
Fixes #6240
Bjørn Erik Pedersen [Mon, 2 Sep 2019 15:09:56 +0000 (17:09 +0200)]
Add some fingerprint tests
Closes #6284
Closes #6280
Bjørn Erik Pedersen [Sun, 1 Sep 2019 15:27:21 +0000 (17:27 +0200)]
resources: Cache Exif data to disk
```bash
name old time/op new time/op delta
ImageExif/Cold_cache-4 312µs ±28% 355µs ± 7% ~ (p=0.343 n=4+4)
ImageExif/Cold_cache,_10-4 479µs ± 6% 546µs ± 0% +13.91% (p=0.029 n=4+4)
ImageExif/Warm_cache-4 272µs ± 1% 81µs ± 5% -70.30% (p=0.029 n=4+4)
name old alloc/op new alloc/op delta
ImageExif/Cold_cache-4 151kB ± 0% 161kB ± 0% +6.46% (p=0.029 n=4+4)
ImageExif/Cold_cache,_10-4 179kB ± 0% 189kB ± 0% +5.49% (p=0.029 n=4+4)
ImageExif/Warm_cache-4 151kB ± 0% 13kB ± 0% -91.52% (p=0.029 n=4+4)
name old allocs/op new allocs/op delta
ImageExif/Cold_cache-4 1.03k ± 0% 1.21k ± 0% +17.78% (p=0.029 n=4+4)
ImageExif/Cold_cache,_10-4 1.65k ± 0% 1.83k ± 0% +11.09% (p=0.029 n=4+4)
ImageExif/Warm_cache-4 1.03k ± 0% 0.28k ± 0% -72.40% (p=0.029 n=4+4)
```
Fixes #6291
Bjørn Erik Pedersen [Sun, 1 Sep 2019 21:48:51 +0000 (23:48 +0200)]
Remove metaDataFormat setting
Not in use anymore.
Bjørn Erik Pedersen [Sun, 1 Sep 2019 20:05:39 +0000 (22:05 +0200)]
resources: Make the Exif benchmark filenames distinct
Bjørn Erik Pedersen [Sun, 1 Sep 2019 15:57:35 +0000 (17:57 +0200)]
resources: Add Exif benchmark
See #6291
Bjørn Erik Pedersen [Sat, 31 Aug 2019 19:30:13 +0000 (21:30 +0200)]
resources: Remove unused map type
Bjørn Erik Pedersen [Thu, 29 Aug 2019 08:18:51 +0000 (10:18 +0200)]
Add image.Exif
Note that we will probably need to add some metadata cache for this to scale.
Fixes #4600
Niklas Fasching [Sat, 31 Aug 2019 11:15:08 +0000 (13:15 +0200)]
deps: Update go-org (fix descriptive lists)
</dt> and </dd> closing tags were broken, see
https://github.com/niklasfasching/go-org/pull/9
Jake Jarvis [Thu, 29 Aug 2019 15:27:14 +0000 (11:27 -0400)]
tpl: Migrate last shortcodes (YouTube and Vimeo) to HTTPS embeds
Bjørn Erik Pedersen [Mon, 26 Aug 2019 17:12:41 +0000 (19:12 +0200)]
Add a set of image filters
With this you can do variants of this:
```
{{ $img := resources.Get "images/misc/3-jenny.jpg" }}
{{ $img := $img.Resize "300x" }}
{{ $g1 := $img.Filter images.Grayscale }}
{{ $g2 := $img | images.Filter (images.Saturate 30) (images.GaussianBlur 3) }}
```
Fixes #6255
Bjørn Erik Pedersen [Sun, 18 Aug 2019 09:21:27 +0000 (11:21 +0200)]
Image resource refactor
This commit pulls most of the image related logic into its own package, to make it easier to reason about and extend.
This is also a rewrite of the transformation logic used in Hugo Pipes, mostly to allow constructs like the one below:
{{ ($myimg | fingerprint ).Width }}
Fixes #5903
Fixes #6234
Fixes #6266
Niklas Fasching [Sat, 24 Aug 2019 10:20:40 +0000 (12:20 +0200)]
deps: Update go-org (fix footnotes in headlines)
Christian Oliff [Fri, 23 Aug 2019 15:21:37 +0000 (00:21 +0900)]
Discrepancy typo fix
Bjørn Erik Pedersen [Fri, 23 Aug 2019 05:37:56 +0000 (07:37 +0200)]
source: Remove debug check left during development
Fixes #6249
Vazrupe (HyeonGyu Lee) [Mon, 19 Aug 2019 14:26:53 +0000 (23:26 +0900)]
hugolib: Change to output non-panic error message if missing shortcode template
A panic occurred when the `nested` variable was nil.
Changed to check if the `nested` variable is nil.
Fixes #6075
hugoreleaser [Sat, 17 Aug 2019 17:59:28 +0000 (17:59 +0000)]
releaser: Prepare repository for 0.58.0-DEV
[ci skip]
hugoreleaser [Sat, 17 Aug 2019 17:51:54 +0000 (17:51 +0000)]
releaser: Add release notes to /docs for release of 0.57.2
[ci skip]
hugoreleaser [Sat, 17 Aug 2019 17:51:54 +0000 (17:51 +0000)]
releaser: Bump versions for release of 0.57.2
[ci skip]
hugoreleaser [Sat, 17 Aug 2019 17:51:54 +0000 (17:51 +0000)]
releaser: Add release notes for 0.57.2
[ci skip]
Bjørn Erik Pedersen [Sat, 17 Aug 2019 17:38:12 +0000 (19:38 +0200)]
Revert "Update to Go 1.11.13 and 1.12.9"
This reverts commit
f28efd35820dc4909832c14dfd8ea6812ecead31.
Bjørn Erik Pedersen [Sat, 17 Aug 2019 17:37:14 +0000 (19:37 +0200)]
tpl: Use RegularPages for RSS template
This is in line with how it was in Hugo 0.56.
See #6238
Bjørn Erik Pedersen [Sat, 17 Aug 2019 15:13:33 +0000 (17:13 +0200)]
hugolib: Don't use the global warning logger
See #6238
Bjørn Erik Pedersen [Sat, 17 Aug 2019 15:11:41 +0000 (17:11 +0200)]
tpl: Avoid "home page warning" in RSS template
See #6238
Bjørn Erik Pedersen [Sat, 17 Aug 2019 14:22:24 +0000 (16:22 +0200)]
hugolib: Allow index.md inside bundles
Fixes #6208
Bjørn Erik Pedersen [Sat, 17 Aug 2019 11:08:03 +0000 (13:08 +0200)]
Adjust the default paginator for sections
To make it in line with 0.56 for sections; only paginate regular pages.
Fixes #6231
Bjørn Erik Pedersen [Sat, 17 Aug 2019 10:59:41 +0000 (12:59 +0200)]
Revert the 0.57 home.Pages change
In 0.57 we change the behaviour of home.Pages to be in line with the other sections. This has created a lot noise and breakage in the wild.
This commit reverts that change, but adds a warning that we will change this in 0.58 and that you should consider using .Site.RegularPages if that is what you want.
Bjørn Erik Pedersen [Fri, 16 Aug 2019 14:21:03 +0000 (16:21 +0200)]
hugolib: Add a site benchmark
Bjørn Erik Pedersen [Fri, 16 Aug 2019 08:46:34 +0000 (10:46 +0200)]
Update to Go 1.11.13 and 1.12.9
Fixes #6228
hugoreleaser [Thu, 15 Aug 2019 19:00:12 +0000 (19:00 +0000)]
releaser: Prepare repository for 0.58.0-DEV
[ci skip]
hugoreleaser [Thu, 15 Aug 2019 18:52:49 +0000 (18:52 +0000)]
releaser: Add release notes to /docs for release of 0.57.1
[ci skip]
hugoreleaser [Thu, 15 Aug 2019 18:52:49 +0000 (18:52 +0000)]
releaser: Bump versions for release of 0.57.1
[ci skip]
hugoreleaser [Thu, 15 Aug 2019 18:52:49 +0000 (18:52 +0000)]
releaser: Add release notes for 0.57.1
[ci skip]
Bjørn Erik Pedersen [Thu, 15 Aug 2019 16:25:21 +0000 (18:25 +0200)]
hugolib: Fix draft etc. handling of _index.md pages
We will need to revisit this with a proper spec, but this commit makes sure that draft/expiryDate etc. set in front matter on _index.md content files that should disable the page will:
* Not crash
* Make the rendered page not render any `.Content`.
Fixes #6222
Fixes #6210