mirror of
https://seed.radicle.dev/rad:z4V1sjrXqjvFdnCUbxPFqd5p4DtH5.git
synced 2026-10-18 19:30:27 +08:00
Integrate radicle-artifact into explorer
- Add release read API to httpd as cargo feature enabled by default - Add Releases and Release views to the UI - Filter out redacted artifacts and mark delegate authors - Degrade releases UI gracefully with older radicle-httpd versions - Hide fully redacted releases - Skip releases in the list endpoint when every artifact was redacted by its author or a delegate, so no empty release entries are shown - Keep them reachable with showRedacted=true and by release id - Add e2e tests for the release routes Co-Authored-By: Rūdolfs Ošiņš <rudolfs@osins.org>
This commit is contained in:
co-authored by
Rūdolfs Ošiņš
parent
8f2ddcf489
commit
b1acb3eb4d
@@ -4,10 +4,13 @@ set -e
|
||||
REPO_ROOT=$(git rev-parse --show-toplevel 2>/dev/null || echo "$PWD")
|
||||
RELEASE=$(cat "$REPO_ROOT/tests/support/heartwood-release")
|
||||
HTTPD_RELEASE=$(cat "$REPO_ROOT/tests/support/radicle-httpd-release")
|
||||
ARTIFACT_RELEASE=$(cat "$REPO_ROOT/tests/support/radicle-artifact-release")
|
||||
BINARY_PATH=$REPO_ROOT/tests/tmp/bin
|
||||
OS=$(uname)
|
||||
|
||||
install() {
|
||||
local BINARY=""
|
||||
|
||||
if test -d "$BINARY_PATH/$1/$2"; then
|
||||
echo ✅ "Folder $BINARY_PATH/$1/$2 exists already skipping download."
|
||||
else
|
||||
@@ -32,13 +35,23 @@ install() {
|
||||
FETCH_URL="https://files.radicle.dev/releases/radicle-httpd/$2/radicle-httpd-$ARCH.tar.xz"
|
||||
FILENAME="radicle-httpd-$2-$ARCH"
|
||||
;;
|
||||
artifact)
|
||||
# radicle-artifact publishes bare executables instead of archives.
|
||||
FETCH_URL="https://files.radicle.dev/releases/radicle-artifact/$2/rad-artifact_$2_$ARCH"
|
||||
BINARY="rad-artifact"
|
||||
;;
|
||||
*)
|
||||
echo "No precompiled binary found with the name $1." && exit 1
|
||||
;;
|
||||
esac
|
||||
|
||||
echo Downloading "$1" v"$2" from "$FETCH_URL into /tests/tmp/bin/$1/$2"
|
||||
curl --fail --silent --location "$FETCH_URL" | tar -xJ --strip-components=2 -C "$BINARY_PATH/$1/$2" "$FILENAME/bin/" || (echo "Download failed" && exit 1)
|
||||
if test -n "$BINARY"; then
|
||||
curl --fail --silent --location --output "$BINARY_PATH/$1/$2/$BINARY" "$FETCH_URL" || (echo "Download failed" && exit 1)
|
||||
chmod +x "$BINARY_PATH/$1/$2/$BINARY"
|
||||
else
|
||||
curl --fail --silent --location "$FETCH_URL" | tar -xJ --strip-components=2 -C "$BINARY_PATH/$1/$2" "$FILENAME/bin/" || (echo "Download failed" && exit 1)
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
@@ -65,5 +78,6 @@ done
|
||||
|
||||
install "heartwood" "$RELEASE"
|
||||
install "httpd" "$HTTPD_RELEASE"
|
||||
install "artifact" "$ARTIFACT_RELEASE"
|
||||
|
||||
echo
|
||||
|
||||
Reference in New Issue
Block a user