split SDK overview from decision history and close RN upgrade gates #4040
Workflow file for this run
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: Workspace CI | |
| on: | |
| pull_request: | |
| branches: | |
| - dev | |
| - staging | |
| - main | |
| push: | |
| branches: | |
| - dev | |
| - staging | |
| - main | |
| jobs: | |
| generated-artifacts: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Cache pnpm store | |
| uses: ./.github/actions/cache-pnpm | |
| with: | |
| cache-version: v1 | |
| - name: Install Dependencies | |
| uses: ./.github/actions/pnpm-install | |
| - name: Verify generated contract error selectors | |
| run: pnpm --filter @selfxyz/contracts check:error-selectors | |
| rn-types-pin: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version-file: .nvmrc | |
| - name: Check @types/react-native-web react-native pin | |
| run: node scripts/check-rn-types-pin.cjs | |
| workspace-build: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Cache pnpm store | |
| uses: ./.github/actions/cache-pnpm | |
| with: | |
| cache-version: v1 | |
| - name: Install Dependencies | |
| uses: ./.github/actions/pnpm-install | |
| - name: Cache Turbo | |
| uses: ./.github/actions/cache-turbo | |
| with: | |
| key-prefix: workspace-build | |
| - name: Run workspace build | |
| run: pnpm build | |
| - name: Verify build artifacts | |
| run: | | |
| echo "Checking for build artifacts..." | |
| find . -name "dist" -type d | head -10 | |
| echo "Build completed successfully!" | |
| workspace-type-check: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Cache pnpm store | |
| uses: ./.github/actions/cache-pnpm | |
| with: | |
| cache-version: v1 | |
| - name: Install Dependencies | |
| uses: ./.github/actions/pnpm-install | |
| - name: Cache Turbo | |
| uses: ./.github/actions/cache-turbo | |
| with: | |
| key-prefix: workspace-type-check | |
| - name: Build workspace dependencies | |
| run: pnpm build | |
| - name: Run workspace type checking | |
| run: pnpm types | |
| - name: Verify type checking passed | |
| run: echo "Type checking completed successfully!" | |
| workspace-lint: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Cache pnpm store | |
| uses: ./.github/actions/cache-pnpm | |
| with: | |
| cache-version: v1 | |
| - name: Install Dependencies | |
| uses: ./.github/actions/pnpm-install | |
| - name: Install SwiftLint | |
| run: | | |
| curl -sL "https://github.com/realm/SwiftLint/releases/download/0.57.1/swiftlint_linux.zip" -o /tmp/swiftlint.zip | |
| unzip -o /tmp/swiftlint.zip -d /tmp/swiftlint | |
| sudo install /tmp/swiftlint/swiftlint /usr/local/bin/swiftlint | |
| - name: Cache Turbo | |
| uses: ./.github/actions/cache-turbo | |
| with: | |
| key-prefix: workspace-lint | |
| - name: Build workspace dependencies | |
| run: pnpm build | |
| - name: Run workspace linting | |
| run: pnpm lint | |
| - name: Verify linting passed | |
| run: echo "Linting completed successfully!" | |
| workspace-format-check: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Cache pnpm store | |
| uses: ./.github/actions/cache-pnpm | |
| with: | |
| cache-version: v1 | |
| - name: Install Dependencies | |
| uses: ./.github/actions/pnpm-install | |
| - name: Install SwiftLint | |
| run: | | |
| curl -sL "https://github.com/realm/SwiftLint/releases/download/0.57.1/swiftlint_linux.zip" -o /tmp/swiftlint.zip | |
| unzip -o /tmp/swiftlint.zip -d /tmp/swiftlint | |
| sudo install /tmp/swiftlint/swiftlint /usr/local/bin/swiftlint | |
| - name: Cache Turbo | |
| uses: ./.github/actions/cache-turbo | |
| with: | |
| key-prefix: workspace-format-check | |
| - name: Build workspace dependencies | |
| run: pnpm build | |
| - name: Check code formatting (dry run) | |
| run: | | |
| echo "Checking if code is properly formatted..." | |
| # Run format in dry-run mode by checking if any files would change | |
| if ! git diff --quiet --exit-code; then | |
| echo "Working directory not clean before format check" | |
| git status --porcelain | |
| exit 1 | |
| fi | |
| pnpm format | |
| # Markdown is excluded from the CI gate: prettier aligns markdown | |
| # tables by display width, which differs across OS for ambiguous-width | |
| # glyphs (em-dash, arrows), producing spurious diffs on the Linux | |
| # runner. `pnpm format` still formats .md locally; it just won't fail CI. | |
| if ! git diff --quiet --exit-code -- ':!*.md'; then | |
| echo "❌ Code formatting issues found. The following files need formatting:" | |
| git diff --name-only -- ':!*.md' | |
| echo "Run 'pnpm format' to fix these issues." | |
| exit 1 | |
| fi | |
| md_drift=$(git diff --name-only -- '*.md') | |
| if [ -n "$md_drift" ]; then | |
| echo "ℹ️ Markdown formatting drift (not failing CI):" | |
| echo "$md_drift" | |
| fi | |
| - name: Verify formatting check passed | |
| run: echo "Code formatting check completed successfully!" | |
| workspace-test: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Cache pnpm store | |
| uses: ./.github/actions/cache-pnpm | |
| with: | |
| cache-version: v1 | |
| - name: Install Dependencies | |
| uses: ./.github/actions/pnpm-install | |
| - name: Cache Turbo | |
| uses: ./.github/actions/cache-turbo | |
| with: | |
| key-prefix: workspace-test | |
| - name: Build workspace dependencies | |
| run: pnpm build | |
| - name: Run workspace tests | |
| run: pnpm -r --if-present --filter "!@selfxyz/circuits" --filter "!@selfxyz/contracts" run test | |
| - name: Verify tests passed | |
| run: echo "Workspace tests completed successfully!" | |
| # version-consistency: | |
| # runs-on: ubuntu-latest | |
| # permissions: | |
| # contents: read | |
| # steps: | |
| # - uses: actions/checkout@v6 | |
| # - name: Cache pnpm store | |
| # uses: ./.github/actions/cache-pnpm | |
| # with: | |
| # cache-version: v1 | |
| # - name: Install Dependencies | |
| # uses: ./.github/actions/pnpm-install | |
| # - name: Check package version consistency | |
| # run: pnpm check:versions | |
| # - name: Verify version consistency | |
| # run: echo "Package version consistency check passed!" |