mirror of
https://github.com/simplex-chat/simplex-chat.git
synced 2026-11-11 18:17:46 +00:00
ci: install ui as a command for the Claude job
A wrapper in /usr/local/bin runs the helper from the checkout, so Claude's Bash tool finds ui on PATH whatever environment it builds for its shell. First Claude run: [claude-test]
This commit is contained in:
1 parent
0c73033192
commit
499cab08fd
2 files changed
+6
-3
No files matched your search
@@ -379,10 +379,13 @@ jobs:
|
||||
working-directory: apps/multiplatform
|
||||
run: ./gradlew --no-daemon --console=plain -Psimplex.assets.dir=../../assets :desktop:createDistributable
|
||||
|
||||
- name: Install Claude Code
|
||||
# ui goes on every shell's PATH, where Claude's Bash tool finds it whatever environment it builds
|
||||
- name: Install Claude Code and the ui command
|
||||
run: |
|
||||
npm install --prefix "$RUNNER_TEMP/claude-code" "@anthropic-ai/claude-code@$CLAUDE_CODE_VERSION"
|
||||
echo "$RUNNER_TEMP/claude-code/node_modules/.bin" >> "$GITHUB_PATH"
|
||||
printf '#!/bin/sh\nexec %s/scripts/ci/desktop-linux/ui "$@"\n' "$PWD" | sudo tee /usr/local/bin/ui
|
||||
sudo chmod +x /usr/local/bin/ui
|
||||
|
||||
- name: Start the app at the chat list
|
||||
run: scripts/ci/desktop-linux/smoke-test.sh apps/multiplatform/release/main/app/simplex "$RUNNER_TEMP/claude-test/screens" onboarding
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
# Runs Claude Code to repeat the directory search with the ui helper, as claude-test.md describes, and passes when
|
||||
# its final message ends with "CLAUDE-TEST: PASS".
|
||||
# Usage: scripts/ci/desktop-linux/claude-test.sh <output dir> <transcript .jsonl>
|
||||
# Expects the app at the chat list (smoke-test.sh ... onboarding) with UI_OUT under <output dir>, claude on PATH,
|
||||
# Expects the app at the chat list (smoke-test.sh ... onboarding) with UI_OUT under <output dir>, claude and ui on PATH,
|
||||
# CLAUDE_MODEL and CLAUDE_CODE_OAUTH_TOKEN. Claude works in <output dir>: the screenshots, its report.md and the
|
||||
# prompt it was given end up there. The transcript is kept outside it, where Claude can't write.
|
||||
|
||||
@@ -29,7 +29,7 @@ EOF
|
||||
claude --version
|
||||
cd "$out"
|
||||
status=0
|
||||
PATH="$here:$PATH" claude -p "$(cat prompt.md)" \
|
||||
claude -p "$(cat prompt.md)" \
|
||||
--model "$CLAUDE_MODEL" \
|
||||
--max-turns 60 \
|
||||
--max-budget-usd 4 \
|
||||
|
||||
Reference in new issue
Block a user