docs(cordova): Align Cordova docs with the v7-based SDK #1301
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: PR priority metadata | ||
|
Check warning on line 1 in .github/workflows/pr-priority-metadata.yml
|
||
| on: | ||
| pull_request_target: | ||
| types: [opened, edited, reopened, ready_for_review, converted_to_draft] | ||
| workflow_dispatch: | ||
| inputs: | ||
| pr_number: | ||
| description: Pull request number to evaluate | ||
| required: true | ||
| type: number | ||
| dry_run: | ||
| description: Log metadata decisions without changing the pull request | ||
| required: true | ||
| default: true | ||
| type: boolean | ||
| permissions: | ||
| contents: read | ||
| issues: write | ||
| pull-requests: write | ||
| jobs: | ||
| priority_metadata: | ||
| name: Priority metadata | ||
| if: >- | ||
| github.event_name == 'workflow_dispatch' || | ||
| github.event.action != 'edited' || | ||
| github.event.changes.body != null | ||
| concurrency: | ||
| group: >- | ||
| priority-metadata-${{ github.event.pull_request.number || inputs.pr_number }}-${{ | ||
| github.event_name == 'workflow_dispatch' && inputs.dry_run && github.run_id || 'event' }} | ||
| cancel-in-progress: true | ||
| runs-on: ubuntu-latest | ||
| timeout-minutes: 5 | ||
| steps: | ||
| - name: Resolve trusted base commit | ||
| id: base | ||
| env: | ||
| EVENT_BASE_SHA: ${{ github.event.pull_request.base.sha }} | ||
| PR_NUMBER: ${{ github.event.pull_request.number || inputs.pr_number }} | ||
| REPOSITORY: ${{ github.repository }} | ||
| GH_TOKEN: ${{ github.token }} | ||
| run: | | ||
| base_sha="$EVENT_BASE_SHA" | ||
| if [[ -z "$base_sha" ]]; then | ||
| base_sha=$(gh api "repos/$REPOSITORY/pulls/$PR_NUMBER" --jq '.base.sha') | ||
| fi | ||
| if [[ ! "$base_sha" =~ ^[0-9a-f]{40}$ ]]; then | ||
| echo "Invalid base commit SHA" >&2 | ||
| exit 1 | ||
| fi | ||
| echo "sha=$base_sha" >> "$GITHUB_OUTPUT" | ||
| - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | ||
| with: | ||
| ref: ${{ steps.base.outputs.sha }} | ||
| persist-credentials: false | ||
| - uses: actions/setup-node@53b83947a5a98c8d113130e565377fae1a50d02f # v4 | ||
| with: | ||
| node-version-file: package.json | ||
| - name: Synchronize priority metadata | ||
| env: | ||
| PR_NUMBER: ${{ github.event.pull_request.number || inputs.pr_number }} | ||
| REPOSITORY: ${{ github.repository }} | ||
| DRY_RUN: ${{ github.event_name == 'workflow_dispatch' && inputs.dry_run || false }} | ||
| GH_TOKEN: ${{ github.token }} | ||
| run: | | ||
| args=() | ||
| if [[ "$DRY_RUN" == "true" ]]; then | ||
| args+=(--dry-run) | ||
| fi | ||
| node scripts/sync-pr-priority-metadata.mjs "${args[@]}" | ||