hugo: fix cachebuster regexp

Cachebusters previously failed to detect changes in asset/layout files
due to a bad regex. Also simplified patterns by removing unnecessary
escapes and quotations.

Signed-off-by: David Karlsson <35727626+dvdksn@users.noreply.github.com>
This commit is contained in:
David Karlsson 2023-12-21 16:06:20 +01:00
parent b7e3ae1c69
commit 0bb3e5373d
1 changed files with 8 additions and 8 deletions

View File

@ -39,14 +39,14 @@ related:
build: build:
writeStats: true writeStats: true
cachebusters: cachebusters:
- source: "assets/watching/hugo_stats\\.json" - source: assets/watching/hugo_stats\.json
target: "styles\\.css" target: styles\.css
- source: "(postcss|tailwind)\\.config\\.js" - source: (postcss|tailwind)\.config\.js
target: "css" target: css
- source: "assets/.*\\.(js|ts|jsx|tsx)" - source: assets/.*\.js
target: "js" target: js
- source: "(assets|layouts)/.*\\.(.*)$" - source: (assets|layouts)/.*\.(.*)$
target: "$1" target: "$2"
outputFormats: outputFormats:
redirects: redirects: