#!/bin/bash set -e echo "Publishing project..." dotnet publish -c Release -r linux-x64 -o ./publish echo "Finding binary..." BINARY=$(find ./publish -type f -name "anchor" | head -n 1) if [ -z "$BINARY" ]; then echo "Error: Could not find binary in ./publish" exit 1 fi echo "Found binary: $BINARY" echo "Copying to /usr/bin..." sudo cp "$BINARY" /usr/bin/ echo "Installation complete!"