From 4eb604a6a949901d6e8642a8057bf95708c5d052 Mon Sep 17 00:00:00 2001 From: Idan Levi Date: Wed, 27 May 2026 10:32:16 +0300 Subject: [PATCH] chore(ci): unblock lint for PRs MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Two related fixes so every contributor's PR isn't blocked by an unfixable lint check: 1. `src/DatePickerIOS.js` — apply `yarn lint --fix`. Pre-existing prettier issues at lines 26-27 that have been failing CI on every PR for months. 2. `.github/workflows/lint.yml` — check out the PR head, not master. `pr.yml` is triggered by `pull_request_target`, which defaults to the base branch for the workflow file *and* for the checkout, so lint was running against master and PR-side fixes were invisible. The other workflows (build-android, build-ios, test-android-*) already override this with `ref: ${{ github.event.pull_request.head.sha }}` — mirror the same pattern here. Combined, these unblock the lint check on every open PR (the existing \`yarn lint\` rules are unchanged). Co-Authored-By: Claude Opus 4.7 (1M context) --- .github/workflows/lint.yml | 8 ++++++++ src/DatePickerIOS.js | 8 ++++++-- 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index efae1e0d..701f3bbb 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -12,6 +12,14 @@ jobs: steps: - name: Checkout uses: actions/checkout@v4 + with: + # Required because pr.yml uses `pull_request_target`, which + # otherwise checks out the base branch (master) instead of the + # PR head. Without this override, lint runs against master and + # PR-side fixes (or breaks) are invisible to the check. + # Mirrors the pattern already used in build-android.yml / + # build-ios.yml / test-android-*.yml. + ref: ${{ github.event.pull_request.head.sha }} - name: Node uses: actions/setup-node@v4 diff --git a/src/DatePickerIOS.js b/src/DatePickerIOS.js index 987cbcac..268519bc 100644 --- a/src/DatePickerIOS.js +++ b/src/DatePickerIOS.js @@ -23,8 +23,12 @@ export const DatePickerIOS = (props) => { style: [styles.datePickerIOS, props.style], date: props.date ? props.date.toISOString() : undefined, locale: props.locale ? props.locale : undefined, - maximumDate: props.maximumDate ? props.maximumDate.toISOString() : undefined, - minimumDate: props.minimumDate ? props.minimumDate.toISOString() : undefined, + maximumDate: props.maximumDate + ? props.maximumDate.toISOString() + : undefined, + minimumDate: props.minimumDate + ? props.minimumDate.toISOString() + : undefined, theme: props.theme ? props.theme : 'auto', }