mirror of
https://git.sr.ht/~seirdy/seirdy.one
synced 2024-11-23 12:52:10 +00:00
Compare commits
5 commits
d0c63f1ee6
...
b07f06e009
Author | SHA1 | Date | |
---|---|---|---|
|
b07f06e009 | ||
|
ca1b9910a1 | ||
|
566539df67 | ||
|
5a4da5f818 | ||
|
df5516a476 |
13 changed files with 37 additions and 12 deletions
2
.gitignore
vendored
2
.gitignore
vendored
|
@ -10,7 +10,7 @@ old/
|
||||||
public/
|
public/
|
||||||
public_*/
|
public_*/
|
||||||
.hugo_build.lock
|
.hugo_build.lock
|
||||||
csv/webrings.csv
|
assets/csv/webrings.csv
|
||||||
results/
|
results/
|
||||||
linter-configs/htmltest/
|
linter-configs/htmltest/
|
||||||
public.eac
|
public.eac
|
||||||
|
|
10
Makefile
10
Makefile
|
@ -97,10 +97,14 @@ html-validate:
|
||||||
.validate-feed-notes:
|
.validate-feed-notes:
|
||||||
scripts/bin/validate-feed file://$(PWD)/$(OUTPUT_DIR)/notes/atom.xml
|
scripts/bin/validate-feed file://$(PWD)/$(OUTPUT_DIR)/notes/atom.xml
|
||||||
validate-feeds: .validate-feed-main .validate-feed-posts .validate-feed-notes
|
validate-feeds: .validate-feed-main .validate-feed-posts .validate-feed-notes
|
||||||
.PHONY: validate-feeds .validate-feed-main .validate-feed-posts .validate-feed-notes
|
|
||||||
|
fflint: hugo
|
||||||
|
sh scripts/fflint.sh $(OUTPUT_DIR)
|
||||||
|
|
||||||
|
.PHONY: validate-feeds .validate-feed-main .validate-feed-posts .validate-feed-notes fflint
|
||||||
|
|
||||||
.PHONY: lint-local
|
.PHONY: lint-local
|
||||||
lint-local: html-validate validate-html validate-json htmlproofer validate-feeds
|
lint-local: fflint htmlproofer validate-feeds validate-json html-validate validate-html
|
||||||
|
|
||||||
# dev server, includes future and draft posts
|
# dev server, includes future and draft posts
|
||||||
.PHONY: serve
|
.PHONY: serve
|
||||||
|
@ -195,5 +199,5 @@ lint-and-deploy-staging:
|
||||||
deploy-envs:
|
deploy-envs:
|
||||||
@$(MAKE) HUGO_FLAGS='--gc --ignoreCache' USER=seirdy@envs.net WWW_ROOT=/home/seirdy/public_html GEMINI_ROOT=/home/seirdy/public_gemini HUGO_BASEURL='https://envs.net/~seirdy/' OUTPUT_DIR=public_envs xhtmlize
|
@$(MAKE) HUGO_FLAGS='--gc --ignoreCache' USER=seirdy@envs.net WWW_ROOT=/home/seirdy/public_html GEMINI_ROOT=/home/seirdy/public_gemini HUGO_BASEURL='https://envs.net/~seirdy/' OUTPUT_DIR=public_envs xhtmlize
|
||||||
@$(MAKE) HUGO_FLAGS='--gc --ignoreCache' USER=seirdy@envs.net WWW_ROOT=/home/seirdy/public_html GEMINI_ROOT=/home/seirdy/public_gemini HUGO_BASEURL='https://envs.net/~seirdy/' OUTPUT_DIR=public_envs copy-to-xhtml
|
@$(MAKE) HUGO_FLAGS='--gc --ignoreCache' USER=seirdy@envs.net WWW_ROOT=/home/seirdy/public_html GEMINI_ROOT=/home/seirdy/public_gemini HUGO_BASEURL='https://envs.net/~seirdy/' OUTPUT_DIR=public_envs copy-to-xhtml
|
||||||
@$(MAKE) HUGO_FLAGS='' USER=seirdy@envs.net WWW_ROOT=/home/seirdy/public_html GEMINI_ROOT=/home/seirdy/public_gemini HUGO_BASEURL='https://envs.net/~seirdy/' OUTPUT_DIR=public_envs validate-html html-validate validate-json validate-feeds
|
@$(MAKE) HUGO_FLAGS='' USER=seirdy@envs.net WWW_ROOT=/home/seirdy/public_html GEMINI_ROOT=/home/seirdy/public_gemini HUGO_BASEURL='https://envs.net/~seirdy/' OUTPUT_DIR=public_envs fflint validate-json validate-feeds validate-html html-validate
|
||||||
@$(MAKE) SSHFLAGS='-o KexAlgorithms=curve25519-sha256@libssh.org' HUGO_FLAGS='' USER=seirdy@envs.net WWW_ROOT=/home/seirdy/public_html GEMINI_ROOT=/home/seirdy/public_gemini HUGO_BASEURL='https://envs.net/~seirdy/' OUTPUT_DIR=public_envs deploy
|
@$(MAKE) SSHFLAGS='-o KexAlgorithms=curve25519-sha256@libssh.org' HUGO_FLAGS='' USER=seirdy@envs.net WWW_ROOT=/home/seirdy/public_html GEMINI_ROOT=/home/seirdy/public_gemini HUGO_BASEURL='https://envs.net/~seirdy/' OUTPUT_DIR=public_envs deploy
|
||||||
|
|
BIN
assets/p/b/indieweb.png
Normal file
BIN
assets/p/b/indieweb.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 524 B |
|
@ -41,7 +41,7 @@ Template markup to embed my 88x31 badge.
|
||||||
|
|
||||||
- Double the width and height in your HTML to `width="176" height="62"` to make them easier to read on higher-resolution screens.
|
- Double the width and height in your HTML to `width="176" height="62"` to make them easier to read on higher-resolution screens.
|
||||||
|
|
||||||
- The more consecutive badges you have, the shorter your alt-text should be. Balance the need for detail against the need to skim.
|
- The more consecutive badges you have, the shorter your average alt-text should be. Balance the need for detail against the need to skim.
|
||||||
|
|
||||||
- If you want to detect my button programmatically, consider the [`.well-known/button.json` schema](https://codeberg.org/LunarEclipse/well-known-button).
|
- If you want to detect my button programmatically, consider the [`.well-known/button.json` schema](https://codeberg.org/LunarEclipse/well-known-button).
|
||||||
|
|
||||||
|
@ -80,6 +80,7 @@ Read more about the design of this site in my [site design standards page]({{<re
|
||||||
|
|
||||||
<a href="https://www.mabsland.com/Adoption.html">{{<picture name="b/panda_14c" alt="Smug panda fursona next to the text “Web 14”." width="176" height="62" class="pix">}}</a>
|
<a href="https://www.mabsland.com/Adoption.html">{{<picture name="b/panda_14c" alt="Smug panda fursona next to the text “Web 14”." width="176" height="62" class="pix">}}</a>
|
||||||
<a href="https://tildeverse.org/">{{<picture name="b/tildeverse" alt="Tildeverse." width="176" height="62" class="pix">}}</a>
|
<a href="https://tildeverse.org/">{{<picture name="b/tildeverse" alt="Tildeverse." width="176" height="62" class="pix">}}</a>
|
||||||
|
<a href="https://indieweb.org/">{{<picture name="b/indieweb" alt="I W C Now! indieweb.org." width="176" height="62" class="pix">}}</a>
|
||||||
<a href="https://indieweb.org/Webmention">{{<picture name="b/webmentions" alt="Webmentions supported." width="176" height="62" class="pix">}}</a>
|
<a href="https://indieweb.org/Webmention">{{<picture name="b/webmentions" alt="Webmentions supported." width="176" height="62" class="pix">}}</a>
|
||||||
<a href="https://internet.nl/faqs/ipv6/">{{<picture name="b/ipv6" alt="The word “IPv6” next to a green checkmark." width="176" height="62" class="pix">}}</a>
|
<a href="https://internet.nl/faqs/ipv6/">{{<picture name="b/ipv6" alt="The word “IPv6” next to a green checkmark." width="176" height="62" class="pix">}}</a>
|
||||||
<a href="https://creativecommons.org/licenses/by-sa/4.0/">{{<picture name="b/cc-by-sa" alt="Creative Commons BY-SA license." width="176" height="62" class="pix">}}</a>
|
<a href="https://creativecommons.org/licenses/by-sa/4.0/">{{<picture name="b/cc-by-sa" alt="Creative Commons BY-SA license." width="176" height="62" class="pix">}}</a>
|
||||||
|
|
|
@ -59,6 +59,8 @@ Other lints/checks I run also use additional command-line utilities such as `sd`
|
||||||
|
|
||||||
#### Quick linters
|
#### Quick linters
|
||||||
|
|
||||||
|
- [fflint](https://www.fflint.dev/)
|
||||||
|
|
||||||
- Stylelint
|
- Stylelint
|
||||||
|
|
||||||
- [html-validate](https://html-validate.org/)
|
- [html-validate](https://html-validate.org/)
|
||||||
|
|
|
@ -63,7 +63,7 @@
|
||||||
<admin:errorReportsTo xmlns:admin="http://webns.net/mvcb/" rdf:resource="mailto:{{ .Site.Author.email }}" />
|
<admin:errorReportsTo xmlns:admin="http://webns.net/mvcb/" rdf:resource="mailto:{{ .Site.Author.email }}" />
|
||||||
<rights type="text">Copyright © {{ now.Year }} Rohan Kumar</rights>
|
<rights type="text">Copyright © {{ now.Year }} Rohan Kumar</rights>
|
||||||
<link rel="license" type="application/rdf+xml" href="https://creativecommons.org/licenses/by-sa/4.0/rdf" />
|
<link rel="license" type="application/rdf+xml" href="https://creativecommons.org/licenses/by-sa/4.0/rdf" />
|
||||||
<updated>{{ site.LastChange.UTC.Format "2006-01-02T15:04:05-07:00" | safeHTML }}</updated>
|
<updated>{{ site.Lastmod.UTC.Format "2006-01-02T15:04:05-07:00" | safeHTML }}</updated>
|
||||||
<generator uri="https://gohugo.io/" version="{{ .Site.Hugo.Version }}">Hugo {{ .Site.Hugo.Version }}</generator>
|
<generator uri="https://gohugo.io/" version="{{ .Site.Hugo.Version }}">Hugo {{ .Site.Hugo.Version }}</generator>
|
||||||
<id>{{ .Permalink }}</id>
|
<id>{{ .Permalink }}</id>
|
||||||
{{ range $pages -}}
|
{{ range $pages -}}
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
{{- $rewritesDict := dict "" "" -}}
|
{{- $rewritesDict := dict "" "" -}}
|
||||||
{{- range $i, $r := (getCSV "," "/csv/rewrites.csv") -}}
|
{{- range $i, $r := (resources.Get "csv/rewrites.csv" | transform.Unmarshal) -}}
|
||||||
{{- $rewritesDict = merge $rewritesDict (dict (index $r 0) (index $r 1)) -}}
|
{{- $rewritesDict = merge $rewritesDict (dict (index $r 0) (index $r 1)) -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
{{- return $rewritesDict -}}
|
{{- return $rewritesDict -}}
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
{{- $refPol = "strict-origin" -}}
|
{{- $refPol = "strict-origin" -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
<h2 id="webrings">Webrings</h2>
|
<h2 id="webrings">Webrings</h2>
|
||||||
{{ $webringData := after 1 (getCSV "," "/csv/webrings.csv") -}}
|
{{ $webringData := after 1 (resources.Get "csv/webrings.csv" | transform.Unmarshal) -}}
|
||||||
<p>This site is part of {{ len $webringData }} <a href="https://en.wikipedia.org/wiki/Webring">webrings</a>. A webring is a collection of sites in a circular doubly-linked list; each website links to the next and previous site in the list.</p>
|
<p>This site is part of {{ len $webringData }} <a href="https://en.wikipedia.org/wiki/Webring">webrings</a>. A webring is a collection of sites in a circular doubly-linked list; each website links to the next and previous site in the list.</p>
|
||||||
<details>
|
<details>
|
||||||
<summary>Toggle webrings list</summary>
|
<summary>Toggle webrings list</summary>
|
||||||
|
|
|
@ -12,7 +12,7 @@
|
||||||
{{ $dark_webp := resources.GetMatch (printf "/p/%s_dark.webp" (.Get "name")) -}}
|
{{ $dark_webp := resources.GetMatch (printf "/p/%s_dark.webp" (.Get "name")) -}}
|
||||||
{{ $dark_avif := resources.GetMatch (printf "/p/%s_dark.avif" (.Get "name")) -}}
|
{{ $dark_avif := resources.GetMatch (printf "/p/%s_dark.avif" (.Get "name")) -}}
|
||||||
{{ $dark_jxl := resources.GetMatch (printf "/p/%s_dark.jxl" (.Get "name")) -}}
|
{{ $dark_jxl := resources.GetMatch (printf "/p/%s_dark.jxl" (.Get "name")) -}}
|
||||||
|
{{ $alt := .Get "alt" -}}
|
||||||
{{- $orig_img := $light_png -}}
|
{{- $orig_img := $light_png -}}
|
||||||
{{- $orig_img_type := "image/png" -}}
|
{{- $orig_img_type := "image/png" -}}
|
||||||
{{- $orig_img_dark := $dark_png -}}
|
{{- $orig_img_dark := $dark_png -}}
|
||||||
|
@ -119,7 +119,7 @@
|
||||||
type="{{ $orig_img_type }}" />
|
type="{{ $orig_img_type }}" />
|
||||||
<img{{ with .Get "class" }} class="{{ . }}"{{ end }}
|
<img{{ with .Get "class" }} class="{{ . }}"{{ end }}
|
||||||
width="{{ $img_width }}" height="{{ $img_height }}"
|
width="{{ $img_width }}" height="{{ $img_height }}"
|
||||||
src="{{ $orig_src.Permalink }}" alt='{{ .Get "alt" }}'
|
src="{{ $orig_src.Permalink }}" alt="{{ $alt }}"
|
||||||
{{ with .Parent -}}
|
{{ with .Parent -}}
|
||||||
{{ if eq .Name "transcribed-image-figure" -}}
|
{{ if eq .Name "transcribed-image-figure" -}}
|
||||||
{{ with .Get "id" -}}
|
{{ with .Get "id" -}}
|
||||||
|
|
18
scripts/fflint.sh
Normal file
18
scripts/fflint.sh
Normal file
|
@ -0,0 +1,18 @@
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
#fflint json --show-tests all --show-detail "$output_dir/**/*.json"
|
||||||
|
set -e -u
|
||||||
|
output_dir="$1"
|
||||||
|
|
||||||
|
fflint_wrapper() {
|
||||||
|
fflint --fail-fast --progress=false --show-tests failing $*
|
||||||
|
}
|
||||||
|
|
||||||
|
cd "$output_dir"
|
||||||
|
find '.' -type f -name "*.jpg" | fflint_wrapper --height 1-1500 --width 1-1500 jpeg @-
|
||||||
|
find '.' -type f -name "*.png" | fflint_wrapper --height 1-1500 --width 1-1500 png @-
|
||||||
|
find '.' -type f -name "*.json" -o -name ".webmanifest" | fflint_wrapper json @-
|
||||||
|
find '.' -type f -name "*.html" | fflint_wrapper html @-
|
||||||
|
find '.' -type f -name "*.svg" | fflint_wrapper --height 1-1500 --width 1-1500 svg @-
|
||||||
|
find '.' -type f -name "*.txt" -o -name "*.gmi" -o -name "*.asc" | fflint_wrapper text @-
|
||||||
|
find '.' -type f -name "*.xhtml" -o -name "*.xml" | fflint_wrapper xml @-
|
|
@ -15,8 +15,8 @@ set -e -u
|
||||||
progname="$(basename "$0")"
|
progname="$(basename "$0")"
|
||||||
dirname="$(dirname "$0")"
|
dirname="$(dirname "$0")"
|
||||||
|
|
||||||
webrings_src="$dirname/../csv/webrings.base.csv"
|
webrings_src="$dirname/../assets/csv/webrings.base.csv"
|
||||||
webrings_dest="$dirname/../csv/webrings.csv"
|
webrings_dest="$dirname/../assets/csv/webrings.csv"
|
||||||
|
|
||||||
help_text="Usage: $progname [OPTION...]
|
help_text="Usage: $progname [OPTION...]
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue