mirror of
https://git.sr.ht/~seirdy/seirdy.one
synced 2024-11-10 00:12:09 +00:00
More whitespace fixes
This commit is contained in:
parent
89139337d1
commit
672d89d007
4 changed files with 8 additions and 9 deletions
|
@ -1,9 +1,9 @@
|
||||||
<article class="h-entry hentry"><!--Once WAI-ARIA 1.3 gains traction, I'll add aria-details for webmentions.-->
|
<article class="h-entry hentry"><!--Once WAI-ARIA 1.3 gains traction, I'll add aria-details for webmentions.-->
|
||||||
<header>
|
<header>
|
||||||
<h1 itemprop="name headline" class="p-name entry-title">{{ .Title }}</h1>
|
<h1 itemprop="name headline" class="p-name entry-title">{{ .Title }}</h1>
|
||||||
{{ if not .Params.disableMeta -}}
|
{{- if not .Params.disableMeta -}}
|
||||||
{{- partial "post-meta.html" . }}
|
{{- partial "post-meta.html" . -}}
|
||||||
{{- end }}
|
{{- end -}}
|
||||||
<hr />
|
<hr />
|
||||||
</header>
|
</header>
|
||||||
<div class="e-content entry-content" itemprop="articleBody">
|
<div class="e-content entry-content" itemprop="articleBody">
|
||||||
|
|
|
@ -16,4 +16,4 @@
|
||||||
{{- if not $isNotes -}}
|
{{- if not $isNotes -}}
|
||||||
<br />
|
<br />
|
||||||
{{ partial "wordcount.html" . -}}
|
{{ partial "wordcount.html" . -}}
|
||||||
{{ end }}
|
{{- end -}}
|
||||||
|
|
|
@ -3,9 +3,9 @@
|
||||||
{{- $thousands := string (div .WordCount 1000) -}}
|
{{- $thousands := string (div .WordCount 1000) -}}
|
||||||
{{- $displayCount = printf "%s thousand" $thousands -}}
|
{{- $displayCount = printf "%s thousand" $thousands -}}
|
||||||
About
|
About
|
||||||
{{- end }}
|
{{- end -}}
|
||||||
<data itemprop="wordCount" value="{{ .WordCount }}">
|
<data itemprop="wordCount" value="{{ .WordCount }}">
|
||||||
{{ $displayCount }}
|
{{- $displayCount -}}
|
||||||
</data> words
|
</data> words
|
||||||
{{- with .ReadingTime -}}
|
{{- with .ReadingTime -}}
|
||||||
{{- $displayTime := string . -}}
|
{{- $displayTime := string . -}}
|
||||||
|
@ -14,6 +14,6 @@ About
|
||||||
{{- $minutes := mod . 60 -}}
|
{{- $minutes := mod . 60 -}}
|
||||||
{{- $displayTime = (printf "%d hour and %d" $hours $minutes) | safeHTML -}}
|
{{- $displayTime = (printf "%d hour and %d" $hours $minutes) | safeHTML -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
; a{{ if lt . 10 }} short{{ else if and (gt . 20) (lt . 30) }} somewhat long{{ else if and (gt . 29) (lt . 60) }} long{{ else if gt . 59 }} very long{{ end }}
|
; a{{ if lt . 10 }} short{{ else if and (gt . 20) (lt . 30) }} somewhat long{{ else if and (gt . 29) (lt . 60) }} long{{ else if gt . 59 }} very long {{ end -}}
|
||||||
<time itemprop="timeRequired" datetime="PT{{ . }}M">{{ $displayTime }} minute</time> read
|
<time itemprop="timeRequired" datetime="PT{{ . }}M">{{ $displayTime }} minute</time> read
|
||||||
{{- end }}
|
{{- end -}}
|
||||||
|
|
|
@ -5,7 +5,6 @@
|
||||||
# XML tooling.
|
# XML tooling.
|
||||||
# this means that every index.html file has an equivalent index.xhtml file.
|
# this means that every index.html file has an equivalent index.xhtml file.
|
||||||
# content negotiation allows an agent to pick html or xhtml.
|
# content negotiation allows an agent to pick html or xhtml.
|
||||||
# echo "<?xml version=\"1.0\" encoding=\"UTF-8\"?>"
|
|
||||||
|
|
||||||
find "$1" -type f -name '*.html' \
|
find "$1" -type f -name '*.html' \
|
||||||
-exec sh -c 'echo "<?xml version=\"1.0\" encoding=\"UTF-8\"?>" >"${0%*.html}.xhtml" && xmlfmt -i " " -f "$0" | busybox sed -e :a -e "/./,\$!d;/^\n*\$/{\$d;N;};/\n\$/ba" | sd -f m "\n(?:\t*)?</" "</" | sd -f m "<pre>\n\t*<code" "<pre><code" | sd -f m "\(\n\t*<abbr" "(<abbr" | pee "sed 5d >>\"${0%*.html}.xhtml\"" "sponge \"$0\""' {} \;
|
-exec sh -c 'echo "<?xml version=\"1.0\" encoding=\"UTF-8\"?>" >"${0%*.html}.xhtml" && xmlfmt -i " " -f "$0" | busybox sed -e :a -e "/./,\$!d;/^\n*\$/{\$d;N;};/\n\$/ba" | sd -f m "\n(?:\t*)?</" "</" | sd -f m "<pre>\n\t*<code" "<pre><code" | sd -f m "\(\n\t*<abbr" "(<abbr" | pee "sed 5d >>\"${0%*.html}.xhtml\"" "sponge \"$0\""' {} \;
|
||||||
|
|
Loading…
Reference in a new issue