From 5110f3bb64352ee4d833fb00fba27c80503f8041 Mon Sep 17 00:00:00 2001 From: Mateusz <169154504+donbagger@users.noreply.github.com> Date: Mon, 16 Nov 2026 09:41:40 +0100 Subject: [PATCH] Check both tutorials install and parse on GitHub Actions Neither tutorial can run in CI without Telegram or Anthropic credentials, so the workflow checks what it can: crypto-alert-bot installs on Node 22 and every .js file passes node --check; technical-indicators-agent installs on Python 3.12 and agent.py compiles. Runs on pushes to main and every PR, GITHUB_TOKEN limited to contents: read. Checked locally: both pass; a syntax error added to start.js fails the check. --- .github/workflows/ci.yml | 41 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..755ad36 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,41 @@ +name: CI + +on: + push: + branches: [main] + pull_request: + +permissions: + contents: read + +# The tutorials need Telegram and Anthropic credentials to run, so CI checks +# what it can without them: dependencies install and every file parses. +jobs: + crypto-alert-bot: + runs-on: ubuntu-latest + defaults: + run: + working-directory: crypto-alert-bot + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 + with: + node-version: '22' + # package-lock.json is gitignored, so install resolves fresh, as a reader's would. + - run: npm install --no-audit --no-fund + - name: Syntax check + run: for f in $(git ls-files '*.js'); do node --check "$f"; done + + technical-indicators-agent: + runs-on: ubuntu-latest + defaults: + run: + working-directory: technical-indicators-agent + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 + with: + python-version: '3.12' + - run: pip install -r requirements.txt + - name: Syntax check + run: python -m py_compile agent.py