From 774a5b48cdae4bcf61762d8e0eec7e8931a10792 Mon Sep 17 00:00:00 2001 From: Lorenz Leutgeb Date: Sat, 2 May 2026 16:18:49 +0200 Subject: [PATCH] releases: Generate Information at Build Time Instead of requiring JavaScript to dynamically fetch release metadata, generate at build time of the website, and only use JavaScript to change the data if it does not match what is served by files.radicle.dev. This allows users to obtain information about releases and download URLs without having JavaScript enabled. --- Makefile | 11 +- _config.yml | 13 +++ _data/author/alexis.yml | 5 + _data/author/fintan.yml | 5 + _data/author/rudolfs.yml | 5 + _data/releases/radicle-httpd.json | 1 + _data/releases/radicle.json | 1 + _includes/latest-release.html | 42 ++----- _pages/download.md | 177 +++++++++--------------------- assets/css/page.css | 4 - 10 files changed, 100 insertions(+), 164 deletions(-) create mode 100644 _data/releases/radicle-httpd.json create mode 100644 _data/releases/radicle.json diff --git a/Makefile b/Makefile index abd582b..ede83cb 100644 --- a/Makefile +++ b/Makefile @@ -1,11 +1,18 @@ +FILES := https://files.radicle.dev + default: build -build: +build: releases bundle exec jekyll build $(CONFIG) -serve: +serve: releases bundle exec jekyll serve $(CONFIG) --port 3000 --livereload +# NOTE: Manually keep these consistent with `_config.yml`. +releases: + curl -s -o _data/releases/radicle.json $(FILES)/releases/latest/radicle.json + curl -s -o _data/releases/radicle-httpd.json $(FILES)/releases/radicle-httpd/latest/radicle-httpd.json + dependencies: gem install jekyll diff --git a/_config.yml b/_config.yml index 86681b8..744daf9 100644 --- a/_config.yml +++ b/_config.yml @@ -30,6 +30,19 @@ include: - _redirects - .well-known +releases: + - id: radicle + base: "https://files.radicle.dev/releases/latest" + name: Radicle + signers: + - alexis + - fintan + - id: radicle-httpd + base: "https://files.radicle.dev/releases/radicle-httpd/latest" + name: Radicle HTTP Daemon + signers: + - rudolfs + # Metadata title: "Radicle: the sovereign forge" description: "The Radicle forge is an open source, peer-to-peer code collaboration stack built on Git." diff --git a/_data/author/alexis.yml b/_data/author/alexis.yml index 3532c7c..e2bb532 100644 --- a/_data/author/alexis.yml +++ b/_data/author/alexis.yml @@ -4,3 +4,8 @@ radicle: age: age1jf5fhwgtr4lpdsgjz2lu0s839eutm7g39y5ya7sw747y0sl204rsdl6zvn web: cloudhead.io atproto: cloudhead.io + +signing: + email: cloudhead@radicle.dev + fingerprint: SHA256:iTDjRHSIaoL8dpHbQ0mv+y0IQqPufGl2hQwk4TbXFlw + key: ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIL460KIEccS4881p7PPpiiQBsxF+H5tgC6De6crw9rbU \ No newline at end of file diff --git a/_data/author/fintan.yml b/_data/author/fintan.yml index 1f4cc12..870dfe1 100644 --- a/_data/author/fintan.yml +++ b/_data/author/fintan.yml @@ -3,3 +3,8 @@ radicle: did: did:key:z6MkireRatUThvd3qzfKht1S44wpm4FEWSSa4PRMTSQZ3voM age: age1l7yzgrhnxrmjszklf0l2vpfxh0l57swe9jh2qnyh5hjq8vrecassw9vg98 atproto: fintohaps.bsky.social + +signing: + email: fintan@radicle.dev + fingerprint: SHA256:vV38nW5eSWfTMITdAoMCBOFzEEr0bDMXjSWHpwrpsKY + key: ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIEFsaRqAJ1r6bBFwlcWzJKN7DdjItQDumCNc0wqw6Dvk \ No newline at end of file diff --git a/_data/author/rudolfs.yml b/_data/author/rudolfs.yml index e43ef8b..8117711 100644 --- a/_data/author/rudolfs.yml +++ b/_data/author/rudolfs.yml @@ -2,3 +2,8 @@ name: rudolfs radicle: did: did:key:z6MkwPUeUS2fJMfc2HZN1RQTQcTTuhw4HhPySB8JeUg2mVvx atproto: osins.bsky.social + +signing: + email: rudolfs@osins.org + fingerprint: SHA256:s/6EWLSAoeZWREZxj8vr6FtM6NaDjWhwsGB80eoaSzs + key: ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPueml1FxzjvwbD7vRZfwoaoyuxLy0L+WLBwSNiVoJe5 \ No newline at end of file diff --git a/_data/releases/radicle-httpd.json b/_data/releases/radicle-httpd.json new file mode 100644 index 0000000..aefcbec --- /dev/null +++ b/_data/releases/radicle-httpd.json @@ -0,0 +1 @@ +{ "name": "radicle-httpd", "version": "0.25.0", "commit": "5a3337de", "timestamp": "1776953069" } diff --git a/_data/releases/radicle.json b/_data/releases/radicle.json new file mode 100644 index 0000000..f39c472 --- /dev/null +++ b/_data/releases/radicle.json @@ -0,0 +1 @@ +{"name":"rad","version":"1.8.0","commit":"edde15d9ea700a70de04558fafc0b55360e9f5d2","timestamp":"1774539562"} diff --git a/_includes/latest-release.html b/_includes/latest-release.html index aa09383..fa46628 100644 --- a/_includes/latest-release.html +++ b/_includes/latest-release.html @@ -6,61 +6,39 @@ width: 100%; overflow: hidden; } - .loading .release-info { - display: none; - } - .loading .release-loader { - display: inline-block; - } - .release-loader { - display: none; - border: 2px solid var(--color-border-hint); - border-top: 2px solid var(--color-border-default); - border-right: 2px solid var(--color-border-default); - border-radius: 50%; - height: 1rem; - width: 1rem; - animation: spin 1s linear infinite; - } #release-timestamp, #release-commit { color: var(--color-fg-dim); } - .hidden { - display: none !important; - } - - @keyframes spin { - 0% { transform: rotate(0deg); } - 100% { transform: rotate(360deg); } - } -