From 8f8e846b562bbba00eb2e0368dad5a75531b7c19 Mon Sep 17 00:00:00 2001 From: sangeeths03 Date: Tue, 22 Apr 2025 10:53:53 +0530 Subject: [PATCH] Create swiftlintcrash.yml --- .github/workflows/swiftlintcrash.yml | 34 ++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 .github/workflows/swiftlintcrash.yml diff --git a/.github/workflows/swiftlintcrash.yml b/.github/workflows/swiftlintcrash.yml new file mode 100644 index 00000000..835f169a --- /dev/null +++ b/.github/workflows/swiftlintcrash.yml @@ -0,0 +1,34 @@ +name: Reproduce SwiftLint Crash + +on: + workflow_dispatch: # manual trigger + +jobs: + swiftlint-crash-check: + runs-on: macos-15-large + name: SwiftLint Crash Repro on macOS 15 + + steps: + - name: Checkout code + uses: actions/checkout@v3 + + - name: Set up project structure + run: | + mkdir -p subdir + echo "opt_in_rules:\n - closure_body_length\n\nopt_in_rules:\n - closure_body_length" > subdir/.swiftlint.yml + echo "let a = 1" > subdir/a.swift + + - name: Install SwiftLint (Latest via Homebrew) + run: | + brew update + brew install swiftlint + + - name: Run SwiftLint in subdir (check for crash) + run: | + echo "Running SwiftLint..." + cd subdir + swiftlint || echo "SwiftLint crashed or failed" + + - name: Output result + if: ${{ failure() }} + run: echo "❌ SwiftLint crashed with current config."