Address all warnings during the Hugo build

- Add descriptions for pages that have too much content
- Add an image orientation override param so that I can specify orientation when it's missing from EXIF
- Move the author.name and author.email configurations to params; delete author.yaml
This commit is contained in:
Eryn Wells 2023-12-18 11:22:14 -08:00
parent e4c62f02d3
commit 383234e983
13 changed files with 41 additions and 16 deletions

View file

@ -1,2 +0,0 @@
name: Eryn Wells
email: eryn@erynwells.me

View file

@ -1,3 +1,7 @@
author:
name: Eryn Wells
email: eryn@erynwells.me
shortTitle: Eryn Wells shortTitle: Eryn Wells
twitter: erynofwales twitter: erynofwales

View file

@ -1,7 +1,7 @@
--- ---
title: "Booting a Raspberry Pi Over TFTP" title: "Booting a Raspberry Pi Over TFTP"
date: 2020-10-13T08:31:52-07:00 date: 2020-10-13T08:31:52-07:00
draft: false description: A writeup of how I set up a Raspberry Pi to boot over TFTP to facilitate an operating system development project.
series: ["Raspberry Pi OS Development"] series: ["Raspberry Pi OS Development"]
categories: ["Tech"] categories: ["Tech"]
tags: ["Raspberry Pi", "Networking"] tags: ["Raspberry Pi", "Networking"]

View file

@ -1,6 +1,7 @@
--- ---
title: "Roguelikes I Like" title: "Roguelikes I Like"
date: 2022-05-09T08:37:23-07:00 date: 2022-05-09T08:37:23-07:00
description: Some roguelikes Ive enjoyed recently.
draft: false draft: false
resources: resources:
- name: nethack - name: nethack

View file

@ -1,7 +1,7 @@
--- ---
title: "Making an Audio Scope with P5.js" title: "Making an Audio Scope with P5.js"
date: 2022-08-18T20:48:37-07:00 date: 2022-08-18T20:48:37-07:00
draft: false description: A writeup of a small JavaScript waveform visualizer I made with P5.js.
categories: ["Tech"] categories: ["Tech"]
tags: ["P5.js", "Programming", "Web", "Art"] tags: ["P5.js", "Programming", "Web", "Art"]
resources: resources:

View file

@ -1,6 +1,7 @@
--- ---
title: "Hugo's Dictionary API" title: "Hugo's Dictionary API"
date: 2022-10-13T10:19:02-07:00 date: 2022-10-13T10:19:02-07:00
description: Ive found Hugos API for collections to be difficult to understand. Heres my attempt to summarize its quirks.
categories: ["Tech"] categories: ["Tech"]
tags: ["Hugo", "Web", "API Design"] tags: ["Hugo", "Web", "API Design"]
series: "Erynwells.me Development" series: "Erynwells.me Development"

View file

@ -1,6 +1,7 @@
--- ---
title: "Lunar Eclipse 🌝" title: "Lunar Eclipse 🌝"
date: 2022-11-07T08:37:45-08:00 date: 2022-11-07T08:37:45-08:00
description: A quick note about the upcoming lunar eclipse in the morning of 2022-11-08.
categories: Space categories: Space
tags: [Moon, Lunar Eclipse] tags: [Moon, Lunar Eclipse]
--- ---

View file

@ -1,6 +1,7 @@
--- ---
title: "My Best Nethack Game (So Far)" title: "My Best Nethack Game (So Far)"
date: 2022-11-24T09:13:15-05:00 date: 2022-11-24T09:13:15-05:00
description: A summary of my best-to-date game of Nethack.
categories: ["Games"] categories: ["Games"]
tags: ["Nethack", "Roguelikes", "Video Games"] tags: ["Nethack", "Roguelikes", "Video Games"]
resources: resources:

View file

@ -1,8 +1,9 @@
--- ---
title: "Netscape Meteors: Retrospective" title: "Netscape Meteors: Retrospective"
date: 2023-08-05T17:14:40-07:00 date: 2023-08-05T17:14:40-07:00
description: Someone shared my Netscape Meteors post on the Orange Website, causing it to be moderately viral for a few days. Heres an update on the web traffic my server received.
categories: ["Tech"] categories: ["Tech"]
tags: tags:
- History - History
- Meta - Meta
- Netscape - Netscape

