Skip to content

Add error code descriptions as code comments #1924

Add error code descriptions as code comments

Add error code descriptions as code comments #1924

Workflow file for this run

name: Lint
on:
push:
branches: [main]
pull_request:
permissions:
contents: read
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
detect-changes:
runs-on: ubuntu-latest
outputs:
workspace: ${{ steps.filter.outputs.workspace }}
node: ${{ steps.filter.outputs.node }}
wasm: ${{ steps.filter.outputs.wasm }}
ios: ${{ steps.filter.outputs.ios }}
android: ${{ steps.filter.outputs.android }}
config: ${{ steps.filter.outputs.config }}
steps:
- uses: actions/checkout@v6
- uses: dorny/paths-filter@v3
id: filter
with:
filters: |
workspace:
- 'crates/**'
- 'bindings/**'
- 'apps/**'
- 'Cargo.toml'
- 'Cargo.lock'
- '.cargo/**'
- 'rust-toolchain.toml'
- 'rustfmt.toml'
- '.github/workflows/lint.yml'
- '.github/workflows/lint-workspace*'
node:
- 'bindings/node/**'
- '.github/workflows/lint-node*'
wasm:
- 'bindings/wasm/**'
- 'rust-toolchain.toml'
- '.github/workflows/lint-wasm*'
ios:
- 'sdks/ios/**'
- '.github/workflows/lint-ios*'
android:
- 'sdks/android/**'
- 'bindings/mobile/**'
- '.github/workflows/lint-android*'
config:
- '**/*.toml'
- '**/*.nix'
- 'flake.nix'
- 'dev/**'
- '.github/workflows/lint-config*'
lint-workspace:
needs: detect-changes
if: needs.detect-changes.outputs.workspace == 'true'
uses: ./.github/workflows/lint-workspace.yml
secrets: inherit
lint-node:
needs: detect-changes
if: needs.detect-changes.outputs.node == 'true'
uses: ./.github/workflows/lint-node.yml
secrets: inherit
lint-wasm:
needs: detect-changes
if: needs.detect-changes.outputs.wasm == 'true'
uses: ./.github/workflows/lint-wasm.yml
secrets: inherit
lint-ios:
needs: detect-changes
if: needs.detect-changes.outputs.ios == 'true'
uses: ./.github/workflows/lint-ios.yml
secrets: inherit
lint-android:
needs: detect-changes
if: needs.detect-changes.outputs.android == 'true'
uses: ./.github/workflows/lint-android.yml
secrets: inherit
lint-config:
needs: detect-changes
if: needs.detect-changes.outputs.config == 'true'
uses: ./.github/workflows/lint-config.yml
secrets: inherit
lint:
name: Lint
runs-on: ubuntu-latest
if: always()
needs:
- lint-workspace
- lint-node
- lint-wasm
# - lint-ios TODO:(nm) Temporarily making optional until we are confident the new workflows are fast/reliable enough to block CI
# - lint-android TODO:(nm) Temporarily making optional until we are confident the new workflows are fast/reliable enough to block CI
- lint-config
steps:
- run: |
if [[ "${{ contains(needs.*.result, 'failure') }}" == "true" || \
"${{ contains(needs.*.result, 'cancelled') }}" == "true" ]]; then
echo "One or more lint jobs failed or were cancelled"
exit 1
fi