Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 4 additions & 8 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ jobs:
name: Build ${{ matrix.suffix }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- goos: linux
Expand All @@ -27,10 +28,6 @@ jobs:
- goos: darwin
goarch: arm64
suffix: darwin-arm64
- goos: windows
goarch: amd64
suffix: windows-amd64
ext: .exe

steps:
- uses: actions/checkout@v4
Expand All @@ -50,7 +47,7 @@ jobs:
go build \
-trimpath \
-ldflags="-s -w -X main.version=${{ github.ref_name }}" \
-o dist/seshat-${{ matrix.suffix }}${{ matrix.ext || '' }} \
-o dist/seshat-${{ matrix.suffix }} \
./cmd/cli

- name: Build gRPC server
Expand All @@ -62,7 +59,7 @@ jobs:
go build \
-trimpath \
-ldflags="-s -w -X main.version=${{ github.ref_name }}" \
-o dist/seshat-grpc-${{ matrix.suffix }}${{ matrix.ext || '' }} \
-o dist/seshat-grpc-${{ matrix.suffix }} \
./cmd/grpc

- name: Upload artifacts
Expand All @@ -89,6 +86,5 @@ jobs:
- name: Create GitHub Release
uses: softprops/action-gh-release@v2
with:
files: |
dist/**
files: dist/**
generate_release_notes: true
13 changes: 12 additions & 1 deletion scripts/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,17 @@

set -euo pipefail

# Portable SHA256 check: sha256sum (Linux) or shasum -a 256 (macOS)
_sha256check() {
if command -v sha256sum &>/dev/null; then
sha256sum --check --status
elif command -v shasum &>/dev/null; then
shasum -a 256 --check --status
else
error "No SHA256 tool found (sha256sum or shasum)" ; exit 1
fi
}

REPO="EngineerProjects/seshat"
BINARY="seshat"
INSTALL_DIR="${INSTALL_DIR:-$HOME/.local/bin}"
Expand Down Expand Up @@ -104,7 +115,7 @@ _dl "$BASE_URL/SHA256SUMS.txt" "$TMP_DIR/SHA256SUMS.txt"
# ── Verify checksum ───────────────────────────────────────────────────────────
step "Verifying checksum"

(cd "$TMP_DIR" && grep "$BIN_ASSET" SHA256SUMS.txt | sha256sum --check --status) \
(cd "$TMP_DIR" && grep "$BIN_ASSET" SHA256SUMS.txt | _sha256check) \
|| { error "Checksum verification failed — aborting."; exit 1; }
success "Checksum OK"

Expand Down
Loading