View file

@ -1,6 +1,7 @@
--- ---
title: "Netscape Meteors" title: "Netscape Meteors"
date: 2023-08-01T18:23:33-07:00 date: 2023-08-01T18:23:33-07:00
description: I went on a hunt to find the "Meteors" loading animation from Netscape back in the 90s, and wrote up my adventure.
resources: resources:
- name: netscape60 - name: netscape60
title: Netscape Meteor Loading Animation title: Netscape Meteor Loading Animation
@ -14,7 +15,7 @@ resources:
- name: rectangular-pixels - name: rectangular-pixels
title: Rectangular Pixels title: Rectangular Pixels
src: rectangular-pixels.png src: rectangular-pixels.png
alt: "A zoomed in screenshot of an animation frame with pixel grid enabled, alt: "A zoomed in screenshot of an animation frame with pixel grid enabled,
showing rectangular pixels" showing rectangular pixels"
categories: Tech categories: Tech
tags: ["Netscape", "History", "Web Browsers", "Web"] tags: ["Netscape", "History", "Web Browsers", "Web"]

View file

@ -1,7 +1,12 @@
--- ---
title: "Lotus" title: "Lotus"
date: 2023-10-12T10:09:29-07:00 date: 2023-10-12T10:09:29-07:00
tags: resources:
- name: Lotus
src: 20231008-Lotus.jpg
params:
orientation: horizontal
tags:
- Nature - Nature
- Flowers - Flowers
--- ---

View file

@ -1,18 +1,30 @@
{{ $orientation := 0 }} {{ $orientation := 0 }}
{{ with (int .Exif.Tags.Orientation) }} {{ with .Params.orientation }}
{{/* EXIF orientation is specified as an integer corresponding to a 90º rotation. */}} {{ if strings.Contains . "horizontal" }}
{{ if in (slice 1 2) . }}
{{ $orientation = 0 }} {{ $orientation = 0 }}
{{ else if in (slice 3 4) . }} {{ else if strings.Contains . "rotate180" }}
{{ $orientation = 180 }} {{ $orientation = 180 }}
{{ else if in (slice 5 6) . }} {{ else if strings.Contains . "rotate90" }}
{{ $orientation = 90 }} {{ $orientation = 90 }}
{{ else if in (slice 7 8) . }} {{ else if strings.Contains . "rotate270" }}
{{ $orientation = 270 }} {{ $orientation = 270 }}
{{ end }} {{ end }}
{{ else }} {{ else }}
{{ warnf "Image missing orientation: %s" . }} {{ with (int .Exif.Tags.Orientation) }}
{{/* EXIF orientation is specified as an integer corresponding to a 90º rotation. */}}
{{ if in (slice 1 2) . }}
{{ $orientation = 0 }}
{{ else if in (slice 3 4) . }}
{{ $orientation = 180 }}
{{ else if in (slice 5 6) . }}
{{ $orientation = 90 }}
{{ else if in (slice 7 8) . }}
{{ $orientation = 270 }}
{{ end }}
{{ else }}
{{ warnf "Image missing orientation: %s" . }}
{{ end }}
{{ end }} {{ end }}
{{ return $orientation }} {{ return $orientation }}

View file

@ -8,9 +8,9 @@
{{/* Space separated list of classes to apply to the <img> tag */}} {{/* Space separated list of classes to apply to the <img> tag */}}
{{ $classes := .Get "class" }} {{ $classes := .Get "class" }}
{{ $altText := $img.Params.alt | default (.Get "alt") }} {{ $altText := .Get "alt" | default $img.Params.alt }}
{{ if not $altText }} {{ if not $altText }}
{{ warnf "Image doesn't have alt text. %s" $img.Permalink }} {{ warnf "Image doesn't have alt text: %s" $img.RelPermalink }}
{{ end }} {{ end }}
{{ $resizedImg := $img.Fit "1280x1280" }} {{ $resizedImg := $img.Fit "1280x1280" }}