hackertours/layouts/_partials/lint-brand.html
Vincent Mahnke efab84c6ae
All checks were successful
/ build (pull_request) Successful in 1m16s
/ accessibility (pull_request) Successful in 1m59s
/ cleanup-staging (pull_request) Successful in 36s
fix: Normalizes any bodycopy to "Hackertours" casing
2026-11-07 19:37:14 +01:00

15 lines
820 B
HTML

{{- with .File -}}
{{- $file := . -}}
{{- $source := readFile .Filename -}}
{{- range $index, $line := split $source "\n" -}}
{{- if not (findRE `(?:#\s*hackertours-lint-ignore|<!--\s*hackertours-lint-ignore\s*-->)\s*$` $line) -}}
{{- $text := replaceRE `\]\([^)]*\)` "]" $line -}}
{{- $text = replaceRE `(?i)(?:https?://|mailto:|www\.)[^\s<>"']+|[[:alnum:]._%+-]+@[[:alnum:]._-]+|@[[:alnum:]_]+|#[[:alnum:]_-]+:[[:alnum:]._-]+` "" $text -}}
{{- range findRE `(?i)\bhackertours\b` $text -}}
{{- if ne . "Hackertours" -}}
{{- errorf "%s:%d: %q should be \"Hackertours\" (different casing) - to ignore this, add a hackertours-lint-ignore comment on this line" $file.Filename (add $index 1) . -}}
{{- end -}}
{{- end -}}
{{- end -}}
{{- end -}}
{{- end -}}