diff options
author | EuAndreh <eu@euandre.org> | 2023-04-05 16:14:00 -0300 |
---|---|---|
committer | EuAndreh <eu@euandre.org> | 2023-04-05 16:14:00 -0300 |
commit | 24e24b49fb6375189cfa527a113eb965087a293a (patch) | |
tree | fc75f8267a22f6473432ee6b07c4013561c303dc /v2/src/bin/security-txt | |
parent | v2: Recove h[2-6] anchor link and icon (diff) | |
download | euandre.org-24e24b49fb6375189cfa527a113eb965087a293a.tar.gz euandre.org-24e24b49fb6375189cfa527a113eb965087a293a.tar.xz |
v2: Support Atom feeds and collection translations
Diffstat (limited to '')
-rwxr-xr-x | v2/src/bin/security-txt (renamed from v2/src/development/security-txt.sh.in) | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/v2/src/development/security-txt.sh.in b/v2/src/bin/security-txt index 8f6613f..7026969 100755 --- a/v2/src/development/security-txt.sh.in +++ b/v2/src/bin/security-txt @@ -4,8 +4,8 @@ set -eu usage() { cat <<-'EOF' Usage: - src/development/security-txt.sh - src/development/security-txt.sh -h + security-txt + security-txt -h EOF } @@ -25,7 +25,7 @@ help() { Just run it: - $ sh src/development/security-txt.sh > .well-known/security.txt + $ security-txt > .well-known/security.txt EOF } @@ -62,21 +62,21 @@ shift $((OPTIND - 1)) EXPIRES="$( - LANG=C.UTF-8 gpg --list-key eu@euandre.org | + LANG=C.UTF-8 gpg --list-key "$EMAIL" | awk '/^pub/ { print substr($(NF), 1, 10) }' )T00:00:00z" -LANGS="en$( - echo po/??.po | - sed 's|\.po$||' | - sed 's|^po/|, |' | - paste -sd, +LANGUAGES="$( + langs | + sed 's|^|, |' | + tr -d '\n' | + sed 's|^, ||' )" cat <<-EOF - Contact: mailto:@EMAIL@ - Encryption: https://@DOMAIN@/public.asc.txt + Contact: mailto:$EMAIL + Encryption: $(url-for 'public.asc.txt' | absolute) Expires: $EXPIRES - Preferred-Languages: $LANGS + Preferred-Languages: $LANGUAGES EOF |