feat(ci): skip opencode re-download on cache hit
ci / lint (push) Skipped
ci / lint (pull_request) Successful in 11s
ci / lint (push) Skipped
ci / lint (pull_request) Successful in 11s
This commit is contained in:
@@ -9,7 +9,14 @@ set -eu
|
||||
# --format json event schema that build-activity-log.sh parses) breaks every agent in every repo
|
||||
# at once. Bump deliberately by changing this default (or set OPENCODE_VERSION in the step env).
|
||||
OPENCODE_VERSION="${OPENCODE_VERSION:-1.17.13}"
|
||||
# Skip the download when a cache hit already restored the pinned binary (see the Cache
|
||||
# opencode CLI step in agent.yml). The installer always re-fetches otherwise.
|
||||
OC_BIN="$HOME/.opencode/bin/opencode"
|
||||
if [ -x "$OC_BIN" ] && "$OC_BIN" --version 2>/dev/null | grep -qF "$OPENCODE_VERSION"; then
|
||||
echo "opencode $OPENCODE_VERSION already present (cache hit) — skipping install"
|
||||
else
|
||||
curl -fsSL https://opencode.ai/install | bash -s -- --version "$OPENCODE_VERSION"
|
||||
fi
|
||||
echo "$HOME/.opencode/bin" >> "$GITHUB_PATH"
|
||||
mkdir -p ~/.config/opencode
|
||||
# Playwright browser MCP only for agents that need to drive a web app
|
||||
|
||||
Reference in New Issue
Block a user