Add macOS-arm64 MCP binary, update Roopik #225
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Build Linux | |
| on: | |
| push: | |
| branches: [ main, develop ] | |
| pull_request: | |
| branches: [ main, develop ] | |
| workflow_dispatch: # Manual trigger | |
| concurrency: | |
| group: build-linux-${{ github.ref }} | |
| cancel-in-progress: false | |
| jobs: | |
| build-linux-x64: | |
| name: Build Linux (x64) | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 120 | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v6 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v6 | |
| with: | |
| node-version-file: '.nvmrc' | |
| cache: 'npm' | |
| - name: Setup Python 3 | |
| uses: actions/setup-python@v6 | |
| with: | |
| python-version: '3.11' | |
| - name: Install tsx (TypeScript runner) | |
| run: npm install -g tsx | |
| - name: Setup GCC | |
| uses: egor-tensin/setup-gcc@v1 | |
| with: | |
| version: 10 | |
| platform: x64 | |
| - name: Install build dependencies | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y \ | |
| dpkg-dev \ | |
| fakeroot \ | |
| build-essential \ | |
| pkg-config \ | |
| libkrb5-dev | |
| - name: Run preinstall script manually | |
| run: tsx build/npm/preinstall.ts | |
| - name: Install dependencies (skip scripts) | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| run: npm install --ignore-scripts | |
| - name: Run postinstall script manually | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| run: tsx build/npm/postinstall.ts | |
| - name: Install native module build dependencies | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y \ | |
| libx11-dev \ | |
| libxkbfile-dev \ | |
| libkrb5-dev \ | |
| libsecret-1-dev | |
| - name: Rebuild native modules | |
| run: npm rebuild | |
| - name: Generate DOM whitelist from MDN | |
| run: node build/scripts/generateDOMWhitelist.mjs | |
| - name: Install roopik-roo extension dependencies | |
| working-directory: extensions/roopik-roo | |
| run: | | |
| if ! npm install; then | |
| echo "Normal install failed, trying with --legacy-peer-deps..." | |
| npm install --legacy-peer-deps | |
| node ../../.github/scripts/install-all-peer-deps.js || true | |
| fi | |
| - name: Install @roo-code/types dependencies | |
| working-directory: extensions/roopik-roo/packages/types | |
| run: npm install | |
| - name: Build @roo-code/types package | |
| working-directory: extensions/roopik-roo/packages/types | |
| run: npm run build | |
| - name: Install @roo-code/build dependencies | |
| working-directory: extensions/roopik-roo/packages/build | |
| run: npm install | |
| - name: Build @roo-code/build package | |
| working-directory: extensions/roopik-roo/packages/build | |
| run: npm run build | |
| - name: Create .env file for roopik-roo | |
| working-directory: extensions/roopik-roo | |
| env: | |
| ROO_CODE_API_URL: ${{ secrets.ROO_CODE_API_URL || 'https://app.roocode.com' }} | |
| ROO_CODE_PROVIDER_URL: ${{ secrets.ROO_CODE_PROVIDER_URL || 'https://app.roocode.com/proxy/v1' }} | |
| POSTHOG_API_KEY: ${{ secrets.POSTHOG_API_KEY || '' }} | |
| run: | | |
| cat > .env << EOF | |
| ROO_CODE_API_URL=${ROO_CODE_API_URL} | |
| ROO_CODE_PROVIDER_URL=${ROO_CODE_PROVIDER_URL} | |
| POSTHOG_API_KEY=${POSTHOG_API_KEY} | |
| EOF | |
| - name: Build roopik-roo extension | |
| working-directory: extensions/roopik-roo | |
| run: npm run build | |
| - name: Install roopik extension dependencies (skip postinstall) | |
| working-directory: extensions/roopik | |
| run: npm install --ignore-scripts | |
| - name: Install roopik webview dependencies | |
| working-directory: extensions/roopik/webview | |
| run: npm install | |
| - name: Build roopik extension | |
| working-directory: extensions/roopik | |
| run: npm run build | |
| - name: Build MCP STDIO binary (Linux) | |
| working-directory: tools/roopik/mcp-stdio-server | |
| run: | | |
| npm ci | |
| mkdir -p ../../../resources/mcp-binaries | |
| npm run build:binary:linux | |
| - name: Build Linux application (x64) | |
| env: | |
| NODE_OPTIONS: --max-old-space-size=4096 | |
| BUILD_SOURCEVERSION: ${{ github.sha }} | |
| run: npm run gulp vscode-linux-x64 | |
| - name: Build DEB package (custom) | |
| env: | |
| APP_NAME: roopik | |
| VSCODE_ARCH: x64 | |
| BUILD_SOURCEVERSION: ${{ github.sha }} | |
| run: bash .github/build/linux/package_roopik_deb.sh | |
| continue-on-error: true | |
| - name: Prepare Linux release artifact | |
| run: | | |
| mkdir -p .artifacts/installer | |
| mkdir -p .artifacts/public | |
| # Copy and rename portable version | |
| cp -r ../VSCode-linux-x64 ./Roopik-Portable-linux-x64 | |
| # Copy DEB file if it exists | |
| DEB_FILE=$(find .build/linux/deb -name "roopik_*.deb" -type f | head -n 1) | |
| if [ -n "$DEB_FILE" ]; then | |
| echo "Found DEB file: $DEB_FILE" | |
| cp "$DEB_FILE" .artifacts/installer/ | |
| cp "$DEB_FILE" .artifacts/public/roopik-linux-latest.deb | |
| else | |
| echo "Warning: DEB file not found, skipping installer artifact" | |
| fi | |
| # List what we're uploading | |
| echo "Artifact contents:" | |
| ls -lah Roopik-Portable-linux-x64/ | |
| ls -lah .artifacts/ | |
| - name: Upload Linux artifacts (x64) | |
| uses: actions/upload-artifact@v6 | |
| with: | |
| name: roopik-linux-release | |
| path: | | |
| .artifacts/public/ | |
| Roopik-Portable-linux-x64/ | |
| retention-days: 10 | |
| - name: Install AWS CLI | |
| continue-on-error: true | |
| run: | | |
| python3 -m pip install --user awscli | |
| - name: Upload Linux installer to R2 | |
| continue-on-error: true | |
| env: | |
| R2_ACCOUNT_ID: ${{ secrets.R2_ACCOUNT_ID }} | |
| R2_ACCESS_KEY_ID: ${{ secrets.R2_ACCESS_KEY_ID }} | |
| R2_SECRET_ACCESS_KEY: ${{ secrets.R2_SECRET_ACCESS_KEY }} | |
| R2_BUCKET: ${{ secrets.R2_BUCKET }} | |
| R2_PUBLIC_BASE_URL: ${{ secrets.R2_PUBLIC_BASE_URL }} | |
| run: | | |
| set -euo pipefail | |
| endpoint="https://${R2_ACCOUNT_ID}.r2.cloudflarestorage.com" | |
| prefix="linux/" | |
| deb_file="$(find .artifacts/installer -name 'roopik_*.deb' -type f | head -n 1)" | |
| if [ -z "$deb_file" ]; then | |
| echo "DEB file not found in .artifacts/installer" | |
| exit 1 | |
| fi | |
| export AWS_ACCESS_KEY_ID="$R2_ACCESS_KEY_ID" | |
| export AWS_SECRET_ACCESS_KEY="$R2_SECRET_ACCESS_KEY" | |
| export AWS_EC2_METADATA_DISABLED=true | |
| aws s3 cp "$deb_file" "s3://${R2_BUCKET}/${prefix}roopik-linux-latest.deb" --endpoint-url "$endpoint" --no-progress | |
| if [ -z "${R2_PUBLIC_BASE_URL:-}" ]; then | |
| echo "R2_PUBLIC_BASE_URL not set, skipping update manifest upload." | |
| exit 0 | |
| fi | |
| version="$(node -p "require('./package.json').version")" | |
| commit="${{ github.sha }}" | |
| hash="$(sha256sum "$deb_file" | awk '{print tolower($1)}')" | |
| pub_date="$(date -u +"%Y-%m-%dT%H:%M:%SZ")" | |
| base="${R2_PUBLIC_BASE_URL%/}" | |
| url="${base}/linux/roopik-linux-latest.deb" | |
| # CRITICAL: 'version' must be the commit hash for update comparison | |
| # 'productVersion' is the human-readable version (e.g., "1.109.0") | |
| json="$(printf '{"version":"%s","productVersion":"%s","url":"%s","sha256hash":"%s","pub_date":"%s"}' "$commit" "$version" "$url" "$hash" "$pub_date")" | |
| printf '%s' "$json" > latest.json | |
| aws s3 cp latest.json "s3://${R2_BUCKET}/linux/stable/latest.json" --endpoint-url "$endpoint" --no-progress | |