Author SHA1 Message Date
bbaovanc c23b43342c WIP: finished implementation of Netlify _redirects
TBD will be caddy, not sure whether this is actually a good idea because
including a Caddy file directly from GitHub Actions accessible job
output might be a config injection risk.
2026-07-08 02:18:53 -05:00
bbaovanc 2f6db565a9 WIP: Add redirects in Netlify _redirects style using old guide
Uses this guide: https://honnef.co/articles/generating-netlify-_redirects-from-hugo/

I didn't realize until after doing all this that there's a guide for the
same thing in the official Hugo docs, so I'm about to migrate over to
that.
2026-07-08 01:51:20 -05:00
bbaovanc a2a8e2c205 css: Use structured class names for children of code-block 2026-01-31 01:58:42 -06:00
4 changed files with 33 additions and 9 deletions
+6 -6
View File
@@ -823,7 +823,7 @@ figcaption {
background-color: var(--background-1);
border-radius: 8px;
}
.code-block > .code-header {
.code-block-header {
display: flex;
flex-direction: row;
justify-content: space-between;
@@ -833,17 +833,17 @@ figcaption {
border-top-right-radius: 8px;
height: 2em;
}
.code-block > .code-header > * {
.code-block-header > * {
margin: auto 0;
}
.code-block > .code-header > .code-type {
.code-block-type {
border-top-left-radius: 8px;
}
/* TODO: make the code copy button prettier */
.code-block > .code-header > .code-copy-button {
.code-block-copy-button {
color: var(--link-1);
}
.code-block > .code-header > .code-copy-button:hover {
.code-block-copy-button:hover {
cursor: pointer;
}
.code-block > .highlight {
@@ -877,7 +877,7 @@ figcaption {
overflow-wrap: break-word;
}
.code-block > .code-header > .code-type,
.code-block-type,
code {
border-radius: 5px;
}
+17
View File
@@ -21,6 +21,23 @@ taxonomies:
outputs:
page:
- html
home:
- html
- rss
- redirects
outputFormats:
# https://honnef.co/articles/generating-netlify-_redirects-from-hugo/
redirects:
baseName: _redirects
isPlainText: true
mediaType: text/redirects
root: true
mediaTypes:
# https://honnef.co/articles/generating-netlify-_redirects-from-hugo/
text/redirects:
delimeter: ""
privacy:
googleAnalytics:
+3 -3
View File
@@ -3,9 +3,9 @@
{{ $type = . }}
{{ end }}
<div class="code-block">
<div class="code-header">
<pre class="code-type">{{ $type }}</pre>
<a href="javascript:void(0)" class="code-copy-button">
<div class="code-block-header">
<pre class="code-block-type">{{ $type }}</pre>
<a href="javascript:void(0)" class="code-block-copy-button">
{{ i18n "copy_to_clipboard" }}
</a>
</div>
+7
View File
@@ -0,0 +1,7 @@
{{ range hugo.Sites -}}
{{ range $p := .Pages -}}
{{ range .Aliases -}}
{{ . }} {{ $p.RelPermalink }}
{{ end -}}
{{ end -}}
{{ end -}}