Bjørn Erik Pedersen
79aa2ab618
deps: Upgrade golang.org/x/tools v0.21.1-0.20240508182429-e35e4ccd0d2d => v0.23.0
...
Main motivation is to try to get dependabot running again.
2024-07-31 18:52:13 +02:00
Bjørn Erik Pedersen
216a69a1ef
Shorten processed image filenames
...
Fixes #12688
Fixes #12656
2024-07-31 16:44:06 +02:00
Bjørn Erik Pedersen
e67886c038
Consolidate all hashing to the common/hashing package
...
And remove now unsued hashing funcs.
2024-07-31 16:44:06 +02:00
Bjørn Erik Pedersen
d5eda13cb2
Replace the MD5 hashing of images with xxHash
...
Note that we only use this for change detection.
The previous implementation invoked `MD5FromReaderFast` that created a MD5 has from 8 64 bytes chunks in the file, which is obviously very fast. The new implementation creates the hash from the entire file and ... seems to be even more effective:
```
name old time/op new time/op delta
HashImage-10 9.45µs ±21% 10.89µs ± 1% ~ (p=0.343 n=4+4)
name old alloc/op new alloc/op delta
HashImage-10 144B ± 0% 8B ± 0% -94.44% (p=0.029 n=4+4)
name old allocs/op new allocs/op delta
HashImage-10 4.00 ± 0% 1.00 ± 0% -75.00% (p=0.029 n=4+4)
```
2024-07-31 16:44:06 +02:00
Bjørn Erik Pedersen
8b5d796989
resources: Add BenchmarkHashImage
2024-07-31 16:44:06 +02:00
Bjørn Erik Pedersen
c9d7577cb4
deps: Replace github.com/mitchellh/hashstructure/v2 with github.com/gohugoio/hashstructure
...
The old repo is archived and no longer maintained.
See #11644
2024-07-31 16:44:06 +02:00
Bjørn Erik Pedersen
2babd6404e
identity: Use xxHash in hashstructure (note)
...
```
name old time/op new time/op delta
HashString/n28-10 133ns ± 9% 107ns ±10% -19.58% (p=0.029 n=4+4)
HashString/n112-10 243ns ± 5% 121ns ± 4% -50.08% (p=0.029 n=4+4)
HashString/n448-10 698ns ± 3% 174ns ± 5% -75.02% (p=0.029 n=4+4)
HashString/n1792-10 2.58µs ± 4% 0.38µs ± 4% -85.11% (p=0.029 n=4+4)
HashString/n7168-10 10.0µs ± 3% 1.3µs ± 4% -86.91% (p=0.029 n=4+4)
name old alloc/op new alloc/op delta
HashString/n28-10 80.0B ± 0% 72.0B ± 0% -10.00% (p=0.029 n=4+4)
HashString/n112-10 160B ± 0% 152B ± 0% -5.00% (p=0.029 n=4+4)
HashString/n448-10 496B ± 0% 488B ± 0% -1.61% (p=0.029 n=4+4)
HashString/n1792-10 1.84kB ± 0% 1.83kB ± 0% -0.43% (p=0.029 n=4+4)
HashString/n7168-10 8.24kB ± 0% 8.23kB ± 0% -0.06% (p=0.029 n=4+4)
name old allocs/op new allocs/op delta
HashString/n28-10 4.00 ± 0% 3.00 ± 0% -25.00% (p=0.029 n=4+4)
HashString/n112-10 4.00 ± 0% 3.00 ± 0% -25.00% (p=0.029 n=4+4)
HashString/n448-10 4.00 ± 0% 3.00 ± 0% -25.00% (p=0.029 n=4+4)
HashString/n1792-10 4.00 ± 0% 3.00 ± 0% -25.00% (p=0.029 n=4+4)
HashString/n7168-10 4.00 ± 0% 3.00 ± 0% -25.00% (p=0.029 n=4+4)
```
2024-07-31 16:44:06 +02:00
Bjørn Erik Pedersen
78db8aebca
identity: Upgrade to github.com/mitchellh/hashstructure/v2 v2.0.2
...
```
name old time/op new time/op delta
HashString/n28-10 131ns ± 7% 133ns ±19% ~ (p=0.343 n=4+4)
HashString/n112-10 237ns ± 5% 241ns ± 3% ~ (p=0.229 n=4+4)
HashString/n448-10 688ns ± 3% 687ns ± 1% ~ (p=0.886 n=4+4)
HashString/n1792-10 2.51µs ± 3% 2.56µs ± 3% ~ (p=0.200 n=4+4)
HashString/n7168-10 10.1µs ± 2% 10.0µs ± 4% ~ (p=0.686 n=4+4)
name old alloc/op new alloc/op delta
HashString/n28-10 80.0B ± 0% 80.0B ± 0% ~ (all equal)
HashString/n112-10 160B ± 0% 160B ± 0% ~ (all equal)
HashString/n448-10 496B ± 0% 496B ± 0% ~ (all equal)
HashString/n1792-10 1.84kB ± 0% 1.84kB ± 0% ~ (all equal)
HashString/n7168-10 8.24kB ± 0% 8.24kB ± 0% ~ (all equal)
name old allocs/op new allocs/op delta
HashString/n28-10 4.00 ± 0% 4.00 ± 0% ~ (all equal)
HashString/n112-10 4.00 ± 0% 4.00 ± 0% ~ (all equal)
HashString/n448-10 4.00 ± 0% 4.00 ± 0% ~ (all equal)
HashString/n1792-10 4.00 ± 0% 4.00 ± 0% ~ (all equal)
HashString/n7168-10 4.00 ± 0% 4.00 ± 0% ~ (all equal)
```
Closes #11644
2024-07-31 16:44:06 +02:00
Bjørn Erik Pedersen
3140e0b994
identity: Add BenchmarkHashString
2024-07-31 16:44:06 +02:00
Bjørn Erik Pedersen
9989404d97
deps: Upgrade github.com/bep/imagemeta v0.7.4 => v0.7.5
2024-07-31 15:35:18 +02:00
Bjørn Erik Pedersen
b81ba2a0f0
deps: Upgrade github.com/aws/aws-sdk-go-v2 v1.26.1 => v1.30.3
2024-07-31 14:22:20 +02:00
Bjørn Erik Pedersen
afdd87db59
deps: Upgrade to github.com/Azure/azure-sdk-for-go/sdk/azidentity v1.7.0
2024-07-31 12:53:27 +02:00
hugoreleaser
e45eae4d67
releaser: Prepare repository for 0.131.0-DEV
...
[ci skip]
2024-07-29 14:06:20 +00:00
hugoreleaser
9b1b11c8a5
releaser: Bump versions for release of 0.130.0
...
[ci skip]
2024-07-29 13:51:56 +00:00
raoulb
9d2b5f98d0
math: Add trigonometric functions and some angle helper functions
...
This commit adds these new template functions in the `math` namespace:
math.Acos
math.Asin
math.Atan
math.Atan2
math.Cos
math.Pi
math.Sin
math.Tan
math.ToDegrees
math.ToRadians
Co-authored-by: Joe Mooring <joe@mooring.com>
2024-07-29 11:05:36 +02:00
Bjørn Erik Pedersen
0e00561620
deps: Upgrade github.com/bep/imagemeta v0.7.3 => v0.7.4
2024-07-23 20:46:05 +02:00
Bjørn Erik Pedersen
71842140d0
deps: Upgrade github.com/bep/imagemeta v0.7.1 => v0.7.3
2024-07-21 21:44:48 +02:00
Bjørn Erik Pedersen
cb95a033c1
readme: Pull the star history down a little
2024-07-20 17:46:48 +02:00
Bjørn Erik Pedersen
3240511153
deps: Upgraded github.com/bep/imagemeta v0.7.0 => v0.7.1
...
Fixes #12669
2024-07-20 17:28:47 +02:00
Bjørn Erik Pedersen
72ff937e11
Switch EXIF library
...
Closes #10855
Closes #8586
Closes #8996
2024-07-20 15:56:10 +02:00
Bjørn Erik Pedersen
a28bed0817
readme: Add Star History
2024-07-20 15:37:22 +02:00
hugoreleaser
979423f4d5
releaser: Prepare repository for 0.130.0-DEV
...
[ci skip]
2024-07-17 13:42:58 +00:00
hugoreleaser
e85be29867
releaser: Bump versions for release of 0.129.0
...
[ci skip]
2024-07-17 13:29:16 +00:00
Bjørn Erik Pedersen
4d8bfa7f1c
tpl: Use xxHash instead of MD5 to hash the deferred templates
...
Motivation is performance. These templates are typically very small, so the win is minor, I guess.
2024-07-17 12:51:49 +02:00
Bjørn Erik Pedersen
f0ed91caba
Throw error if resources.PostProcess is used in a deferred template
...
That just doesn't work.
See #12655
2024-07-17 12:47:25 +02:00
Bjørn Erik Pedersen
7be0377505
deps: Upgrade github.com/bep/gitmap v1.4.0 => v1.6.0 (note)
...
Closes #8627
2024-07-17 10:54:28 +02:00
Bjørn Erik Pedersen
439f07eac4
deps: Go mod tidy
2024-07-08 23:53:23 +02:00
Bjørn Erik Pedersen
ce5a2ce001
deps: Upgraded github.com/tdewolff/minify/v2 v2.20.20 => v2.20.36
2024-07-08 23:53:23 +02:00
Bjørn Erik Pedersen
0f42d975e0
deps: Upgrade to golang.org/x/image v0.18.0
2024-07-08 23:53:23 +02:00
Bjørn Erik Pedersen
cc2d19e19b
commands: Fix --navigateToChanged server behavior when editing headless content
...
Fixes #12648
2024-07-07 14:42:46 +02:00
Bjørn Erik Pedersen
094f746751
commands: Simplify the browser live reload logic
...
And improve the logging for live reload.
Closes #12643
2024-07-07 14:42:46 +02:00
Bjørn Erik Pedersen
fb8909d5b0
Use xxHash for the change detector
...
Much faster compared to MD5:
```
name old time/op new time/op delta
HashingFs-10 21.3µs ± 2% 3.2µs ±17% -84.96% (p=0.029 n=4+4)
name old alloc/op new alloc/op delta
HashingFs-10 12.9kB ± 0% 12.8kB ± 1% -1.31% (p=0.029 n=4+4)
name old allocs/op new allocs/op delta
HashingFs-10 10.0 ± 0% 7.0 ± 0% -30.00% (p=0.029 n=4+4)
```
Updates #12643
2024-07-06 16:57:16 +02:00
PeskyPotato
0ee2610d7c
source: Expose GitInfo Body
...
Updated bep/gitmap to v1.4.0, to get commit message's Body.
Added Body to GitInfo struct. Docs upated with commit body example.
Fixes #10905
2024-07-06 16:28:11 +02:00
Bjørn Erik Pedersen
251a23ef76
commands: Fix hugo mod get -u ./...
...
Fixes #12625
2024-07-06 15:38:21 +02:00
Bjørn Erik Pedersen
644d55475d
Add hash.XxHash
...
Also move the non crypto hash funcs into this new package.
This is much faster than e.g. MD5, especially for larger inputs:
```
BenchmarkXxHash/xxHash_43-10 9917955 112.2 ns/op 56 B/op 4 allocs/op
BenchmarkXxHash/mdb5_43-10 6017239 204.1 ns/op 96 B/op 3 allocs/op
BenchmarkXxHash/fnv32a_43-10 14407333 82.30 ns/op 16 B/op 1 allocs/op
BenchmarkXxHash/xxHash_4300-10 2916892 409.7 ns/op 56 B/op 4 allocs/op
BenchmarkXxHash/mdb5_4300-10 159748 7491 ns/op 4912 B/op 3 allocs/op
BenchmarkXxHash/fnv32a_4300-10 218210 5510 ns/op 16 B/op 1 allocs/op
```
Fixes #12635
2024-07-06 14:08:15 +02:00
hugoreleaser
edeed52fc5
releaser: Prepare repository for 0.129.0-DEV
...
[ci skip]
2024-07-04 08:27:37 +00:00
hugoreleaser
de36c1a95d
releaser: Bump versions for release of 0.128.2
...
[ci skip]
2024-07-04 08:13:25 +00:00
Bjørn Erik Pedersen
8cf96f244a
Fix site.GetPage, never do short lookups for paths with leadig slash
...
Fixes #12638
2024-07-04 10:09:18 +02:00
hugoreleaser
82af94d1f5
releaser: Prepare repository for 0.129.0-DEV
...
[ci skip]
2024-07-02 07:00:44 +00:00
hugoreleaser
0ff542b4b9
releaser: Bump versions for release of 0.128.1
...
[ci skip]
2024-07-02 06:46:41 +00:00
Cyrus Yip
a95fe50616
create/skeletons: Fix languageCode region subtag
...
Region subtag should be in ALLCAPS
2024-07-02 08:43:19 +02:00
Bjørn Erik Pedersen
7b6dafc53a
Fix it so publishDate rolls up to section, taxonomy, or term pages
...
Fixes #12438
2024-07-01 21:48:12 +02:00
Joe Mooring
932ab4c058
Update README.md
2024-06-27 23:35:56 +02:00
hugoreleaser
95479fc2d0
releaser: Prepare repository for 0.129.0-DEV
...
[ci skip]
2024-06-25 16:30:14 +00:00
hugoreleaser
e6d2712ee0
releaser: Bump versions for release of 0.128.0
...
[ci skip]
2024-06-25 16:15:48 +00:00
Joe Mooring
79da24a0eb
deps: Upgrade github.com/yuin/goldmark v1.7.2 => v1.7.4
2024-06-25 18:04:45 +02:00
Bjørn Erik Pedersen
e1317dd322
Add css.TailwindCSS
...
Closes #12618
Closes #12620
2024-06-25 15:48:02 +02:00
Bjørn Erik Pedersen
eddcd2bac6
Clean up the css related template funcs package structure
...
Deprecate and move:
* resources.ToCSS => css.SASS
* resources.PostProcess => css.PostProcess
* resources.Babel => js.Babel
Updates #12618
2024-06-25 15:48:02 +02:00
Bjørn Erik Pedersen
1687a9a585
Delete unused release hook script
...
Closes #12378
2024-06-25 15:09:35 +02:00
Bjørn Erik Pedersen
16e4662b7d
modules: Remove newly introduced "mount source" does not exist warning
2024-06-25 15:04:07 +02:00