Publish a stable stylesheet URL, move bookshop links to /shop
deploy / deploy (push) Successful in 6s
deploy / deploy (push) Successful in 6s
Publishes a second, non-fingerprinted copy of main.css at /css/main.min.css alongside the fingerprinted one the site itself links — same source resource, so bookshop's ARC/download pages (now mounted at thistleandmoth.org/shop, not shop.thistleandmoth.org) can link real, always-current CSS without tracking a hash that changes on every deploy. Updates the two remaining shop.thistleandmoth.org references to the new canonical URL.
This commit is contained in:
@@ -8,4 +8,4 @@ This page is a stub — the link below won't resolve until the real ARC
|
|||||||
campaign is created (see reground-tools' `arc-campaign.sh`) and this copy
|
campaign is created (see reground-tools' `arc-campaign.sh`) and this copy
|
||||||
is replaced with the real title/code.
|
is replaced with the real title/code.
|
||||||
|
|
||||||
[Get your free ebook](https://shop.thistleandmoth.org/arc/TODO-real-code)
|
[Get your free ebook](https://thistleandmoth.org/shop/arc/TODO-real-code)
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ disableKinds = ["taxonomy", "term"]
|
|||||||
description = "TODO: one-line description of Thistle & Moth"
|
description = "TODO: one-line description of Thistle & Moth"
|
||||||
author = "Thistle & Moth"
|
author = "Thistle & Moth"
|
||||||
eec_base_url = "https://eec.thistleandmoth.org"
|
eec_base_url = "https://eec.thistleandmoth.org"
|
||||||
bookshop_base_url = "https://shop.thistleandmoth.org"
|
bookshop_base_url = "https://thistleandmoth.org/shop"
|
||||||
|
|
||||||
[[menu.main]]
|
[[menu.main]]
|
||||||
name = "Submissions"
|
name = "Submissions"
|
||||||
|
|||||||
@@ -13,8 +13,17 @@
|
|||||||
{{ end }}
|
{{ end }}
|
||||||
{{ $css := resources.Get "css/main.css" }}
|
{{ $css := resources.Get "css/main.css" }}
|
||||||
{{ if hugo.IsProduction }}
|
{{ if hugo.IsProduction }}
|
||||||
{{ $css = $css | minify | fingerprint }}
|
{{ $cssFingerprinted := $css | minify | fingerprint }}
|
||||||
<link rel="stylesheet" href="{{ $css.RelPermalink }}" integrity="{{ $css.Data.Integrity }}">
|
<link rel="stylesheet" href="{{ $cssFingerprinted.RelPermalink }}" integrity="{{ $cssFingerprinted.Data.Integrity }}">
|
||||||
|
{{/* Also publish the same source at a second, stable, non-fingerprinted
|
||||||
|
URL — the fingerprinted one above changes hash on every deploy, so
|
||||||
|
it's unusable as a link target for an external same-origin
|
||||||
|
consumer (bookshop's /shop pages) that can't track that hash.
|
||||||
|
Referencing .RelPermalink is what makes Hugo actually publish this
|
||||||
|
resource; nothing else in this template links it. Stray non-
|
||||||
|
whitespace text directly in <head> gets moved into <body> by the
|
||||||
|
HTML parser, so this has to sit inside a comment. */}}
|
||||||
|
<!-- stable stylesheet copy: {{ ($css | minify).RelPermalink }} -->
|
||||||
{{ else }}
|
{{ else }}
|
||||||
<link rel="stylesheet" href="{{ $css.RelPermalink }}">
|
<link rel="stylesheet" href="{{ $css.RelPermalink }}">
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|||||||
Reference in New Issue
Block a user