diff options
Diffstat
| -rw-r--r-- | .forgejo/workflows/build.yml | 17 | +14 −3 |
| -rw-r--r-- | pkg/logo.svg | 2 | +1 −1 |
| -rwxr-xr-x | tests/smoke/run-local.sh | 10 | +4 −6 |
3 files changed, 19 insertions, 10 deletions
diff --git a/.forgejo/workflows/build.yml b/.forgejo/workflows/build.yml index a9b3454..6bd6b89 100644 --- a/.forgejo/workflows/build.yml +++ b/.forgejo/workflows/build.yml @@ -30,8 +30,6 @@ jobs: - name: Check formatting run: cargo fmt --all --check - - name: Run clippy - run: cargo clippy --all-targets --all-features -- -D warnings build: name: Build (${{ matrix.arch }}) @@ -54,6 +52,7 @@ jobs: passphrase: ${{ secrets.GPG_PASSPHRASE }} gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }} + - run: cargo clippy --all-targets --all-features --release -- -D warnings - run: cargo build --release - run: cargo test --all-features --release --locked @@ -90,6 +89,11 @@ jobs: name: packages-${{ matrix.arch }} path: dist/* + - uses: https://code.forgejo.org/forgejo/upload-artifact@cb8afe72b42edc798abfb8fcb556cf660d894245 # v5 + with: + name: binary-${{ matrix.arch }} + path: target/release/recluse + smoke: name: Smoke tests runs-on: [ubuntu-24.04, x86_64] @@ -98,8 +102,15 @@ jobs: steps: - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1 + - uses: https://code.forgejo.org/forgejo/download-artifact@1314311ddb542af343a82d478ac786ceada4143a # v5 + with: + name: binary-amd64 + path: target/release/ + - name: Run smoke tests against local instance - run: ./tests/smoke/run-local.sh + run: | + chmod +x target/release/recluse + ./tests/smoke/run-local.sh publish: name: Publish nightly build diff --git a/pkg/logo.svg b/pkg/logo.svg index 25cd3ec..4356e61 100644 --- a/pkg/logo.svg +++ b/pkg/logo.svg @@ -5,7 +5,7 @@ SPDX-License-Identifier: AGPL-3.0-or-later <?xml version="1.0" encoding="UTF-8" standalone="no"?> <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"> -<svg viewBox="-150 -150 800 800" xmlns="http://www.w3.org/2000/svg" fill="rgb(247, 164, 29)"> +<svg viewBox="-150 -150 800 800" xmlns="http://www.w3.org/2000/svg" fill="#00afaf"> <rect x="0" y="100" width="100" height="100"></rect> <rect x="0" y="200" width="100" height="100"></rect> <rect x="0" y="300" width="100" height="100"></rect> diff --git a/tests/smoke/run-local.sh b/tests/smoke/run-local.sh index 32193dd..313890b 100755 --- a/tests/smoke/run-local.sh +++ b/tests/smoke/run-local.sh @@ -2,7 +2,8 @@ # SPDX-FileCopyrightText: 2026 Nikolay Govorov <me@govorov.online> # SPDX-License-Identifier: AGPL-3.0-or-later -# Builds recluse, starts it in a temporary directory, runs smoke tests, cleans up. +# Starts recluse in a temporary directory, runs smoke tests, cleans up. +# Expects a prebuilt binary at target/release/recluse (run `cargo build --release` first). # # Usage: # ./tests/smoke/run-local.sh # default port 2025 @@ -10,6 +11,7 @@ set -euo pipefail +BIN="target/release/recluse" PORT="${RECLUSE_PORT:-2025}" BASE_URL="http://127.0.0.1:${PORT}" @@ -17,10 +19,6 @@ TMPDIR="$(mktemp -d)" LOGFILE="$TMPDIR/recluse.log" trap 'kill "$PID" 2>/dev/null; wait "$PID" 2>/dev/null; rm -rf "$TMPDIR"' EXIT -# Build -echo "Building recluse..." -cargo build --release -p recluse - # Write minimal config cat > "$TMPDIR/recluse.toml" <<EOF appname = "smoke" @@ -49,7 +47,7 @@ mkdir -p "$TMPDIR/state" # Start recluse echo "Starting recluse on ${BASE_URL}..." echo "Server log: ${LOGFILE}" -cargo run --release -p recluse -- --config="$TMPDIR/recluse.toml" >"$LOGFILE" 2>&1 & +"$BIN" --config="$TMPDIR/recluse.toml" >"$LOGFILE" 2>&1 & PID=$! # Wait for index to load (log shows "index refreshed" for each backend) |
