mirror of
https://git.sr.ht/~seirdy/seirdy.one
synced 2024-11-23 21:02:09 +00:00
Compare commits
5 commits
aade17ef20
...
f9c497fac0
Author | SHA1 | Date | |
---|---|---|---|
|
f9c497fac0 | ||
|
b3a676c72d | ||
|
1e2595cfe3 | ||
|
1f4a6d7b24 | ||
|
9f681f9c0d |
10 changed files with 64 additions and 55 deletions
|
@ -35,9 +35,9 @@ disableKinds = ["taxonomy", "term"]
|
||||||
|
|
||||||
[menu]
|
[menu]
|
||||||
[[menu.main]]
|
[[menu.main]]
|
||||||
identifier = "posts"
|
identifier = "articles"
|
||||||
name = "Posts"
|
name = "Articles"
|
||||||
title = "posts"
|
title = "articles"
|
||||||
url = "/posts/"
|
url = "/posts/"
|
||||||
weight = 10
|
weight = 10
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
---
|
---
|
||||||
title: "Opt in telemetry"
|
title: "Opt in telemetry"
|
||||||
date: 2022-06-03T02:27:05-07:00
|
date: 2022-06-03T02:27:05-07:00
|
||||||
replyURI: "https://news.ycombinator.com/item?id=31604932"
|
replyURI: "https://news.ycombinator.com/item?id=31605884"
|
||||||
replyTitle: "As far as I am concerned, telemetry is a good thing"
|
replyTitle: "As far as I am concerned, telemetry is a good thing"
|
||||||
replyType: "SocialMediaPosting"
|
replyType: "SocialMediaPosting"
|
||||||
replyAuthor: "eterevsky"
|
replyAuthor: "eterevsky"
|
||||||
|
|
22
content/notes/welcome-to-the-indieweb.md
Normal file
22
content/notes/welcome-to-the-indieweb.md
Normal file
|
@ -0,0 +1,22 @@
|
||||||
|
---
|
||||||
|
title: "Welcome to the IndieWeb"
|
||||||
|
date: 2022-06-20T14:30:24-07:00
|
||||||
|
replyURI: "https://www.miriamsuzanne.com/2022/06/04/indiweb/"
|
||||||
|
replyTitle: "Am I on the IndieWeb Yet?"
|
||||||
|
replyType: "BlogPosting"
|
||||||
|
replyAuthor: "Miriam Suzanne"
|
||||||
|
replyAuthorURI: "https://www.miriamsuzanne.com/who/"
|
||||||
|
---
|
||||||
|
Welcome to the IndieWeb, Miriam!
|
||||||
|
|
||||||
|
> I've struggled to categorize what on my wite is a "post" worth syndicating vs a "page" vs ???
|
||||||
|
|
||||||
|
I had this struggle too, and solved it with per-section and combined feeds. [My combined feed](https://seirdy.one/atom.xml) contains every page on my site that includes a publication date in its metadata; my sections for articles and notes have their own respective feeds.
|
||||||
|
|
||||||
|
> If I want live updates (this is a static site) there’s still more to learn.
|
||||||
|
|
||||||
|
Remember that pretty much all IndieWeb features are optional. You only have to implement what interests you. You can get really far when it comes to bringing a static site to the IndieWeb, so I'd suggest against jumping onto a dynamic site immediately.
|
||||||
|
|
||||||
|
You can also push live updates using WebSub. Your main site can still be static, but you can pint a (first- or third-party) WebSub hub to push content as soon as you update your site. I plan on using this approach soon.
|
||||||
|
|
||||||
|
I like the "static site with ancillary services" model: it keeps the core fast and simple, and makes extra modules easy to add and replace.
|
|
@ -1,13 +1,13 @@
|
||||||
---
|
---
|
||||||
template: "posts.html"
|
template: "posts.html"
|
||||||
description: "All the long-form posts on Seirdy's Home"
|
description: "All the long-form articles on Seirdy's Home"
|
||||||
title: "Posts"
|
title: "Articles"
|
||||||
sitemap:
|
sitemap:
|
||||||
ChangeFreq: weekly
|
ChangeFreq: weekly
|
||||||
Priority: 0.7
|
Priority: 0.7
|
||||||
---
|
---
|
||||||
Posts
|
Articles
|
||||||
=====
|
========
|
||||||
|
|
||||||
These are all of my long-form posts. [An Atom feed](./atom.xml) contains their full text. If that has any problems, I also have [a legacy RSS feed](./index.xml).
|
These are all of my long-form articles. [An Atom feed](./atom.xml) contains their full text. If that has any problems, I also have [a legacy RSS feed](./index.xml).
|
||||||
|
|
||||||
|
|
|
@ -7,7 +7,7 @@ date: "2022-06-10T00:00:00+00:00"
|
||||||
---
|
---
|
||||||
This site may look simple on the surface, but I put a _lot_ of thought into it. I hold myself to a long list of requirements concerning accessibility, compatibility, privacy, security, and machine-friendliness.
|
This site may look simple on the surface, but I put a _lot_ of thought into it. I hold myself to a long list of requirements concerning accessibility, compatibility, privacy, security, and machine-friendliness.
|
||||||
|
|
||||||
<p role="doc-tip">Note: all references to "pixels" (px) in this section refer to CSS pixels.</p>
|
<p role="doc-tip">Note: all references to "pixels" (<abbr title="pixels">px</abbr>) in this section refer to CSS pixels.</p>
|
||||||
|
|
||||||
Accessibility statement
|
Accessibility statement
|
||||||
-----------------------
|
-----------------------
|
||||||
|
@ -22,7 +22,7 @@ The [Web Content Accessibility Guidelines (WCAG)](https://www.w3.org/WAI/standar
|
||||||
|
|
||||||
### Additional accessibility considerations
|
### Additional accessibility considerations
|
||||||
|
|
||||||
Additionally, I strive to conform to WCAG 2.2 level AAA wherever applicable. There are some AAA criteria that I do not currently meet:
|
Additionally, I strive to conform to WCAG 2.2 level AAA wherever applicable. I comply with all AAA criteria except for the following:
|
||||||
|
|
||||||
|
|
||||||
SC 1.4.8 Visual Presentation
|
SC 1.4.8 Visual Presentation
|
||||||
|
@ -65,12 +65,16 @@ Finally, I supplement manual testing with the following automated tools:
|
||||||
|
|
||||||
WAVE reports no errors; AXE is unable to determine certain contrast errors, but it otherwise reports no errors; IBM Equal Access reports no errors but some items that need review.
|
WAVE reports no errors; AXE is unable to determine certain contrast errors, but it otherwise reports no errors; IBM Equal Access reports no errors but some items that need review.
|
||||||
|
|
||||||
Browser engine compatibility
|
I regularly run axe-core and the IBM Equal Access Accessibility Checker on every page in my sitemap, and receive no errors.
|
||||||
----------------------------
|
|
||||||
|
|
||||||
This site sticks to Web standards: I regularly run [the Nu HTML Checker](https://github.com/validator/validator) and `xmllint` on every page and see no errors (I do [filter out false Nu positives](https://git.sr.ht/~seirdy/seirdy.one/tree/master/item/linter-configs/vnu_filter.jq) and report them upstream when I can).
|
Compatibility statement
|
||||||
|
-----------------------
|
||||||
|
|
||||||
I also do cross-browser testing for both HTML and XHTML versions of my pages:
|
The website is built on well structured, semantic HTML (including [WAI-ARIA](https://www.w3.org/WAI/standards-guidelines/aria/) and [DPUB-ARIA](https://www.w3.org/TR/dpub-aria-1.1/) where appropriate), enhanced with CSS for styling. The website does **not** rely on modern development practices such as CSS Grid, Flexbox, SVG 2, Web fonts, and JavaScript; this should improve support in older browsers such as Internet Explorer 11. No extra plugins or libraries should be required to view the website.
|
||||||
|
|
||||||
|
This site sticks to Web standards. I regularly run a local build of [the Nu HTML Checker](https://github.com/validator/validator), `xmllint`, and [html proofer](https://github.com/gjtorikian/html-proofer) on every page in my sitemap, and see no errors. I do [filter out false Nu positives](https://git.sr.ht/~seirdy/seirdy.one/tree/master/item/linter-configs/vnu_filter.jq) and report them upstream when I can.
|
||||||
|
|
||||||
|
I also perform cross-browser testing for both HTML and XHTML versions of my pages:
|
||||||
|
|
||||||
- I maintain excellent compatibility with **mainstream engines:** Blink (Chromium and Edge), WebKit (Safari, Epiphany), and Gecko (Firefox). The hidden service also works well with the Tor Browser.
|
- I maintain excellent compatibility with **mainstream engines:** Blink (Chromium and Edge), WebKit (Safari, Epiphany), and Gecko (Firefox). The hidden service also works well with the Tor Browser.
|
||||||
|
|
||||||
|
|
|
@ -34,7 +34,7 @@
|
||||||
<a rel="home" href="https://seirdy.one/">Seirdy's Home</a>
|
<a rel="home" href="https://seirdy.one/">Seirdy's Home</a>
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="/posts/">Posts</a>
|
<a href="/posts/">Articles</a>
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="/notes/">Notes</a>
|
<a href="/notes/">Notes</a>
|
||||||
|
|
|
@ -20,18 +20,18 @@
|
||||||
<link href="{{ .Site.Params.WebmentionEndpoint }}" rel="webmention" />
|
<link href="{{ .Site.Params.WebmentionEndpoint }}" rel="webmention" />
|
||||||
{{ $webmanifest := resources.Get "/manifest.webmanifest" | resources.ExecuteAsTemplate "manifest.webmanifest" . | resources.Minify | resources.Fingerprint "md5" -}}
|
{{ $webmanifest := resources.Get "/manifest.webmanifest" | resources.ExecuteAsTemplate "manifest.webmanifest" . | resources.Minify | resources.Fingerprint "md5" -}}
|
||||||
{{- printf `<link href="%s" rel="manifest" />` $webmanifest.RelPermalink | safeHTML -}}
|
{{- printf `<link href="%s" rel="manifest" />` $webmanifest.RelPermalink | safeHTML -}}
|
||||||
<!--Feeds for both notes and posts; posts come first unless we're in the notes section.-->
|
<!--Feeds for both notes and articles; articles come first unless we're in the notes section.-->
|
||||||
{{- if or (eq .Section "notes") (eq .Title "Notes") -}}
|
{{- if or (eq .Section "notes") (eq .Title "Notes") -}}
|
||||||
<link rel="alternate" type="application/atom+xml" href="{{ site.BaseURL }}notes/atom.xml" title="Notes" />
|
<link rel="alternate" type="application/atom+xml" href="{{ site.BaseURL }}notes/atom.xml" title="Notes" />
|
||||||
<link rel="alternate" type="application/atom+xml" href="{{ site.BaseURL }}atom.xml" title="All content" />
|
<link rel="alternate" type="application/atom+xml" href="{{ site.BaseURL }}atom.xml" title="All content" />
|
||||||
<link rel="alternate" type="application/atom+xml" href="{{ site.BaseURL }}posts/atom.xml" title="Posts" />
|
<link rel="alternate" type="application/atom+xml" href="{{ site.BaseURL }}posts/atom.xml" title="Articles" />
|
||||||
{{- else if or (eq .Section "posts") (eq .Title "Posts") -}}
|
{{- else if or (eq .Section "posts") (eq .Title "Articles") -}}
|
||||||
<link rel="alternate" type="application/atom+xml" href="{{ site.BaseURL }}posts/atom.xml" title="Posts" />
|
<link rel="alternate" type="application/atom+xml" href="{{ site.BaseURL }}posts/atom.xml" title="Articles" />
|
||||||
<link rel="alternate" type="application/atom+xml" href="{{ site.BaseURL }}atom.xml" title="All content" />
|
<link rel="alternate" type="application/atom+xml" href="{{ site.BaseURL }}atom.xml" title="All content" />
|
||||||
<link rel="alternate" type="application/atom+xml" href="{{ site.BaseURL }}notes/atom.xml" title="Notes" />
|
<link rel="alternate" type="application/atom+xml" href="{{ site.BaseURL }}notes/atom.xml" title="Notes" />
|
||||||
{{- else -}}
|
{{- else -}}
|
||||||
<link rel="alternate" type="application/atom+xml" href="{{ site.BaseURL }}atom.xml" title="All content" />
|
<link rel="alternate" type="application/atom+xml" href="{{ site.BaseURL }}atom.xml" title="All content" />
|
||||||
<link rel="alternate" type="application/atom+xml" href="{{ site.BaseURL }}posts/atom.xml" title="Posts" />
|
<link rel="alternate" type="application/atom+xml" href="{{ site.BaseURL }}posts/atom.xml" title="Articles" />
|
||||||
<link rel="alternate" type="application/atom+xml" href="{{ site.BaseURL }}notes/atom.xml" title="Notes" />
|
<link rel="alternate" type="application/atom+xml" href="{{ site.BaseURL }}notes/atom.xml" title="Notes" />
|
||||||
{{- end }}
|
{{- end }}
|
||||||
<title>{{ .Title }}{{ if and (lt (len .Title) 54) (ne $canonicalRelPermalink "/") }} - Seirdy{{ end }}</title>
|
<title>{{ .Title }}{{ if and (lt (len .Title) 54) (ne $canonicalRelPermalink "/") }} - Seirdy{{ end }}</title>
|
||||||
|
|
|
@ -23,9 +23,9 @@
|
||||||
{{ $isCurrent := false }}
|
{{ $isCurrent := false }}
|
||||||
<li itemprop="hasPart" itemscope="" itemtype="https://schema.org/SiteNavigationElement">
|
<li itemprop="hasPart" itemscope="" itemtype="https://schema.org/SiteNavigationElement">
|
||||||
<a href="{{ .URL }}" itemprop="url"
|
<a href="{{ .URL }}" itemprop="url"
|
||||||
{{- if or (eq .Identifier "notes" ) (eq .Identifier "posts") (eq .Identifier "bookmarks") }} rel="feed"{{- end }}
|
{{- if or (eq .Identifier "notes" ) (eq .Identifier "articles") (eq .Identifier "bookmarks") }} rel="feed"{{- end }}
|
||||||
{{- if or (eq $currentPage.RelPermalink .URL) ($currentPage.HasMenuCurrent "main" .) -}}{{- $isCurrent = true }} aria-current="page"{{- end -}}>
|
{{- if or (eq $currentPage.RelPermalink .URL) ($currentPage.HasMenuCurrent "main" .) -}}{{- $isCurrent = true }} aria-current="page"{{- end -}}>
|
||||||
{{- if or $isCurrent (eq $currentPage.Section .Title) -}}
|
{{- if or $isCurrent (eq $currentPage.Section .Title) (and (eq $currentPage.Section "posts") (eq .Identifier "articles")) -}}
|
||||||
<strong itemprop="name">{{- .Name -}}</strong>
|
<strong itemprop="name">{{- .Name -}}</strong>
|
||||||
{{- else -}}
|
{{- else -}}
|
||||||
<span itemprop="name">{{- .Name -}}</span>
|
<span itemprop="name">{{- .Name -}}</span>
|
||||||
|
|
|
@ -1,43 +1,23 @@
|
||||||
{{- $isStandalone := false -}}
|
|
||||||
{{- if and (ne .Permalink .Site.BaseURL) (ne .RelPermalink "/") -}}
|
|
||||||
{{- $isStandalone = true -}}
|
|
||||||
{{- end -}}
|
|
||||||
{{- if $isStandalone -}}
|
|
||||||
<main itemprop="mainEntity" class="h-feed hfeed" itemscope="" itemtype="https://schema.org/DataFeed">
|
|
||||||
<h1 class="p-name" itemprop="name headline" id="posts">Posts</h1>
|
|
||||||
<p>These are all of my long-form posts. <a href="./atom.xml">An Atom feed</a> contains the full text of all my posts. If that has any problems, I also have <a href="./index.xml">a legacy RSS feed</a>.</p>
|
|
||||||
{{- else -}}
|
|
||||||
<section class="h-feed hfeed" itemprop="hasPart" itemscope="" itemtype="https://schema.org/DataFeed">
|
<section class="h-feed hfeed" itemprop="hasPart" itemscope="" itemtype="https://schema.org/DataFeed">
|
||||||
<h2 class="p-name" itemprop="name" id="posts">Posts</h2>
|
<h2 class="p-name" itemprop="name" id="articles">Articles</h2>
|
||||||
<p>Here’s a selection of my best posts, in featured order. To see the rest, visit <a href="posts/">my Posts page</a>.</p>
|
<p>Here’s a selection of my best articles, in featured order. To see the rest, visit <a href="posts/">my Articles page</a>.</p>
|
||||||
{{- end }}
|
<p>I edit some of these articles quite often; some are updated indefinitely. Check the “updated” timestamps.</p>
|
||||||
<p>I edit some of these posts quite often; some are updated indefinitely. Check the “updated” timestamps.</p>
|
|
||||||
<p role="doc-tip">
|
<p role="doc-tip">
|
||||||
Timestamp format: <code>YYYY-MM-DD</code>, as per <cite><a href="https://www.ietf.org/rfc/rfc3339.txt">RFC 3339</a></cite> and <cite><a href="https://xkcd.com/1179/">ISO 8601</a></cite>. Sorted newest to oldest.
|
Timestamp format: <code>YYYY-MM-DD</code>, as per <cite><a href="https://www.ietf.org/rfc/rfc3339.txt">RFC 3339</a></cite> and <cite><a href="https://xkcd.com/1179/">ISO 8601</a></cite>. Sorted newest to oldest.
|
||||||
</p>
|
</p>
|
||||||
<ol>
|
<ol>
|
||||||
{{- $posts := (where site.RegularPages "Section" "posts") -}}
|
{{- $posts := site.RegularPages -}}
|
||||||
{{- if not $isStandalone -}}
|
{{- $posts = sort (where $posts "Params.featured" ">" 0) "Params.featured" -}}
|
||||||
{{- $posts = sort (where $posts "Params.featured" ">" 0) "Params.featured" -}}
|
|
||||||
{{- end -}}
|
|
||||||
{{- range $posts -}}
|
{{- range $posts -}}
|
||||||
{{- $canonicalRelPermalink := .RelPermalink | replaceRE "^/~seirdy/" "/" -}}
|
{{- $canonicalRelPermalink := .RelPermalink | replaceRE "^/~seirdy/" "/" -}}
|
||||||
<li itemprop="dataFeedElement" itemscope="" itemtype="https://schema.org/DataFeedItem">
|
<li itemprop="dataFeedElement" itemscope="" itemtype="https://schema.org/DataFeedItem">
|
||||||
<article class="h-entry hentry" itemprop="item" itemscope="" itemtype="https://schema.org/BlogPosting" itemid="{{ .Site.Params.CanonicalBaseURL }}{{ $canonicalRelPermalink }}">
|
<article class="h-entry hentry" itemprop="item" itemscope="" itemtype="https://schema.org/BlogPosting" itemid="{{ .Site.Params.CanonicalBaseURL }}{{ $canonicalRelPermalink }}">
|
||||||
{{ if $isStandalone -}}
|
|
||||||
<h2
|
|
||||||
{{- else -}}
|
|
||||||
<h3
|
<h3
|
||||||
{{- end }}
|
|
||||||
itemprop="name headline" class="p-name entry-title">
|
itemprop="name headline" class="p-name entry-title">
|
||||||
<a href="{{ .Permalink }}" itemprop="url" class="u-url url" rel="bookmark">
|
<a href="{{ .Permalink }}" itemprop="url" class="u-url url" rel="bookmark">
|
||||||
{{ .Title }}
|
{{ .Title }}
|
||||||
</a>
|
</a>
|
||||||
{{ if $isStandalone -}}
|
|
||||||
</h2>
|
|
||||||
{{- else -}}
|
|
||||||
</h3>
|
</h3>
|
||||||
{{- end }}
|
|
||||||
<p>
|
<p>
|
||||||
Posted <time itemprop="datePublished" class="dt-published published" datetime="{{ .Date.Format "2006-01-02 15:04:05Z07:00" }}">{{ .Date.Format "2006-01-02" }}</time>
|
Posted <time itemprop="datePublished" class="dt-published published" datetime="{{ .Date.Format "2006-01-02 15:04:05Z07:00" }}">{{ .Date.Format "2006-01-02" }}</time>
|
||||||
{{- if lt .Date .Lastmod -}}
|
{{- if lt .Date .Lastmod -}}
|
||||||
|
@ -51,8 +31,4 @@
|
||||||
</li>
|
</li>
|
||||||
{{- end }}
|
{{- end }}
|
||||||
</ol>
|
</ol>
|
||||||
{{ if $isStandalone -}}
|
|
||||||
</main>
|
|
||||||
{{ else -}}
|
|
||||||
</section>
|
</section>
|
||||||
{{ end }}
|
|
||||||
|
|
|
@ -5,7 +5,7 @@ set -e -u
|
||||||
# the name of this program
|
# the name of this program
|
||||||
progname="$(basename "${0}")"
|
progname="$(basename "${0}")"
|
||||||
|
|
||||||
help_text="Usage: $progname [BASEURL]
|
help_text="Usage: $progname [OPTIONS...] [BASEURL]
|
||||||
|
|
||||||
Validate the site's markup, CSS, and accessibility.
|
Validate the site's markup, CSS, and accessibility.
|
||||||
|
|
||||||
|
@ -20,6 +20,7 @@ accessibility on every page in the sitemap.
|
||||||
|
|
||||||
Options:
|
Options:
|
||||||
-h Print this help and exit
|
-h Print this help and exit
|
||||||
|
-j Max parallel jobs. Default: 2
|
||||||
"
|
"
|
||||||
|
|
||||||
# TODO: add the following:
|
# TODO: add the following:
|
||||||
|
@ -37,12 +38,18 @@ bad_option() {
|
||||||
exit 1
|
exit 1
|
||||||
}
|
}
|
||||||
|
|
||||||
while getopts "hb" flags; do
|
jobs='2'
|
||||||
|
|
||||||
|
while getopts "hj" flags; do
|
||||||
case ${flags} in
|
case ${flags} in
|
||||||
h)
|
h)
|
||||||
usage
|
usage
|
||||||
exit 0
|
exit 0
|
||||||
;;
|
;;
|
||||||
|
j)
|
||||||
|
jobs="$1"
|
||||||
|
shift
|
||||||
|
;;
|
||||||
*)
|
*)
|
||||||
bad_option "${flags}" 'invalid option'
|
bad_option "${flags}" 'invalid option'
|
||||||
exit 1
|
exit 1
|
||||||
|
@ -54,6 +61,6 @@ base_url="${1-http://localhost:8089}"
|
||||||
|
|
||||||
# HTML validation is already parallelized, so run that single-threaded.
|
# HTML validation is already parallelized, so run that single-threaded.
|
||||||
make -j1 HUGO_FLAGS=-DF HUGO_BASEURL="$base_url" clean hugo xhtmlize validate-html
|
make -j1 HUGO_FLAGS=-DF HUGO_BASEURL="$base_url" clean hugo xhtmlize validate-html
|
||||||
make -j2 -f Makefile.online HUGO_BASEURL="$base_url" all-extra URLS="$(curl -sSL "$base_url/sitemap.xml" | htmlq loc -t | rg -v '/search/$' | tr '\n' ' ')"
|
make -j "$jobs" -f Makefile.online HUGO_BASEURL="$base_url" all-extra URLS="$(curl -sSL "$base_url/sitemap.xml" | htmlq loc -t | rg -v '/search/$' | tr '\n' ' ')"
|
||||||
|
|
||||||
# vi:ft=sh
|
# vi:ft=sh
|
||||||
|
|
Loading…
Reference in a new issue