eslint-plugin-github-actions-2 1.0.2 → 1.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +149 -101
- package/dist/_internal/code-scanning-workflow.d.ts +37 -0
- package/dist/_internal/code-scanning-workflow.d.ts.map +1 -0
- package/dist/_internal/code-scanning-workflow.js +73 -0
- package/dist/_internal/code-scanning-workflow.js.map +1 -0
- package/dist/_internal/dependabot-automation-workflow.d.ts +26 -0
- package/dist/_internal/dependabot-automation-workflow.d.ts.map +1 -0
- package/dist/_internal/dependabot-automation-workflow.js +25 -0
- package/dist/_internal/dependabot-automation-workflow.js.map +1 -0
- package/dist/_internal/dependabot-yaml.d.ts +63 -0
- package/dist/_internal/dependabot-yaml.d.ts.map +1 -0
- package/dist/_internal/dependabot-yaml.js +139 -0
- package/dist/_internal/dependabot-yaml.js.map +1 -0
- package/dist/_internal/dependency-review-workflow.d.ts +20 -0
- package/dist/_internal/dependency-review-workflow.d.ts.map +1 -0
- package/dist/_internal/dependency-review-workflow.js +9 -0
- package/dist/_internal/dependency-review-workflow.js.map +1 -0
- package/dist/_internal/github-actions-config-references.d.ts +1 -1
- package/dist/_internal/github-actions-config-references.d.ts.map +1 -1
- package/dist/_internal/github-actions-config-references.js +19 -2
- package/dist/_internal/github-actions-config-references.js.map +1 -1
- package/dist/_internal/lint-targets.d.ts +15 -0
- package/dist/_internal/lint-targets.d.ts.map +1 -1
- package/dist/_internal/lint-targets.js +41 -0
- package/dist/_internal/lint-targets.js.map +1 -1
- package/dist/_internal/rules-registry.d.ts +90 -0
- package/dist/_internal/rules-registry.d.ts.map +1 -1
- package/dist/_internal/rules-registry.js +90 -0
- package/dist/_internal/rules-registry.js.map +1 -1
- package/dist/_internal/secret-scanning-workflow.d.ts +24 -0
- package/dist/_internal/secret-scanning-workflow.d.ts.map +1 -0
- package/dist/_internal/secret-scanning-workflow.js +21 -0
- package/dist/_internal/secret-scanning-workflow.js.map +1 -0
- package/dist/_internal/workflow-action-steps.d.ts +35 -0
- package/dist/_internal/workflow-action-steps.d.ts.map +1 -0
- package/dist/_internal/workflow-action-steps.js +75 -0
- package/dist/_internal/workflow-action-steps.js.map +1 -0
- package/dist/_internal/workflow-permissions.d.ts +11 -0
- package/dist/_internal/workflow-permissions.d.ts.map +1 -0
- package/dist/_internal/workflow-permissions.js +50 -0
- package/dist/_internal/workflow-permissions.js.map +1 -0
- package/dist/_internal/yaml-fixes.d.ts +13 -0
- package/dist/_internal/yaml-fixes.d.ts.map +1 -0
- package/dist/_internal/yaml-fixes.js +77 -0
- package/dist/_internal/yaml-fixes.js.map +1 -0
- package/dist/plugin.cjs +3516 -268
- package/dist/plugin.cjs.map +4 -4
- package/dist/plugin.d.ts.map +1 -1
- package/dist/plugin.js +2 -0
- package/dist/plugin.js.map +1 -1
- package/dist/rules/action-name-casing.d.ts.map +1 -1
- package/dist/rules/action-name-casing.js +3 -0
- package/dist/rules/action-name-casing.js.map +1 -1
- package/dist/rules/job-id-casing.d.ts.map +1 -1
- package/dist/rules/job-id-casing.js +3 -0
- package/dist/rules/job-id-casing.js.map +1 -1
- package/dist/rules/max-jobs-per-action.d.ts.map +1 -1
- package/dist/rules/max-jobs-per-action.js +3 -0
- package/dist/rules/max-jobs-per-action.js.map +1 -1
- package/dist/rules/no-case-insensitive-input-id-collision.d.ts.map +1 -1
- package/dist/rules/no-case-insensitive-input-id-collision.js +3 -0
- package/dist/rules/no-case-insensitive-input-id-collision.js.map +1 -1
- package/dist/rules/no-codeql-autobuild-for-javascript-typescript.d.ts +9 -0
- package/dist/rules/no-codeql-autobuild-for-javascript-typescript.d.ts.map +1 -0
- package/dist/rules/no-codeql-autobuild-for-javascript-typescript.js +54 -0
- package/dist/rules/no-codeql-autobuild-for-javascript-typescript.js.map +1 -0
- package/dist/rules/no-codeql-javascript-typescript-split-language-matrix.d.ts +9 -0
- package/dist/rules/no-codeql-javascript-typescript-split-language-matrix.d.ts.map +1 -0
- package/dist/rules/no-codeql-javascript-typescript-split-language-matrix.js +50 -0
- package/dist/rules/no-codeql-javascript-typescript-split-language-matrix.js.map +1 -0
- package/dist/rules/no-composite-input-env-access.d.ts.map +1 -1
- package/dist/rules/no-composite-input-env-access.js +3 -0
- package/dist/rules/no-composite-input-env-access.js.map +1 -1
- package/dist/rules/no-deprecated-node-runtime.d.ts.map +1 -1
- package/dist/rules/no-deprecated-node-runtime.js +3 -0
- package/dist/rules/no-deprecated-node-runtime.js.map +1 -1
- package/dist/rules/no-duplicate-composite-step-id.d.ts.map +1 -1
- package/dist/rules/no-duplicate-composite-step-id.js +3 -0
- package/dist/rules/no-duplicate-composite-step-id.js.map +1 -1
- package/dist/rules/no-empty-template-file-pattern.d.ts.map +1 -1
- package/dist/rules/no-empty-template-file-pattern.js +6 -0
- package/dist/rules/no-empty-template-file-pattern.js.map +1 -1
- package/dist/rules/no-external-job.d.ts.map +1 -1
- package/dist/rules/no-external-job.js +3 -0
- package/dist/rules/no-external-job.js.map +1 -1
- package/dist/rules/no-hardcoded-default-branch-in-template.d.ts.map +1 -1
- package/dist/rules/no-hardcoded-default-branch-in-template.js +3 -0
- package/dist/rules/no-hardcoded-default-branch-in-template.js.map +1 -1
- package/dist/rules/no-icon-file-extension-in-template-icon-name.d.ts.map +1 -1
- package/dist/rules/no-icon-file-extension-in-template-icon-name.js +13 -3
- package/dist/rules/no-icon-file-extension-in-template-icon-name.js.map +1 -1
- package/dist/rules/no-inherit-secrets.d.ts.map +1 -1
- package/dist/rules/no-inherit-secrets.js +3 -0
- package/dist/rules/no-inherit-secrets.js.map +1 -1
- package/dist/rules/no-invalid-concurrency-context.d.ts.map +1 -1
- package/dist/rules/no-invalid-concurrency-context.js +3 -0
- package/dist/rules/no-invalid-concurrency-context.js.map +1 -1
- package/dist/rules/no-invalid-key.d.ts.map +1 -1
- package/dist/rules/no-invalid-key.js +7 -0
- package/dist/rules/no-invalid-key.js.map +1 -1
- package/dist/rules/no-invalid-reusable-workflow-job-key.d.ts.map +1 -1
- package/dist/rules/no-invalid-reusable-workflow-job-key.js +3 -0
- package/dist/rules/no-invalid-reusable-workflow-job-key.js.map +1 -1
- package/dist/rules/no-invalid-template-file-pattern-regex.d.ts.map +1 -1
- package/dist/rules/no-invalid-template-file-pattern-regex.js +3 -0
- package/dist/rules/no-invalid-template-file-pattern-regex.js.map +1 -1
- package/dist/rules/no-invalid-workflow-call-output-value.d.ts.map +1 -1
- package/dist/rules/no-invalid-workflow-call-output-value.js +3 -0
- package/dist/rules/no-invalid-workflow-call-output-value.js.map +1 -1
- package/dist/rules/no-overlapping-dependabot-directories.d.ts +9 -0
- package/dist/rules/no-overlapping-dependabot-directories.d.ts.map +1 -0
- package/dist/rules/no-overlapping-dependabot-directories.js +151 -0
- package/dist/rules/no-overlapping-dependabot-directories.js.map +1 -0
- package/dist/rules/no-path-separators-in-template-icon-name.d.ts.map +1 -1
- package/dist/rules/no-path-separators-in-template-icon-name.js +26 -3
- package/dist/rules/no-path-separators-in-template-icon-name.js.map +1 -1
- package/dist/rules/no-post-if-without-post.d.ts.map +1 -1
- package/dist/rules/no-post-if-without-post.js +6 -0
- package/dist/rules/no-post-if-without-post.js.map +1 -1
- package/dist/rules/no-pr-head-checkout-in-pull-request-target.d.ts.map +1 -1
- package/dist/rules/no-pr-head-checkout-in-pull-request-target.js +3 -0
- package/dist/rules/no-pr-head-checkout-in-pull-request-target.js.map +1 -1
- package/dist/rules/no-pre-if-without-pre.d.ts.map +1 -1
- package/dist/rules/no-pre-if-without-pre.js +6 -0
- package/dist/rules/no-pre-if-without-pre.js.map +1 -1
- package/dist/rules/no-required-input-with-default.d.ts.map +1 -1
- package/dist/rules/no-required-input-with-default.js +23 -0
- package/dist/rules/no-required-input-with-default.js.map +1 -1
- package/dist/rules/no-secrets-in-if.d.ts.map +1 -1
- package/dist/rules/no-secrets-in-if.js +3 -0
- package/dist/rules/no-secrets-in-if.js.map +1 -1
- package/dist/rules/no-self-hosted-runner-on-fork-pr-events.d.ts.map +1 -1
- package/dist/rules/no-self-hosted-runner-on-fork-pr-events.js +3 -0
- package/dist/rules/no-self-hosted-runner-on-fork-pr-events.js.map +1 -1
- package/dist/rules/no-subdirectory-template-file-pattern.d.ts.map +1 -1
- package/dist/rules/no-subdirectory-template-file-pattern.js +3 -0
- package/dist/rules/no-subdirectory-template-file-pattern.js.map +1 -1
- package/dist/rules/no-template-placeholder-in-non-template-workflow.d.ts.map +1 -1
- package/dist/rules/no-template-placeholder-in-non-template-workflow.js +3 -0
- package/dist/rules/no-template-placeholder-in-non-template-workflow.js.map +1 -1
- package/dist/rules/no-top-level-env.d.ts.map +1 -1
- package/dist/rules/no-top-level-env.js +3 -0
- package/dist/rules/no-top-level-env.js.map +1 -1
- package/dist/rules/no-top-level-permissions.d.ts.map +1 -1
- package/dist/rules/no-top-level-permissions.js +3 -0
- package/dist/rules/no-top-level-permissions.js.map +1 -1
- package/dist/rules/no-universal-template-file-pattern.d.ts.map +1 -1
- package/dist/rules/no-universal-template-file-pattern.js +3 -0
- package/dist/rules/no-universal-template-file-pattern.js.map +1 -1
- package/dist/rules/no-unknown-dependabot-multi-ecosystem-group.d.ts +9 -0
- package/dist/rules/no-unknown-dependabot-multi-ecosystem-group.d.ts.map +1 -0
- package/dist/rules/no-unknown-dependabot-multi-ecosystem-group.js +58 -0
- package/dist/rules/no-unknown-dependabot-multi-ecosystem-group.js.map +1 -0
- package/dist/rules/no-unknown-input-reference-in-composite.d.ts.map +1 -1
- package/dist/rules/no-unknown-input-reference-in-composite.js +3 -0
- package/dist/rules/no-unknown-input-reference-in-composite.js.map +1 -1
- package/dist/rules/no-unknown-job-output-reference.d.ts.map +1 -1
- package/dist/rules/no-unknown-job-output-reference.js +3 -0
- package/dist/rules/no-unknown-job-output-reference.js.map +1 -1
- package/dist/rules/no-unknown-step-reference.d.ts.map +1 -1
- package/dist/rules/no-unknown-step-reference.js +3 -0
- package/dist/rules/no-unknown-step-reference.js.map +1 -1
- package/dist/rules/no-untrusted-input-in-run.d.ts.map +1 -1
- package/dist/rules/no-untrusted-input-in-run.js +3 -0
- package/dist/rules/no-untrusted-input-in-run.js.map +1 -1
- package/dist/rules/no-unused-dependabot-enable-beta-ecosystems.d.ts +9 -0
- package/dist/rules/no-unused-dependabot-enable-beta-ecosystems.d.ts.map +1 -0
- package/dist/rules/no-unused-dependabot-enable-beta-ecosystems.js +51 -0
- package/dist/rules/no-unused-dependabot-enable-beta-ecosystems.js.map +1 -0
- package/dist/rules/no-unused-input-in-composite.d.ts.map +1 -1
- package/dist/rules/no-unused-input-in-composite.js +3 -0
- package/dist/rules/no-unused-input-in-composite.js.map +1 -1
- package/dist/rules/no-write-all-permissions.d.ts.map +1 -1
- package/dist/rules/no-write-all-permissions.js +3 -0
- package/dist/rules/no-write-all-permissions.js.map +1 -1
- package/dist/rules/pin-action-shas.d.ts.map +1 -1
- package/dist/rules/pin-action-shas.js +3 -0
- package/dist/rules/pin-action-shas.js.map +1 -1
- package/dist/rules/prefer-action-yml.d.ts.map +1 -1
- package/dist/rules/prefer-action-yml.js +3 -0
- package/dist/rules/prefer-action-yml.js.map +1 -1
- package/dist/rules/prefer-fail-fast.d.ts.map +1 -1
- package/dist/rules/prefer-fail-fast.js +3 -0
- package/dist/rules/prefer-fail-fast.js.map +1 -1
- package/dist/rules/prefer-file-extension.d.ts.map +1 -1
- package/dist/rules/prefer-file-extension.js +3 -0
- package/dist/rules/prefer-file-extension.js.map +1 -1
- package/dist/rules/prefer-inputs-context.d.ts.map +1 -1
- package/dist/rules/prefer-inputs-context.js +3 -0
- package/dist/rules/prefer-inputs-context.js.map +1 -1
- package/dist/rules/prefer-step-uses-style.d.ts.map +1 -1
- package/dist/rules/prefer-step-uses-style.js +3 -0
- package/dist/rules/prefer-step-uses-style.js.map +1 -1
- package/dist/rules/prefer-template-yml-extension.d.ts.map +1 -1
- package/dist/rules/prefer-template-yml-extension.js +3 -0
- package/dist/rules/prefer-template-yml-extension.js.map +1 -1
- package/dist/rules/require-action-name.d.ts.map +1 -1
- package/dist/rules/require-action-name.js +7 -0
- package/dist/rules/require-action-name.js.map +1 -1
- package/dist/rules/require-action-run-name.d.ts.map +1 -1
- package/dist/rules/require-action-run-name.js +7 -0
- package/dist/rules/require-action-run-name.js.map +1 -1
- package/dist/rules/require-checkout-before-local-action.d.ts.map +1 -1
- package/dist/rules/require-checkout-before-local-action.js +3 -0
- package/dist/rules/require-checkout-before-local-action.js.map +1 -1
- package/dist/rules/require-codeql-actions-read.d.ts +9 -0
- package/dist/rules/require-codeql-actions-read.d.ts.map +1 -0
- package/dist/rules/require-codeql-actions-read.js +63 -0
- package/dist/rules/require-codeql-actions-read.js.map +1 -0
- package/dist/rules/require-codeql-branch-filters.d.ts +12 -0
- package/dist/rules/require-codeql-branch-filters.d.ts.map +1 -0
- package/dist/rules/require-codeql-branch-filters.js +83 -0
- package/dist/rules/require-codeql-branch-filters.js.map +1 -0
- package/dist/rules/require-codeql-category-when-language-matrix.d.ts +12 -0
- package/dist/rules/require-codeql-category-when-language-matrix.d.ts.map +1 -0
- package/dist/rules/require-codeql-category-when-language-matrix.js +68 -0
- package/dist/rules/require-codeql-category-when-language-matrix.js.map +1 -0
- package/dist/rules/require-codeql-pull-request-trigger.d.ts +9 -0
- package/dist/rules/require-codeql-pull-request-trigger.d.ts.map +1 -0
- package/dist/rules/require-codeql-pull-request-trigger.js +46 -0
- package/dist/rules/require-codeql-pull-request-trigger.js.map +1 -0
- package/dist/rules/require-codeql-schedule.d.ts +9 -0
- package/dist/rules/require-codeql-schedule.d.ts.map +1 -0
- package/dist/rules/require-codeql-schedule.js +46 -0
- package/dist/rules/require-codeql-schedule.js.map +1 -0
- package/dist/rules/require-codeql-security-events-write.d.ts +9 -0
- package/dist/rules/require-codeql-security-events-write.d.ts.map +1 -0
- package/dist/rules/require-codeql-security-events-write.js +53 -0
- package/dist/rules/require-codeql-security-events-write.js.map +1 -0
- package/dist/rules/require-composite-step-name.d.ts.map +1 -1
- package/dist/rules/require-composite-step-name.js +3 -0
- package/dist/rules/require-composite-step-name.js.map +1 -1
- package/dist/rules/require-dependabot-assignees.d.ts +9 -0
- package/dist/rules/require-dependabot-assignees.d.ts.map +1 -0
- package/dist/rules/require-dependabot-assignees.js +53 -0
- package/dist/rules/require-dependabot-assignees.js.map +1 -0
- package/dist/rules/require-dependabot-automation-permissions.d.ts +9 -0
- package/dist/rules/require-dependabot-automation-permissions.d.ts.map +1 -0
- package/dist/rules/require-dependabot-automation-permissions.js +68 -0
- package/dist/rules/require-dependabot-automation-permissions.js.map +1 -0
- package/dist/rules/require-dependabot-automation-pull-request-trigger.d.ts +12 -0
- package/dist/rules/require-dependabot-automation-pull-request-trigger.d.ts.map +1 -0
- package/dist/rules/require-dependabot-automation-pull-request-trigger.js +49 -0
- package/dist/rules/require-dependabot-automation-pull-request-trigger.js.map +1 -0
- package/dist/rules/require-dependabot-bot-actor-guard.d.ts +9 -0
- package/dist/rules/require-dependabot-bot-actor-guard.d.ts.map +1 -0
- package/dist/rules/require-dependabot-bot-actor-guard.js +64 -0
- package/dist/rules/require-dependabot-bot-actor-guard.js.map +1 -0
- package/dist/rules/require-dependabot-commit-message-include-scope.d.ts +9 -0
- package/dist/rules/require-dependabot-commit-message-include-scope.d.ts.map +1 -0
- package/dist/rules/require-dependabot-commit-message-include-scope.js +60 -0
- package/dist/rules/require-dependabot-commit-message-include-scope.js.map +1 -0
- package/dist/rules/require-dependabot-commit-message-prefix-development.d.ts +9 -0
- package/dist/rules/require-dependabot-commit-message-prefix-development.d.ts.map +1 -0
- package/dist/rules/require-dependabot-commit-message-prefix-development.js +75 -0
- package/dist/rules/require-dependabot-commit-message-prefix-development.js.map +1 -0
- package/dist/rules/require-dependabot-commit-message-prefix.d.ts +9 -0
- package/dist/rules/require-dependabot-commit-message-prefix.d.ts.map +1 -0
- package/dist/rules/require-dependabot-commit-message-prefix.js +60 -0
- package/dist/rules/require-dependabot-commit-message-prefix.js.map +1 -0
- package/dist/rules/require-dependabot-cooldown.d.ts +9 -0
- package/dist/rules/require-dependabot-cooldown.d.ts.map +1 -0
- package/dist/rules/require-dependabot-cooldown.js +52 -0
- package/dist/rules/require-dependabot-cooldown.js.map +1 -0
- package/dist/rules/require-dependabot-directory.d.ts +9 -0
- package/dist/rules/require-dependabot-directory.d.ts.map +1 -0
- package/dist/rules/require-dependabot-directory.js +68 -0
- package/dist/rules/require-dependabot-directory.js.map +1 -0
- package/dist/rules/require-dependabot-github-actions-directory-root.d.ts +9 -0
- package/dist/rules/require-dependabot-github-actions-directory-root.d.ts.map +1 -0
- package/dist/rules/require-dependabot-github-actions-directory-root.js +76 -0
- package/dist/rules/require-dependabot-github-actions-directory-root.js.map +1 -0
- package/dist/rules/require-dependabot-labels.d.ts +9 -0
- package/dist/rules/require-dependabot-labels.d.ts.map +1 -0
- package/dist/rules/require-dependabot-labels.js +52 -0
- package/dist/rules/require-dependabot-labels.js.map +1 -0
- package/dist/rules/require-dependabot-open-pull-requests-limit.d.ts +9 -0
- package/dist/rules/require-dependabot-open-pull-requests-limit.d.ts.map +1 -0
- package/dist/rules/require-dependabot-open-pull-requests-limit.js +55 -0
- package/dist/rules/require-dependabot-open-pull-requests-limit.js.map +1 -0
- package/dist/rules/require-dependabot-package-ecosystem.d.ts +9 -0
- package/dist/rules/require-dependabot-package-ecosystem.d.ts.map +1 -0
- package/dist/rules/require-dependabot-package-ecosystem.js +79 -0
- package/dist/rules/require-dependabot-package-ecosystem.js.map +1 -0
- package/dist/rules/require-dependabot-patterns-for-multi-ecosystem-group.d.ts +9 -0
- package/dist/rules/require-dependabot-patterns-for-multi-ecosystem-group.d.ts.map +1 -0
- package/dist/rules/require-dependabot-patterns-for-multi-ecosystem-group.js +58 -0
- package/dist/rules/require-dependabot-patterns-for-multi-ecosystem-group.js.map +1 -0
- package/dist/rules/require-dependabot-schedule-cronjob.d.ts +9 -0
- package/dist/rules/require-dependabot-schedule-cronjob.d.ts.map +1 -0
- package/dist/rules/require-dependabot-schedule-cronjob.js +82 -0
- package/dist/rules/require-dependabot-schedule-cronjob.js.map +1 -0
- package/dist/rules/require-dependabot-schedule-interval.d.ts +9 -0
- package/dist/rules/require-dependabot-schedule-interval.d.ts.map +1 -0
- package/dist/rules/require-dependabot-schedule-interval.js +73 -0
- package/dist/rules/require-dependabot-schedule-interval.js.map +1 -0
- package/dist/rules/require-dependabot-schedule-time.d.ts +9 -0
- package/dist/rules/require-dependabot-schedule-time.d.ts.map +1 -0
- package/dist/rules/require-dependabot-schedule-time.js +68 -0
- package/dist/rules/require-dependabot-schedule-time.js.map +1 -0
- package/dist/rules/require-dependabot-schedule-timezone.d.ts +9 -0
- package/dist/rules/require-dependabot-schedule-timezone.d.ts.map +1 -0
- package/dist/rules/require-dependabot-schedule-timezone.js +69 -0
- package/dist/rules/require-dependabot-schedule-timezone.js.map +1 -0
- package/dist/rules/require-dependabot-target-branch.d.ts +9 -0
- package/dist/rules/require-dependabot-target-branch.d.ts.map +1 -0
- package/dist/rules/require-dependabot-target-branch.js +53 -0
- package/dist/rules/require-dependabot-target-branch.js.map +1 -0
- package/dist/rules/require-dependabot-updates.d.ts +9 -0
- package/dist/rules/require-dependabot-updates.d.ts.map +1 -0
- package/dist/rules/require-dependabot-updates.js +54 -0
- package/dist/rules/require-dependabot-updates.js.map +1 -0
- package/dist/rules/require-dependabot-version.d.ts +9 -0
- package/dist/rules/require-dependabot-version.d.ts.map +1 -0
- package/dist/rules/require-dependabot-version.js +62 -0
- package/dist/rules/require-dependabot-version.js.map +1 -0
- package/dist/rules/require-dependabot-versioning-strategy-for-npm.d.ts +9 -0
- package/dist/rules/require-dependabot-versioning-strategy-for-npm.d.ts.map +1 -0
- package/dist/rules/require-dependabot-versioning-strategy-for-npm.js +58 -0
- package/dist/rules/require-dependabot-versioning-strategy-for-npm.js.map +1 -0
- package/dist/rules/require-dependency-review-action.d.ts +9 -0
- package/dist/rules/require-dependency-review-action.d.ts.map +1 -0
- package/dist/rules/require-dependency-review-action.js +51 -0
- package/dist/rules/require-dependency-review-action.js.map +1 -0
- package/dist/rules/require-dependency-review-fail-on-severity.d.ts +9 -0
- package/dist/rules/require-dependency-review-fail-on-severity.d.ts.map +1 -0
- package/dist/rules/require-dependency-review-fail-on-severity.js +62 -0
- package/dist/rules/require-dependency-review-fail-on-severity.js.map +1 -0
- package/dist/rules/require-dependency-review-permissions-contents-read.d.ts +9 -0
- package/dist/rules/require-dependency-review-permissions-contents-read.d.ts.map +1 -0
- package/dist/rules/require-dependency-review-permissions-contents-read.js +55 -0
- package/dist/rules/require-dependency-review-permissions-contents-read.js.map +1 -0
- package/dist/rules/require-dependency-review-pull-request-trigger.d.ts +9 -0
- package/dist/rules/require-dependency-review-pull-request-trigger.d.ts.map +1 -0
- package/dist/rules/require-dependency-review-pull-request-trigger.js +47 -0
- package/dist/rules/require-dependency-review-pull-request-trigger.js.map +1 -0
- package/dist/rules/require-fetch-metadata-github-token.d.ts +9 -0
- package/dist/rules/require-fetch-metadata-github-token.d.ts.map +1 -0
- package/dist/rules/require-fetch-metadata-github-token.js +57 -0
- package/dist/rules/require-fetch-metadata-github-token.js.map +1 -0
- package/dist/rules/require-job-name.d.ts.map +1 -1
- package/dist/rules/require-job-name.js +35 -0
- package/dist/rules/require-job-name.js.map +1 -1
- package/dist/rules/require-job-step-name.d.ts.map +1 -1
- package/dist/rules/require-job-step-name.js +76 -0
- package/dist/rules/require-job-step-name.js.map +1 -1
- package/dist/rules/require-job-timeout-minutes.d.ts.map +1 -1
- package/dist/rules/require-job-timeout-minutes.js +3 -0
- package/dist/rules/require-job-timeout-minutes.js.map +1 -1
- package/dist/rules/require-merge-group-trigger.d.ts.map +1 -1
- package/dist/rules/require-merge-group-trigger.js +3 -0
- package/dist/rules/require-merge-group-trigger.js.map +1 -1
- package/dist/rules/require-pull-request-target-branches.d.ts.map +1 -1
- package/dist/rules/require-pull-request-target-branches.js +3 -0
- package/dist/rules/require-pull-request-target-branches.js.map +1 -1
- package/dist/rules/require-run-step-shell.d.ts.map +1 -1
- package/dist/rules/require-run-step-shell.js +3 -0
- package/dist/rules/require-run-step-shell.js.map +1 -1
- package/dist/rules/require-sarif-upload-security-events-write.d.ts +9 -0
- package/dist/rules/require-sarif-upload-security-events-write.d.ts.map +1 -0
- package/dist/rules/require-sarif-upload-security-events-write.js +51 -0
- package/dist/rules/require-sarif-upload-security-events-write.js.map +1 -0
- package/dist/rules/require-scorecard-results-format-sarif.d.ts +9 -0
- package/dist/rules/require-scorecard-results-format-sarif.d.ts.map +1 -0
- package/dist/rules/require-scorecard-results-format-sarif.js +57 -0
- package/dist/rules/require-scorecard-results-format-sarif.js.map +1 -0
- package/dist/rules/require-scorecard-upload-sarif-step.d.ts +9 -0
- package/dist/rules/require-scorecard-upload-sarif-step.d.ts.map +1 -0
- package/dist/rules/require-scorecard-upload-sarif-step.js +46 -0
- package/dist/rules/require-scorecard-upload-sarif-step.js.map +1 -0
- package/dist/rules/require-secret-scan-contents-read.d.ts +12 -0
- package/dist/rules/require-secret-scan-contents-read.d.ts.map +1 -0
- package/dist/rules/require-secret-scan-contents-read.js +53 -0
- package/dist/rules/require-secret-scan-contents-read.js.map +1 -0
- package/dist/rules/require-secret-scan-fetch-depth-zero.d.ts +9 -0
- package/dist/rules/require-secret-scan-fetch-depth-zero.d.ts.map +1 -0
- package/dist/rules/require-secret-scan-fetch-depth-zero.js +77 -0
- package/dist/rules/require-secret-scan-fetch-depth-zero.js.map +1 -0
- package/dist/rules/require-secret-scan-schedule.d.ts +9 -0
- package/dist/rules/require-secret-scan-schedule.d.ts.map +1 -0
- package/dist/rules/require-secret-scan-schedule.js +46 -0
- package/dist/rules/require-secret-scan-schedule.js.map +1 -0
- package/dist/rules/require-template-categories.d.ts.map +1 -1
- package/dist/rules/require-template-categories.js +3 -0
- package/dist/rules/require-template-categories.js.map +1 -1
- package/dist/rules/require-template-file-patterns.d.ts.map +1 -1
- package/dist/rules/require-template-file-patterns.js +3 -0
- package/dist/rules/require-template-file-patterns.js.map +1 -1
- package/dist/rules/require-template-icon-file-exists.d.ts.map +1 -1
- package/dist/rules/require-template-icon-file-exists.js +3 -0
- package/dist/rules/require-template-icon-file-exists.js.map +1 -1
- package/dist/rules/require-template-icon-name.d.ts.map +1 -1
- package/dist/rules/require-template-icon-name.js +3 -0
- package/dist/rules/require-template-icon-name.js.map +1 -1
- package/dist/rules/require-template-workflow-name.d.ts.map +1 -1
- package/dist/rules/require-template-workflow-name.js +3 -0
- package/dist/rules/require-template-workflow-name.js.map +1 -1
- package/dist/rules/require-trigger-types.d.ts.map +1 -1
- package/dist/rules/require-trigger-types.js +3 -0
- package/dist/rules/require-trigger-types.js.map +1 -1
- package/dist/rules/require-trufflehog-verified-results-mode.d.ts +9 -0
- package/dist/rules/require-trufflehog-verified-results-mode.d.ts.map +1 -0
- package/dist/rules/require-trufflehog-verified-results-mode.js +59 -0
- package/dist/rules/require-trufflehog-verified-results-mode.js.map +1 -0
- package/dist/rules/require-workflow-call-input-type.d.ts.map +1 -1
- package/dist/rules/require-workflow-call-input-type.js +3 -0
- package/dist/rules/require-workflow-call-input-type.js.map +1 -1
- package/dist/rules/require-workflow-call-output-value.d.ts.map +1 -1
- package/dist/rules/require-workflow-call-output-value.js +3 -0
- package/dist/rules/require-workflow-call-output-value.js.map +1 -1
- package/dist/rules/require-workflow-concurrency.d.ts.map +1 -1
- package/dist/rules/require-workflow-concurrency.js +3 -0
- package/dist/rules/require-workflow-concurrency.js.map +1 -1
- package/dist/rules/require-workflow-dispatch-input-type.d.ts.map +1 -1
- package/dist/rules/require-workflow-dispatch-input-type.js +3 -0
- package/dist/rules/require-workflow-dispatch-input-type.js.map +1 -1
- package/dist/rules/require-workflow-interface-description.d.ts.map +1 -1
- package/dist/rules/require-workflow-interface-description.js +3 -0
- package/dist/rules/require-workflow-interface-description.js.map +1 -1
- package/dist/rules/require-workflow-permissions.d.ts.map +1 -1
- package/dist/rules/require-workflow-permissions.js +7 -0
- package/dist/rules/require-workflow-permissions.js.map +1 -1
- package/dist/rules/require-workflow-run-branches.d.ts.map +1 -1
- package/dist/rules/require-workflow-run-branches.js +3 -0
- package/dist/rules/require-workflow-run-branches.js.map +1 -1
- package/dist/rules/require-workflow-template-pair.d.ts.map +1 -1
- package/dist/rules/require-workflow-template-pair.js +3 -0
- package/dist/rules/require-workflow-template-pair.js.map +1 -1
- package/dist/rules/require-workflow-template-properties-pair.d.ts.map +1 -1
- package/dist/rules/require-workflow-template-properties-pair.js +3 -0
- package/dist/rules/require-workflow-template-properties-pair.js.map +1 -1
- package/dist/rules/valid-timeout-minutes.d.ts.map +1 -1
- package/dist/rules/valid-timeout-minutes.js +3 -0
- package/dist/rules/valid-timeout-minutes.js.map +1 -1
- package/dist/rules/valid-trigger-events.d.ts.map +1 -1
- package/dist/rules/valid-trigger-events.js +3 -0
- package/dist/rules/valid-trigger-events.js.map +1 -1
- package/docs/rules/action-name-casing.md +6 -2
- package/docs/rules/no-codeql-autobuild-for-javascript-typescript.md +55 -0
- package/docs/rules/no-codeql-javascript-typescript-split-language-matrix.md +51 -0
- package/docs/rules/no-empty-template-file-pattern.md +5 -1
- package/docs/rules/no-icon-file-extension-in-template-icon-name.md +5 -1
- package/docs/rules/no-overlapping-dependabot-directories.md +87 -0
- package/docs/rules/no-path-separators-in-template-icon-name.md +5 -1
- package/docs/rules/no-post-if-without-post.md +5 -1
- package/docs/rules/no-pre-if-without-pre.md +5 -1
- package/docs/rules/no-required-input-with-default.md +10 -1
- package/docs/rules/no-unknown-dependabot-multi-ecosystem-group.md +62 -0
- package/docs/rules/no-unused-dependabot-enable-beta-ecosystems.md +63 -0
- package/docs/rules/overview.md +47 -1
- package/docs/rules/prefer-inputs-context.md +6 -2
- package/docs/rules/presets/action-metadata.md +26 -15
- package/docs/rules/presets/all.md +129 -73
- package/docs/rules/presets/code-scanning.md +33 -0
- package/docs/rules/presets/dependabot.md +40 -0
- package/docs/rules/presets/index.md +139 -81
- package/docs/rules/presets/recommended.md +34 -23
- package/docs/rules/presets/security.md +39 -13
- package/docs/rules/presets/strict.md +56 -45
- package/docs/rules/presets/workflow-template-properties.md +26 -15
- package/docs/rules/presets/workflow-templates.md +30 -19
- package/docs/rules/require-codeql-actions-read.md +50 -0
- package/docs/rules/require-codeql-branch-filters.md +53 -0
- package/docs/rules/require-codeql-category-when-language-matrix.md +49 -0
- package/docs/rules/require-codeql-pull-request-trigger.md +53 -0
- package/docs/rules/require-codeql-schedule.md +57 -0
- package/docs/rules/require-codeql-security-events-write.md +50 -0
- package/docs/rules/require-dependabot-assignees.md +64 -0
- package/docs/rules/require-dependabot-automation-permissions.md +53 -0
- package/docs/rules/require-dependabot-automation-pull-request-trigger.md +49 -0
- package/docs/rules/require-dependabot-bot-actor-guard.md +52 -0
- package/docs/rules/require-dependabot-commit-message-include-scope.md +58 -0
- package/docs/rules/require-dependabot-commit-message-prefix-development.md +60 -0
- package/docs/rules/require-dependabot-commit-message-prefix.md +64 -0
- package/docs/rules/require-dependabot-cooldown.md +59 -0
- package/docs/rules/require-dependabot-directory.md +79 -0
- package/docs/rules/require-dependabot-github-actions-directory-root.md +62 -0
- package/docs/rules/require-dependabot-labels.md +65 -0
- package/docs/rules/require-dependabot-open-pull-requests-limit.md +58 -0
- package/docs/rules/require-dependabot-package-ecosystem.md +57 -0
- package/docs/rules/require-dependabot-patterns-for-multi-ecosystem-group.md +67 -0
- package/docs/rules/require-dependabot-schedule-cronjob.md +74 -0
- package/docs/rules/require-dependabot-schedule-interval.md +66 -0
- package/docs/rules/require-dependabot-schedule-time.md +60 -0
- package/docs/rules/require-dependabot-schedule-timezone.md +61 -0
- package/docs/rules/require-dependabot-target-branch.md +63 -0
- package/docs/rules/require-dependabot-updates.md +58 -0
- package/docs/rules/require-dependabot-version.md +70 -0
- package/docs/rules/require-dependabot-versioning-strategy-for-npm.md +58 -0
- package/docs/rules/require-dependency-review-action.md +60 -0
- package/docs/rules/require-dependency-review-fail-on-severity.md +57 -0
- package/docs/rules/require-dependency-review-permissions-contents-read.md +62 -0
- package/docs/rules/require-dependency-review-pull-request-trigger.md +57 -0
- package/docs/rules/require-fetch-metadata-github-token.md +49 -0
- package/docs/rules/require-job-name.md +6 -2
- package/docs/rules/require-job-step-name.md +11 -2
- package/docs/rules/require-sarif-upload-security-events-write.md +50 -0
- package/docs/rules/require-scorecard-results-format-sarif.md +49 -0
- package/docs/rules/require-scorecard-upload-sarif-step.md +55 -0
- package/docs/rules/require-secret-scan-contents-read.md +48 -0
- package/docs/rules/require-secret-scan-fetch-depth-zero.md +50 -0
- package/docs/rules/require-secret-scan-schedule.md +50 -0
- package/docs/rules/require-trufflehog-verified-results-mode.md +49 -0
- package/package.json +50 -57
package/dist/plugin.cjs.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
|
-
"sources": ["../src/plugin.ts", "../package.json", "../src/_internal/lint-targets.ts", "../src/_internal/workflow-yaml.ts", "../src/_internal/github-actions-config-references.ts", "../src/_internal/case-police-dictionary.ts", "../src/_internal/casing.ts", "../src/rules/action-name-casing.ts", "../src/rules/job-id-casing.ts", "../src/rules/max-jobs-per-action.ts", "../src/rules/no-case-insensitive-input-id-collision.ts", "../src/_internal/yaml-traversal.ts", "../src/rules/no-composite-input-env-access.ts", "../src/rules/no-deprecated-node-runtime.ts", "../src/rules/no-duplicate-composite-step-id.ts", "../src/_internal/workflow-template-properties.ts", "../src/rules/no-empty-template-file-pattern.ts", "../src/rules/no-external-job.ts", "../src/rules/no-hardcoded-default-branch-in-template.ts", "../src/rules/no-icon-file-extension-in-template-icon-name.ts", "../src/rules/no-inherit-secrets.ts", "../src/_internal/github-expressions.ts", "../src/rules/no-invalid-concurrency-context.ts", "../src/rules/no-invalid-key.ts", "../src/rules/no-invalid-reusable-workflow-job-key.ts", "../src/rules/no-invalid-template-file-pattern-regex.ts", "../src/rules/no-invalid-workflow-call-output-value.ts", "../src/rules/no-path-separators-in-template-icon-name.ts", "../src/rules/no-post-if-without-post.ts", "../src/rules/no-pr-head-checkout-in-pull-request-target.ts", "../src/rules/no-pre-if-without-pre.ts", "../src/rules/no-required-input-with-default.ts", "../src/rules/no-secrets-in-if.ts", "../src/rules/no-self-hosted-runner-on-fork-pr-events.ts", "../src/rules/no-subdirectory-template-file-pattern.ts", "../src/rules/no-template-placeholder-in-non-template-workflow.ts", "../src/rules/no-top-level-env.ts", "../src/rules/no-top-level-permissions.ts", "../src/rules/no-universal-template-file-pattern.ts", "../src/rules/no-unknown-input-reference-in-composite.ts", "../src/rules/no-unknown-job-output-reference.ts", "../src/rules/no-unknown-step-reference.ts", "../src/rules/no-untrusted-input-in-run.ts", "../src/rules/no-unused-input-in-composite.ts", "../src/rules/no-write-all-permissions.ts", "../src/rules/pin-action-shas.ts", "../src/rules/prefer-action-yml.ts", "../src/rules/prefer-fail-fast.ts", "../src/rules/prefer-file-extension.ts", "../src/rules/prefer-inputs-context.ts", "../src/rules/prefer-step-uses-style.ts", "../src/rules/prefer-template-yml-extension.ts", "../src/rules/require-action-name.ts", "../src/rules/require-action-run-name.ts", "../src/rules/require-checkout-before-local-action.ts", "../src/rules/require-composite-step-name.ts", "../src/rules/require-job-name.ts", "../src/rules/require-job-step-name.ts", "../src/rules/require-job-timeout-minutes.ts", "../src/rules/require-merge-group-trigger.ts", "../src/rules/require-pull-request-target-branches.ts", "../src/rules/require-run-step-shell.ts", "../src/rules/require-template-categories.ts", "../src/rules/require-template-file-patterns.ts", "../src/rules/require-template-icon-file-exists.ts", "../src/rules/require-template-icon-name.ts", "../src/rules/require-template-workflow-name.ts", "../src/rules/require-trigger-types.ts", "../src/rules/require-workflow-call-input-type.ts", "../src/rules/require-workflow-call-output-value.ts", "../src/rules/require-workflow-concurrency.ts", "../src/rules/require-workflow-dispatch-input-type.ts", "../src/rules/require-workflow-interface-description.ts", "../src/rules/require-workflow-permissions.ts", "../src/rules/require-workflow-run-branches.ts", "../src/rules/require-workflow-template-pair.ts", "../src/rules/require-workflow-template-properties-pair.ts", "../src/rules/valid-timeout-minutes.ts", "../src/_internal/github-actions-trigger-events.ts", "../src/rules/valid-trigger-events.ts", "../src/_internal/rules-registry.ts"],
|
|
4
|
-
"sourcesContent": ["/**\n * @packageDocumentation\n * Public plugin entrypoint for eslint-plugin-github-actions-2.\n */\nimport type { ESLint, Linter, Rule } from \"eslint\";\n\nimport * as yamlParser from \"yaml-eslint-parser\";\n\nimport type { GithubActionsRuleDocs } from \"./_internal/rule-docs.js\";\n\nimport packageJson from \"../package.json\" with { type: \"json\" };\nimport {\n githubActionsConfigMetadataByName,\n type GithubActionsConfigName,\n githubActionsConfigNames,\n type GithubActionsConfigReference,\n githubActionsConfigReferenceToName,\n} from \"./_internal/github-actions-config-references.js\";\nimport { githubActionsRules } from \"./_internal/rules-registry.js\";\n\n/** ESLint severity used by generated preset rule maps. */\nconst ERROR_SEVERITY = \"error\" as const;\n\n/** Runtime type for the plugin's generated config presets. */\nexport type GithubActionsConfigs = Record<\n GithubActionsConfigName,\n GithubActionsPresetConfig\n>;\n\n/** Flat config shape produced by this plugin. */\nexport type GithubActionsPresetConfig = Linter.Config & {\n rules: NonNullable<Linter.Config[\"rules\"]>;\n};\n\n/** Fully-qualified ESLint rule ids exposed by this plugin. */\nexport type GithubActionsRuleId = `github-actions/${GithubActionsRuleName}`;\n\n/** Unqualified rule names supported by eslint-plugin-github-actions-2. */\nexport type GithubActionsRuleName = keyof typeof githubActionsRules;\n\n/** Fully assembled plugin contract used by the runtime default export. */\ntype GithubActionsPluginContract = Omit<\n ESLint.Plugin,\n \"configs\" | \"meta\" | \"rules\"\n> & {\n configs: GithubActionsConfigs;\n meta: {\n name: string;\n namespace: string;\n version: string;\n };\n rules: NonNullable<ESLint.Plugin[\"rules\"]>;\n};\n\n/** Rule-map type used when expanding preset memberships. */\ntype RulesConfig = GithubActionsPresetConfig[\"rules\"];\n\n/** Resolve package version from package.json data. */\nfunction getPackageVersion(pkg: unknown): string {\n if (typeof pkg !== \"object\" || pkg === null) {\n return \"0.0.0\";\n }\n\n const version = Reflect.get(pkg, \"version\");\n\n return typeof version === \"string\" ? version : \"0.0.0\";\n}\n\n/** Determine whether a string is a valid config-reference token. */\nconst isGithubActionsConfigReference = (\n value: string\n): value is GithubActionsConfigReference =>\n Object.hasOwn(githubActionsConfigReferenceToName, value);\n\n/** Normalize stored rule docs config references to a validated string array. */\nconst getRuleConfigReferences = (\n ruleName: GithubActionsRuleName,\n rule: Readonly<Rule.RuleModule>\n): readonly GithubActionsConfigReference[] => {\n const docs = rule.meta?.docs as GithubActionsRuleDocs | undefined;\n const references = docs?.configs;\n const referenceList = Array.isArray(references) ? references : [references];\n\n if (referenceList.length === 0 || referenceList[0] === undefined) {\n throw new TypeError(\n `Rule '${ruleName}' is missing docs.configs preset metadata.`\n );\n }\n\n for (const reference of referenceList) {\n if (\n typeof reference !== \"string\" ||\n !isGithubActionsConfigReference(reference)\n ) {\n throw new TypeError(\n `Rule '${ruleName}' has an invalid config reference '${String(reference)}'.`\n );\n }\n }\n\n return referenceList;\n};\n\n/** Strongly typed ESLint rule view of the internal registry. */\nconst githubActionsEslintRules: NonNullable<ESLint.Plugin[\"rules\"]> &\n typeof githubActionsRules = githubActionsRules as NonNullable<\n ESLint.Plugin[\"rules\"]\n> &\n typeof githubActionsRules;\n\n/** Stable rule-entry list used by config derivation and docs tests. */\nconst githubActionsRuleEntries: readonly (readonly [\n GithubActionsRuleName,\n Rule.RuleModule,\n])[] = Object.entries(githubActionsRules) as readonly (readonly [\n GithubActionsRuleName,\n Rule.RuleModule,\n])[];\n\n/** Build a config-to-rule-name map from rule docs metadata. */\nconst createPresetRuleNamesByConfig = (): Record<\n GithubActionsConfigName,\n GithubActionsRuleName[]\n> => {\n const presetRuleNamesByConfig: Record<\n GithubActionsConfigName,\n GithubActionsRuleName[]\n > = {\n actionMetadata: [],\n all: [],\n recommended: [],\n security: [],\n strict: [],\n workflowTemplateProperties: [],\n workflowTemplates: [],\n };\n\n for (const [ruleName, rule] of githubActionsRuleEntries) {\n for (const reference of getRuleConfigReferences(ruleName, rule)) {\n const configName = githubActionsConfigReferenceToName[reference];\n\n if (configName === undefined) {\n continue;\n }\n\n presetRuleNamesByConfig[configName].push(ruleName);\n }\n }\n\n return presetRuleNamesByConfig;\n};\n\n/** Effective rule membership for every exported config preset. */\nconst presetRuleNamesByConfig: Readonly<\n Record<GithubActionsConfigName, readonly GithubActionsRuleName[]>\n> = createPresetRuleNamesByConfig();\n\n/** Build an ESLint rules map that enables each provided rule at error level. */\nfunction errorRulesFor(\n ruleNames: readonly GithubActionsRuleName[]\n): RulesConfig {\n const rules: RulesConfig = {};\n\n for (const ruleName of ruleNames) {\n rules[`github-actions/${ruleName}`] = ERROR_SEVERITY;\n }\n\n return rules;\n}\n\n/** Apply YAML parser and plugin registration to a preset config fragment. */\nfunction withGithubActionsPlugin(\n config: Readonly<GithubActionsPresetConfig>,\n plugin: Readonly<ESLint.Plugin>\n): GithubActionsPresetConfig {\n const existingLanguageOptions = config.languageOptions ?? {};\n const existingParserOptions = existingLanguageOptions[\"parserOptions\"];\n\n return {\n ...config,\n languageOptions: {\n ...existingLanguageOptions,\n parser: existingLanguageOptions[\"parser\"] ?? yamlParser,\n parserOptions:\n existingParserOptions !== null &&\n typeof existingParserOptions === \"object\" &&\n !Array.isArray(existingParserOptions)\n ? { ...existingParserOptions }\n : {},\n },\n plugins: {\n ...config.plugins,\n \"github-actions\": plugin,\n },\n };\n}\n\n/** Minimal plugin view used while assembling exported presets. */\nconst pluginForConfigs: ESLint.Plugin = {\n rules: githubActionsEslintRules,\n};\n\n/** Create every exported flat-config preset from static metadata. */\nconst createGithubActionsConfigsDefinition = (): GithubActionsConfigs => {\n const configs = {} as GithubActionsConfigs;\n\n for (const configName of githubActionsConfigNames) {\n const metadata = githubActionsConfigMetadataByName[configName];\n\n configs[configName] = withGithubActionsPlugin(\n {\n files: [...metadata.files],\n name: metadata.presetName,\n rules: errorRulesFor(presetRuleNamesByConfig[configName]),\n },\n pluginForConfigs\n );\n }\n\n return configs;\n};\n\n/** Finalized typed view of all exported flat-config presets. */\nconst githubActionsConfigs: GithubActionsConfigs =\n createGithubActionsConfigsDefinition();\n\n/** Main plugin object exported for ESLint consumption. */\nconst githubActionsPlugin: GithubActionsPluginContract = {\n configs: githubActionsConfigs,\n meta: {\n name: \"eslint-plugin-github-actions-2\",\n namespace: \"github-actions\",\n version: getPackageVersion(packageJson),\n },\n processors: {},\n rules: githubActionsEslintRules,\n};\n\n/** Runtime type for the plugin object exported as default. */\nexport type GithubActionsPlugin = typeof githubActionsPlugin;\n\n/** Default plugin export consumed by ESLint flat config. */\nexport default githubActionsPlugin;\n", "{\n \"$schema\": \"https://www.schemastore.org/package.json\",\n \"name\": \"eslint-plugin-github-actions-2\",\n \"version\": \"1.0.2\",\n \"private\": false,\n \"description\": \"ESLint plugin for GitHub Actions workflow quality, reliability, and security rules.\",\n \"keywords\": [\n \"eslint\",\n \"eslint-plugin\",\n \"eslintplugin\",\n \"github\",\n \"github-actions\",\n \"workflow\",\n \"yaml\"\n ],\n \"homepage\": \"https://github.com/Nick2bad4u/eslint-plugin-github-actions-2\",\n \"bugs\": {\n \"url\": \"https://github.com/Nick2bad4u/eslint-plugin-github-actions-2/issues\",\n \"email\": \"20943337+Nick2bad4u@users.noreply.github.com\"\n },\n \"repository\": {\n \"type\": \"git\",\n \"url\": \"git+https://github.com/Nick2bad4u/eslint-plugin-github-actions-2.git\"\n },\n \"license\": \"MIT\",\n \"author\": \"Nick2bad4u <20943337+Nick2bad4u@users.noreply.github.com> (https://github.com/Nick2bad4u)\",\n \"contributors\": [\n {\n \"name\": \"Nick2bad4u\",\n \"email\": \"20943337+Nick2bad4u@users.noreply.github.com\",\n \"url\": \"https://github.com/Nick2bad4u\"\n }\n ],\n \"sideEffects\": false,\n \"type\": \"module\",\n \"exports\": {\n \".\": {\n \"import\": {\n \"types\": \"./dist/plugin.d.ts\",\n \"default\": \"./dist/plugin.js\"\n },\n \"require\": {\n \"types\": \"./dist/plugin.d.cts\",\n \"default\": \"./dist/plugin.cjs\"\n },\n \"default\": \"./dist/plugin.js\"\n },\n \"./package.json\": \"./package.json\"\n },\n \"main\": \"./dist/plugin.cjs\",\n \"types\": \"./dist/plugin.d.ts\",\n \"files\": [\n \"dist\",\n \"docs/rules/**\",\n \"CHANGELOG.md\"\n ],\n \"workspaces\": [\n \"docs/docusaurus\"\n ],\n \"scripts\": {\n \"build\": \"tsc -p tsconfig.build.json && npm run build:types:cjs && npm run build:cjs\",\n \"build:cjs\": \"esbuild dist/plugin.js --bundle --format=cjs --platform=node --packages=external --sourcemap --outfile=dist/plugin.cjs --footer:js=\\\"module.exports = module.exports.default;\\\"\",\n \"build:clean\": \"node -e \\\"require('node:fs').rmSync('dist',{recursive:true,force:true})\\\"\",\n \"build:eslint-inspector\": \"npx -y @eslint/config-inspector@1.4.2 build --outDir \\\"docs/docusaurus/static/eslint-inspector\\\" --base \\\"/eslint-plugin-github-actions-2/eslint-inspector/\\\"\",\n \"build:eslint-inspector:local\": \"npx @eslint/config-inspector\",\n \"build:stylelint-inspector\": \"npx -y stylelint-config-inspector@latest build --outDir \\\"docs/docusaurus/static/stylelint-inspector\\\" --base \\\"/eslint-plugin-github-actions-2/stylelint-inspector/\\\"\",\n \"build:stylelint-inspector:local\": \"npx stylelint-config-inspector@latest\",\n \"build:types:cjs\": \"node -e \\\"require('node:fs').copyFileSync('dist/plugin.d.ts','dist/plugin.d.cts')\\\"\",\n \"changelog:release-notes\": \"git-cliff --config cliff.toml --latest --strip header\",\n \"clean:cache\": \"rimraf dist coverage cache .cache .vite .turbo\",\n \"clean:cache:coverage\": \"rimraf coverage .coverage\",\n \"clean:cache:dist\": \"rimraf dist release\",\n \"clean:cache:eslint\": \"rimraf .cache/.eslintcache\",\n \"clean:cache:prettier\": \"rimraf .cache/.prettier-cache .prettier-cache .prettiercache\",\n \"clean:cache:stylelint\": \"rimraf .cache/stylelintcache stylelintcache .stylelintcache\",\n \"clean:cache:typescript\": \"rimraf .cache/**.tsbuildinfo .cache/builds\",\n \"clean:cache:vite\": \"rimraf .cache/vite .cache/vitest .cache/vitest-zero-coverage .cache/vite-zero-coverage\",\n \"clean:docs\": \"rimraf docs/docusaurus/.docusaurus/** docs/docusaurus/build/**\",\n \"clean:docusaurus\": \"npm run clean:docs && npm run --workspace docs/docusaurus clear\",\n \"docs:api\": \"npm run --workspace docs/docusaurus docs:api\",\n \"docs:api:local\": \"npm run --workspace docs/docusaurus docs:api:local\",\n \"docs:build\": \"npm run --workspace docs/docusaurus build\",\n \"docs:build:local\": \"npm run --workspace docs/docusaurus build:local\",\n \"docs:serve\": \"npm run --workspace docs/docusaurus serve\",\n \"docs:start\": \"npm run --workspace docs/docusaurus start\",\n \"docs:start:devtools\": \"npm run docs:api:local && npm run --workspace docs/docusaurus start:devtools\",\n \"docs:typecheck\": \"npm run --workspace docs/docusaurus typecheck\",\n \"lint\": \"cross-env NODE_OPTIONS=--max_old_space_size=16384 eslint --cache --cache-strategy content --cache-location .cache/.eslintcache\",\n \"lint:action\": \"npm run lint:actions\",\n \"lint:actions\": \"node scripts/lint-actionlint.mjs\",\n \"lint:all\": \"npm run lint && npm run lint:css && npm run lint:prettier && npm run lint:remark && npm run lint:package && npm run lint:secretlint && npm run lint:yaml && npm run lint:actions && npm run lint:circular\",\n \"lint:all:fix\": \"npm run lint:fix && npm run lint:css:fix && npm run lint:prettier:fix && npm run lint:remark && npm run lint:package && npm run lint:secretlint && npm run lint:yaml:fix && npm run lint:actions && npm run lint:circular\",\n \"lint:all:fix:quiet\": \"npm run lint:fix:quiet && npm run lint:css:fix && npm run lint:prettier:fix && npm run lint:remark && npm run lint:package && npm run lint:secretlint && npm run lint:yaml:fix && npm run lint:actions && npm run lint:circular\",\n \"lint:circular\": \"npm run madge:circular\",\n \"lint:compat\": \"npm run lint:compat:eslint9 --\",\n \"lint:compat:eslint9\": \"node scripts/lint-compat-eslint9.mjs\",\n \"lint:config:build\": \"npm run build:eslint-inspector\",\n \"lint:config:inspect\": \"npx eslint --inspect-config\",\n \"lint:css\": \"stylelint --cache --config stylelint.config.mjs --cache-strategy content --cache-location .cache/stylelintcache src/ docs/ --custom-formatter stylelint-formatter-pretty && echo \\\"Stylelint done!\\\"\",\n \"lint:css:fix\": \"stylelint --cache --config stylelint.config.mjs --cache-strategy content --cache-location .cache/stylelintcache src/ docs/ --custom-formatter stylelint-formatter-pretty --fix && echo \\\"Stylelint done!\\\"\",\n \"lint:fix\": \"cross-env NODE_OPTIONS=--max_old_space_size=16384 eslint --cache --cache-strategy content --cache-location .cache/.eslintcache --fix\",\n \"lint:fix:quiet\": \"cross-env ESLINT_PROGRESS=off NODE_OPTIONS=--max_old_space_size=16384 eslint --cache --cache-strategy content --cache-location .cache/.eslintcache --fix && echo \\\"Eslint fix done!\\\"\",\n \"lint:grype\": \"grype . -c .grype.yaml --name eslint-plugin-github-actions-2\",\n \"lint:package\": \"npm run lint:package-sort && npm run lint:packagelintrc && echo \\\"Package.json lint done!\\\"\",\n \"lint:package-check\": \"publint && attw --pack .\",\n \"lint:package-sort\": \"sort-package-json \\\"./package.json\\\" \\\"./docs/docusaurus/package.json\\\"\",\n \"lint:package-sort-check\": \"sort-package-json --check \\\"./package.json\\\" \\\"./docs/docusaurus/package.json\\\"\",\n \"lint:packagelintrc\": \"npmPkgJsonLint . --config .npmpackagejsonlintrc.json\",\n \"lint:prettier\": \"prettier . --log-level warn --cache --cache-location=.cache/.prettier-cache --cache-strategy=content --check\",\n \"lint:prettier:fix\": \"prettier . --log-level warn --cache --cache-location=.cache/.prettier-cache --cache-strategy=content --write\",\n \"lint:quiet\": \"cross-env ESLINT_PROGRESS=nofile NODE_OPTIONS=--max_old_space_size=16384 eslint --cache --cache-strategy content --cache-location .cache/.eslintcache && echo \\\"Eslint done!\\\"\",\n \"lint:remark\": \"remark --rc-path .remarkrc.mjs --silently-ignore --ignore-path .remarkignore --frail \\\"*.{md,mdx}\\\" \\\"docs/**/*.{md,mdx}\\\" --quiet\",\n \"lint:remark:fix\": \"prettier --log-level warn --ignore-path prettierignore.remark --cache --cache-location=.cache/.prettier-cache --cache-strategy=content --no-error-on-unmatched-pattern --write \\\"*.{md,mdx}\\\" \\\"docs/**/*.{md,mdx}\\\" && npm run remark:fix\",\n \"lint:secretlint\": \"secretlint --secretlintrc .secretlintrc.json --secretlintignore .secretlintignore \\\"./*\\\" \\\".vscode/**\\\" \\\"assets/**\\\" \\\"src/**\\\" \\\"electron/**\\\" \\\"shared/**\\\" \\\"config/**\\\" \\\"scripts/**\\\" \\\"playwright/**\\\" \\\"storybook/**\\\" \\\".storybook\\\" \\\"tests/**\\\" \\\"benchmarks/**\\\" \\\".devin/**\\\" \\\"public/**\\\" \\\".github/**\\\" \\\"docs/Architecture/**\\\" \\\"docs/*\\\" \\\"docs/assets/**\\\" \\\"docs/Guides/**\\\" \\\"docs/Testing/**\\\" \\\"docs/TSDoc/**\\\" \\\"docs/docusaurus/src/**\\\" \\\"docs/docusaurus/static/**\\\" \\\"docs/docusaurus/blog/**\\\" \\\"docs/docusaurus/docs/**\\\" \\\"docs/docusaurus/docs/*\\\"\",\n \"lint:yaml\": \"cross-env NODE_OPTIONS=--max_old_space_size=16384 eslint --cache --cache-strategy content --cache-location .cache/.eslintcache \\\"**/*.{yml,yaml}\\\" && echo \\\"YAML lint done!\\\"\",\n \"lint:yaml:fix\": \"cross-env NODE_OPTIONS=--max_old_space_size=16384 eslint --cache --cache-strategy content --cache-location .cache/.eslintcache --fix \\\"**/*.{yml,yaml}\\\" && echo \\\"YAML lint (fix) done!\\\"\",\n \"madge:circular\": \"madge --circular --no-spinner --ts-config tsconfig.json --extensions ts,tsx,js,jsx,mjs,cjs,cts,mts ./src --exclude \\\"(^|[\\\\/])(test|dist|node_modules|cache|.cache|coverage|build|eslint-inspector|temp|.docusaurus)($|[\\\\/])|\\\\.css$\\\"\",\n \"prepublishOnly\": \"npm run release:verify\",\n \"release:check\": \"npm run release:verify\",\n \"release:verify\": \"npm run build && npm run lint && npm run typecheck && npm run test && npm run docs:build && npm pack --dry-run\",\n \"remark:fix\": \"remark --rc-path .remarkrc.mjs --silently-ignore --ignore-path .remarkignore --frail --quiet --output -- \\\"*.{md,mdx}\\\" \\\"docs/**/*.{md,mdx}\\\"\",\n \"sync:peer-eslint-range\": \"node scripts/sync-peer-eslint-range.mjs\",\n \"sync:readme-rules-table\": \"node scripts/sync-readme-rules-table.mjs\",\n \"sync:readme-rules-table:write\": \"node scripts/sync-readme-rules-table.mjs --write\",\n \"pretest\": \"npm run build\",\n \"test\": \"vitest run\",\n \"test:ci\": \"cross-env CI=true vitest run --reporter=default\",\n \"test:coverage\": \"vitest run --coverage --reporter=default\",\n \"test:quiet\": \"vitest run --reporter=default --silent\",\n \"test:serial\": \"cross-env MAX_THREADS=1 vitest run\",\n \"test:verbose\": \"vitest run --reporter=verbose\",\n \"test:watch\": \"vitest\",\n \"typecheck\": \"tsc -p tsconfig.json --noEmit && tsc -p tsconfig.build.json --noEmit && tsc -p tsconfig.eslint.json --noEmit && tsc -p tsconfig.js.json --noEmit && npm run --workspace docs/docusaurus typecheck\",\n \"update-deps\": \"npx ncu -i --install never && npm run sync:peer-eslint-range && npm install --force\",\n \"verify:readme-rules-table\": \"npm run build && npm run sync:readme-rules-table\"\n },\n \"overrides\": {\n \"jsonc-eslint-parser\": \"$jsonc-eslint-parser\"\n },\n \"dependencies\": {\n \"yaml-eslint-parser\": \"^2.0.0\"\n },\n \"devDependencies\": {\n \"@arethetypeswrong/cli\": \"^0.18.2\",\n \"@csstools/stylelint-formatter-github\": \"^2.0.0\",\n \"@docusaurus/eslint-plugin\": \"^3.9.2\",\n \"@double-great/remark-lint-alt-text\": \"^1.1.1\",\n \"@double-great/stylelint-a11y\": \"^3.4.7\",\n \"@eslint-community/eslint-plugin-eslint-comments\": \"^4.7.1\",\n \"@eslint-react/eslint-plugin\": \"^3.0.0\",\n \"@eslint/compat\": \"^2.0.3\",\n \"@eslint/config-helpers\": \"^0.5.3\",\n \"@eslint/config-inspector\": \"^1.5.0\",\n \"@eslint/css\": \"^1.0.0\",\n \"@eslint/js\": \"^10.0.1\",\n \"@eslint/json\": \"^1.2.0\",\n \"@eslint/markdown\": \"^7.5.1\",\n \"@html-eslint/eslint-plugin\": \"^0.58.1\",\n \"@html-eslint/parser\": \"^0.58.1\",\n \"@microsoft/eslint-plugin-sdl\": \"^1.1.0\",\n \"@microsoft/tsdoc-config\": \"^0.18.1\",\n \"@secretlint/secretlint-rule-anthropic\": \"^11.4.0\",\n \"@secretlint/secretlint-rule-aws\": \"^11.4.0\",\n \"@secretlint/secretlint-rule-database-connection-string\": \"^11.4.0\",\n \"@secretlint/secretlint-rule-gcp\": \"^11.4.0\",\n \"@secretlint/secretlint-rule-github\": \"^11.4.0\",\n \"@secretlint/secretlint-rule-no-dotenv\": \"^11.4.0\",\n \"@secretlint/secretlint-rule-no-homedir\": \"^11.4.0\",\n \"@secretlint/secretlint-rule-npm\": \"^11.4.0\",\n \"@secretlint/secretlint-rule-openai\": \"^11.4.0\",\n \"@secretlint/secretlint-rule-pattern\": \"^11.4.0\",\n \"@secretlint/secretlint-rule-preset-recommend\": \"^11.4.0\",\n \"@secretlint/secretlint-rule-privatekey\": \"^11.4.0\",\n \"@secretlint/secretlint-rule-secp256k1-privatekey\": \"^11.4.0\",\n \"@secretlint/types\": \"^11.4.0\",\n \"@softonus/prettier-plugin-duplicate-remover\": \"^1.1.2\",\n \"@stryker-ignorer/console-all\": \"^0.3.2\",\n \"@stryker-mutator/core\": \"^9.6.0\",\n \"@stryker-mutator/typescript-checker\": \"^9.6.0\",\n \"@stryker-mutator/vitest-runner\": \"^9.6.0\",\n \"@stylelint-types/stylelint-order\": \"^7.0.1\",\n \"@stylelint-types/stylelint-stylistic\": \"^5.0.0\",\n \"@stylistic/eslint-plugin\": \"^5.10.0\",\n \"@stylistic/stylelint-plugin\": \"^5.0.1\",\n \"@types/eslint-plugin-jsx-a11y\": \"^6.10.1\",\n \"@types/eslint-plugin-security\": \"^3.0.1\",\n \"@types/htmlhint\": \"^1.1.5\",\n \"@types/madge\": \"^5.0.3\",\n \"@types/node\": \"^25.5.0\",\n \"@types/postcss-clamp\": \"^4.1.3\",\n \"@types/postcss-flexbugs-fixes\": \"^5.0.3\",\n \"@types/postcss-html\": \"^1.5.3\",\n \"@types/postcss-import\": \"^14.0.3\",\n \"@types/postcss-inline-svg\": \"^5.0.4\",\n \"@types/postcss-normalize\": \"^9.0.4\",\n \"@types/postcss-reporter\": \"^7.0.5\",\n \"@types/sloc\": \"^0.2.3\",\n \"@typescript-eslint/eslint-plugin\": \"^8.57.2\",\n \"@typescript-eslint/parser\": \"^8.57.2\",\n \"@typescript-eslint/rule-tester\": \"^8.57.2\",\n \"@vitest/coverage-v8\": \"^4.1.1\",\n \"@vitest/eslint-plugin\": \"^1.6.13\",\n \"@vitest/ui\": \"^4.1.1\",\n \"actionlint\": \"^2.0.6\",\n \"all-contributors-cli\": \"^6.26.1\",\n \"cognitive-complexity-ts\": \"^0.8.1\",\n \"commitlint\": \"^20.5.0\",\n \"commitlint-config-gitmoji\": \"^2.3.1\",\n \"cross-env\": \"^10.1.0\",\n \"depcheck\": \"^1.4.7\",\n \"detect-secrets\": \"^1.0.6\",\n \"eslint\": \"^10.1.0\",\n \"eslint-config-flat-gitignore\": \"^2.3.0\",\n \"eslint-config-prettier\": \"^10.1.8\",\n \"eslint-formatter-unix\": \"^9.0.1\",\n \"eslint-import-resolver-typescript\": \"^4.4.4\",\n \"eslint-plugin-array-func\": \"^5.1.1\",\n \"eslint-plugin-canonical\": \"^5.1.3\",\n \"eslint-plugin-case-police\": \"^2.2.0\",\n \"eslint-plugin-comment-length\": \"^2.3.0\",\n \"eslint-plugin-css-modules\": \"^2.12.0\",\n \"eslint-plugin-de-morgan\": \"^2.1.1\",\n \"eslint-plugin-depend\": \"^1.5.0\",\n \"eslint-plugin-eslint-plugin\": \"^7.3.2\",\n \"eslint-plugin-etc\": \"^2.0.3\",\n \"eslint-plugin-etc-misc\": \"^1.0.4\",\n \"eslint-plugin-file-progress-2\": \"^3.4.3\",\n \"eslint-plugin-html\": \"^8.1.4\",\n \"eslint-plugin-import-x\": \"^4.16.2\",\n \"eslint-plugin-jsdoc\": \"^62.8.0\",\n \"eslint-plugin-jsonc\": \"^3.1.2\",\n \"eslint-plugin-jsx-a11y\": \"^6.10.2\",\n \"eslint-plugin-listeners\": \"^1.5.1\",\n \"eslint-plugin-loadable-imports\": \"^1.0.1\",\n \"eslint-plugin-math\": \"^0.13.1\",\n \"eslint-plugin-module-interop\": \"^0.3.1\",\n \"eslint-plugin-n\": \"^17.24.0\",\n \"eslint-plugin-nitpick\": \"^0.12.0\",\n \"eslint-plugin-no-barrel-files\": \"^1.2.2\",\n \"eslint-plugin-no-explicit-type-exports\": \"^0.12.1\",\n \"eslint-plugin-no-function-declare-after-return\": \"^1.1.0\",\n \"eslint-plugin-no-lookahead-lookbehind-regexp\": \"^0.4.0\",\n \"eslint-plugin-no-only-tests\": \"^3.3.0\",\n \"eslint-plugin-no-secrets\": \"^2.3.3\",\n \"eslint-plugin-no-unsanitized\": \"^4.1.5\",\n \"eslint-plugin-no-use-extend-native\": \"^0.7.2\",\n \"eslint-plugin-node-dependencies\": \"^2.2.0\",\n \"eslint-plugin-package-json\": \"^0.91.0\",\n \"eslint-plugin-perfectionist\": \"^5.7.0\",\n \"eslint-plugin-prefer-arrow\": \"^1.2.3\",\n \"eslint-plugin-prettier\": \"^5.5.5\",\n \"eslint-plugin-promise\": \"^7.2.1\",\n \"eslint-plugin-redos\": \"^4.5.0\",\n \"eslint-plugin-regexp\": \"^3.1.0\",\n \"eslint-plugin-require-jsdoc\": \"^1.0.4\",\n \"eslint-plugin-security\": \"^4.0.0\",\n \"eslint-plugin-sonarjs\": \"^4.0.2\",\n \"eslint-plugin-sort-class-members\": \"^1.21.0\",\n \"eslint-plugin-testing-library\": \"^7.16.2\",\n \"eslint-plugin-toml\": \"^1.3.1\",\n \"eslint-plugin-total-functions\": \"^7.1.0\",\n \"eslint-plugin-tsdoc\": \"^0.5.2\",\n \"eslint-plugin-tsdoc-require-2\": \"^1.0.6\",\n \"eslint-plugin-undefined-css-classes\": \"^0.1.5\",\n \"eslint-plugin-unicorn\": \"^63.0.0\",\n \"eslint-plugin-unused-imports\": \"^4.4.1\",\n \"eslint-plugin-write-good-comments\": \"^0.2.0\",\n \"eslint-plugin-yml\": \"^3.3.1\",\n \"fast-check\": \"^4.6.0\",\n \"git-cliff\": \"^2.12.0\",\n \"gitleaks-secret-scanner\": \"^2.1.1\",\n \"globals\": \"^17.4.0\",\n \"htmlhint\": \"^1.9.2\",\n \"jscpd\": \"^4.0.8\",\n \"jsonc-eslint-parser\": \"^3.1.0\",\n \"knip\": \"^6.0.5\",\n \"leasot\": \"^14.4.0\",\n \"madge\": \"^8.0.0\",\n \"markdown-link-check\": \"^3.14.2\",\n \"npm-check-updates\": \"^19.6.5\",\n \"npm-package-json-lint\": \"^9.1.0\",\n \"picocolors\": \"^1.1.1\",\n \"postcss\": \"^8.5.8\",\n \"postcss-assets\": \"^6.0.0\",\n \"postcss-clamp\": \"^4.1.0\",\n \"postcss-combine-duplicated-selectors\": \"^10.0.3\",\n \"postcss-flexbugs-fixes\": \"^5.0.2\",\n \"postcss-html\": \"^1.8.1\",\n \"postcss-import\": \"^16.1.1\",\n \"postcss-inline-svg\": \"^6.0.0\",\n \"postcss-logical\": \"^9.0.0\",\n \"postcss-normalize\": \"^13.0.1\",\n \"postcss-reporter\": \"^7.1.0\",\n \"postcss-round-subpixels\": \"^2.0.0\",\n \"postcss-scss\": \"^4.0.9\",\n \"postcss-sort-media-queries\": \"^6.3.3\",\n \"postcss-styled-jsx\": \"^1.0.1\",\n \"postcss-styled-syntax\": \"^0.7.1\",\n \"postcss-viewport-height-correction\": \"^1.1.1\",\n \"prettier\": \"^3.8.1\",\n \"prettier-plugin-ini\": \"^1.3.0\",\n \"prettier-plugin-interpolated-html-tags\": \"^2.0.1\",\n \"prettier-plugin-jsdoc\": \"^1.8.0\",\n \"prettier-plugin-jsdoc-type\": \"^0.2.0\",\n \"prettier-plugin-merge\": \"^0.10.0\",\n \"prettier-plugin-multiline-arrays\": \"^4.1.5\",\n \"prettier-plugin-packagejson\": \"^3.0.2\",\n \"prettier-plugin-properties\": \"^0.3.1\",\n \"prettier-plugin-sort-json\": \"^4.2.0\",\n \"prettier-plugin-toml\": \"^2.0.6\",\n \"publint\": \"^0.3.18\",\n \"recheck-jar\": \"^4.5.0\",\n \"rehype-katex\": \"^7.0.1\",\n \"remark\": \"^15.0.1\",\n \"remark-cli\": \"^12.0.1\",\n \"remark-directive\": \"^4.0.0\",\n \"remark-frontmatter\": \"^5.0.0\",\n \"remark-gfm\": \"^4.0.1\",\n \"remark-ignore\": \"^3.0.0\",\n \"remark-inline-links\": \"^7.0.0\",\n \"remark-lint\": \"^10.0.1\",\n \"remark-lint-blockquote-indentation\": \"^4.0.1\",\n \"remark-lint-check-toc\": \"^1.0.0\",\n \"remark-lint-checkbox-character-style\": \"^5.0.1\",\n \"remark-lint-checkbox-content-indent\": \"^5.0.1\",\n \"remark-lint-code-block-split-list\": \"^1.0.0\",\n \"remark-lint-code-block-style\": \"^4.0.1\",\n \"remark-lint-correct-media-syntax\": \"^1.0.1\",\n \"remark-lint-definition-case\": \"^4.0.1\",\n \"remark-lint-definition-sort\": \"^1.0.1\",\n \"remark-lint-definition-spacing\": \"^4.0.1\",\n \"remark-lint-directive-attribute-sort\": \"^1.0.1\",\n \"remark-lint-directive-collapsed-attribute\": \"^1.0.1\",\n \"remark-lint-directive-quote-style\": \"^1.0.1\",\n \"remark-lint-directive-shortcut-attribute\": \"^1.0.1\",\n \"remark-lint-directive-unique-attribute-name\": \"^1.0.1\",\n \"remark-lint-emphasis-marker\": \"^4.0.1\",\n \"remark-lint-fenced-code-flag\": \"^4.2.0\",\n \"remark-lint-fenced-code-flag-case\": \"^3.0.0\",\n \"remark-lint-fenced-code-marker\": \"^4.0.1\",\n \"remark-lint-file-extension\": \"^3.0.1\",\n \"remark-lint-final-definition\": \"^4.0.2\",\n \"remark-lint-final-newline\": \"^3.0.1\",\n \"remark-lint-first-heading-level\": \"^4.0.1\",\n \"remark-lint-frontmatter-schema\": \"^3.15.4\",\n \"remark-lint-hard-break-spaces\": \"^4.1.1\",\n \"remark-lint-heading-capitalization\": \"^1.3.0\",\n \"remark-lint-heading-increment\": \"^4.0.1\",\n \"remark-lint-heading-style\": \"^4.0.1\",\n \"remark-lint-heading-whitespace\": \"^1.0.0\",\n \"remark-lint-linebreak-style\": \"^4.0.1\",\n \"remark-lint-link-title-style\": \"^4.0.1\",\n \"remark-lint-list-item-bullet-indent\": \"^5.0.1\",\n \"remark-lint-list-item-content-indent\": \"^4.0.1\",\n \"remark-lint-list-item-indent\": \"^4.0.1\",\n \"remark-lint-list-item-spacing\": \"^5.0.1\",\n \"remark-lint-maximum-heading-length\": \"^4.1.1\",\n \"remark-lint-maximum-line-length\": \"^4.1.1\",\n \"remark-lint-mdx-jsx-attribute-sort\": \"^1.0.1\",\n \"remark-lint-mdx-jsx-no-void-children\": \"^1.0.1\",\n \"remark-lint-mdx-jsx-quote-style\": \"^1.0.1\",\n \"remark-lint-mdx-jsx-self-close\": \"^1.0.1\",\n \"remark-lint-mdx-jsx-shorthand-attribute\": \"^1.0.1\",\n \"remark-lint-mdx-jsx-unique-attribute-name\": \"^1.0.1\",\n \"remark-lint-media-style\": \"^1.0.1\",\n \"remark-lint-no-blockquote-without-marker\": \"^6.0.1\",\n \"remark-lint-no-consecutive-blank-lines\": \"^5.0.1\",\n \"remark-lint-no-dead-urls\": \"^2.0.1\",\n \"remark-lint-no-duplicate-defined-urls\": \"^3.0.1\",\n \"remark-lint-no-duplicate-definitions\": \"^4.0.1\",\n \"remark-lint-no-duplicate-headings\": \"^4.0.1\",\n \"remark-lint-no-duplicate-headings-in-section\": \"^4.0.1\",\n \"remark-lint-no-emphasis-as-heading\": \"^4.0.1\",\n \"remark-lint-no-empty-sections\": \"^4.0.0\",\n \"remark-lint-no-empty-url\": \"^4.0.1\",\n \"remark-lint-no-file-name-articles\": \"^3.0.1\",\n \"remark-lint-no-file-name-consecutive-dashes\": \"^3.0.1\",\n \"remark-lint-no-file-name-irregular-characters\": \"^3.0.1\",\n \"remark-lint-no-file-name-mixed-case\": \"^3.0.1\",\n \"remark-lint-no-file-name-outer-dashes\": \"^3.0.1\",\n \"remark-lint-no-heading-content-indent\": \"^5.0.1\",\n \"remark-lint-no-heading-indent\": \"^5.0.1\",\n \"remark-lint-no-heading-like-paragraph\": \"^4.0.1\",\n \"remark-lint-no-heading-punctuation\": \"^4.0.1\",\n \"remark-lint-no-hidden-table-cell\": \"^1.0.1\",\n \"remark-lint-no-html\": \"^4.0.1\",\n \"remark-lint-no-literal-urls\": \"^4.0.1\",\n \"remark-lint-no-missing-blank-lines\": \"^4.0.1\",\n \"remark-lint-no-multiple-toplevel-headings\": \"^4.0.1\",\n \"remark-lint-no-paragraph-content-indent\": \"^5.0.1\",\n \"remark-lint-no-reference-like-url\": \"^4.0.1\",\n \"remark-lint-no-shell-dollars\": \"^4.0.1\",\n \"remark-lint-no-shortcut-reference-image\": \"^4.0.1\",\n \"remark-lint-no-shortcut-reference-link\": \"^4.0.1\",\n \"remark-lint-no-table-indentation\": \"^5.0.1\",\n \"remark-lint-no-tabs\": \"^4.0.1\",\n \"remark-lint-no-undefined-references\": \"^5.0.2\",\n \"remark-lint-no-unneeded-full-reference-image\": \"^4.0.1\",\n \"remark-lint-no-unneeded-full-reference-link\": \"^4.0.1\",\n \"remark-lint-no-unused-definitions\": \"^4.0.2\",\n \"remark-lint-ordered-list-marker-style\": \"^4.0.1\",\n \"remark-lint-ordered-list-marker-value\": \"^4.0.1\",\n \"remark-lint-rule-style\": \"^4.0.1\",\n \"remark-lint-strikethrough-marker\": \"^3.0.1\",\n \"remark-lint-strong-marker\": \"^4.0.1\",\n \"remark-lint-table-cell-padding\": \"^5.1.1\",\n \"remark-lint-table-pipe-alignment\": \"^4.1.1\",\n \"remark-lint-table-pipes\": \"^5.0.1\",\n \"remark-lint-unordered-list-marker-style\": \"^4.0.1\",\n \"remark-lint-write-good\": \"^1.2.0\",\n \"remark-math\": \"^6.0.0\",\n \"remark-preset-lint-consistent\": \"^6.0.1\",\n \"remark-preset-lint-markdown-style-guide\": \"^6.0.1\",\n \"remark-preset-lint-recommended\": \"^7.0.1\",\n \"remark-preset-prettier\": \"^2.0.2\",\n \"remark-toc\": \"^9.0.0\",\n \"remark-validate-links\": \"^13.1.0\",\n \"remark-wiki-link\": \"^2.0.1\",\n \"rimraf\": \"^6.1.3\",\n \"secretlint\": \"^11.4.0\",\n \"sloc\": \"^0.3.2\",\n \"sort-package-json\": \"^3.6.1\",\n \"stylelint\": \"^17.5.0\",\n \"stylelint-actions-formatters\": \"^16.3.1\",\n \"stylelint-checkstyle-formatter\": \"^0.1.2\",\n \"stylelint-codeframe-formatter\": \"^1.2.0\",\n \"stylelint-config-alphabetical-order\": \"^2.0.0\",\n \"stylelint-config-idiomatic-order\": \"^10.0.0\",\n \"stylelint-config-inspector\": \"^2.0.3\",\n \"stylelint-config-recess-order\": \"^7.7.0\",\n \"stylelint-config-recommended\": \"^18.0.0\",\n \"stylelint-config-sass-guidelines\": \"^13.0.0\",\n \"stylelint-config-standard\": \"^40.0.0\",\n \"stylelint-config-standard-scss\": \"^17.0.0\",\n \"stylelint-config-tailwindcss\": \"^1.0.1\",\n \"stylelint-declaration-block-no-ignored-properties\": \"^3.0.0\",\n \"stylelint-declaration-strict-value\": \"^1.11.1\",\n \"stylelint-define-config\": \"^17.5.0\",\n \"stylelint-find-new-rules\": \"^6.0.0\",\n \"stylelint-formatter-gitlab-code-quality-report\": \"^1.1.0\",\n \"stylelint-formatter-pretty\": \"^4.0.1\",\n \"stylelint-gamut\": \"^2.0.0\",\n \"stylelint-group-selectors\": \"^1.0.10\",\n \"stylelint-high-performance-animation\": \"^2.0.0\",\n \"stylelint-media-use-custom-media\": \"^4.1.0\",\n \"stylelint-no-browser-hacks\": \"^2.0.0\",\n \"stylelint-no-indistinguishable-colors\": \"^2.3.1\",\n \"stylelint-no-restricted-syntax\": \"^2.2.1\",\n \"stylelint-no-unresolved-module\": \"^2.5.2\",\n \"stylelint-no-unsupported-browser-features\": \"^8.1.1\",\n \"stylelint-order\": \"^8.1.1\",\n \"stylelint-plugin-defensive-css\": \"^2.8.0\",\n \"stylelint-plugin-logical-css\": \"^2.0.2\",\n \"stylelint-plugin-use-baseline\": \"^1.4.1\",\n \"stylelint-prettier\": \"^5.0.3\",\n \"stylelint-react-native\": \"^2.7.0\",\n \"stylelint-scales\": \"^5.0.0\",\n \"stylelint-selector-bem-pattern\": \"^4.0.1\",\n \"stylelint-use-nesting\": \"^6.0.2\",\n \"stylelint-value-no-unknown-custom-properties\": \"^6.1.1\",\n \"toml-eslint-parser\": \"^1.0.3\",\n \"ts-unused-exports\": \"^11.0.1\",\n \"typedoc\": \"^0.28.18\",\n \"typescript\": \"^6.0.2\",\n \"typescript-eslint\": \"^8.57.2\",\n \"typesync\": \"^0.14.3\",\n \"vfile\": \"^6.0.3\",\n \"vite\": \"^8.0.2\",\n \"vite-tsconfig-paths\": \"^6.1.1\",\n \"vitest\": \"^4.1.1\",\n \"yamllint-js\": \"^0.2.4\"\n },\n \"peerDependencies\": {\n \"eslint\": \"^9.0.0 || ^10.1.0\"\n },\n \"packageManager\": \"npm@11.12.0\",\n \"engines\": {\n \"node\": \">=22.0.0\"\n },\n \"devEngines\": {\n \"runtime\": {\n \"name\": \"node\",\n \"version\": \">=22.0.0\",\n \"onFail\": \"error\"\n },\n \"packageManager\": {\n \"name\": \"npm\",\n \"version\": \">=11.0.0\",\n \"onFail\": \"error\"\n }\n },\n \"publishConfig\": {\n \"provenance\": true,\n \"registry\": \"https://registry.npmjs.org/\"\n },\n \"readme\": \"README.md\"\n}\n", "/**\n * @packageDocumentation\n * Shared filename target helpers for action metadata and workflow templates.\n */\nimport { basename, extname } from \"node:path\";\n\n/** Action metadata file globs. */\nexport const ACTION_METADATA_FILE_GLOBS: readonly string[] = [\n \"**/action.{yml,yaml}\",\n];\n\n/** Workflow template metadata (`.properties.json`) file globs. */\nexport const WORKFLOW_TEMPLATE_PROPERTIES_FILE_GLOBS: readonly string[] = [\n \"**/workflow-templates/*.properties.json\",\n];\n\n/** Workflow template YAML file globs. */\nexport const WORKFLOW_TEMPLATE_YAML_FILE_GLOBS: readonly string[] = [\n \"**/workflow-templates/*.{yml,yaml}\",\n];\n\n/** Combined workflow template globs used by dedicated template presets. */\nexport const WORKFLOW_TEMPLATE_FILE_GLOBS: readonly string[] = [\n ...WORKFLOW_TEMPLATE_YAML_FILE_GLOBS,\n ...WORKFLOW_TEMPLATE_PROPERTIES_FILE_GLOBS,\n];\n\n/** Normalize file paths for stable cross-platform path checks. */\nconst normalizePathForMatching = (filePath: string): string =>\n filePath.replaceAll(\"\\\\\", \"/\").toLowerCase();\n\n/** Determine whether a filename is an action metadata file. */\nexport const isActionMetadataFile = (filePath: string): boolean => {\n const normalizedFilePath = normalizePathForMatching(filePath);\n\n return (\n normalizedFilePath.endsWith(\"/action.yml\") ||\n normalizedFilePath.endsWith(\"/action.yaml\")\n );\n};\n\n/** Determine whether a filename is a workflow template metadata file. */\nexport const isWorkflowTemplatePropertiesFile = (filePath: string): boolean =>\n normalizePathForMatching(filePath).includes(\"/workflow-templates/\") &&\n normalizePathForMatching(filePath).endsWith(\".properties.json\");\n\n/** Determine whether a filename is a workflow template YAML file. */\nexport const isWorkflowTemplateYamlFile = (filePath: string): boolean => {\n const normalizedFilePath = normalizePathForMatching(filePath);\n\n return (\n normalizedFilePath.includes(\"/workflow-templates/\") &&\n (normalizedFilePath.endsWith(\".yml\") ||\n normalizedFilePath.endsWith(\".yaml\"))\n );\n};\n\n/** Determine whether a filename belongs to any workflow template surface. */\nexport const isWorkflowTemplateFile = (filePath: string): boolean =>\n isWorkflowTemplatePropertiesFile(filePath) ||\n isWorkflowTemplateYamlFile(filePath);\n\n/** Determine whether the path uses `.yaml` (rather than `.yml`). */\nexport const usesYamlExtension = (filePath: string): boolean =>\n extname(filePath).toLowerCase() === \".yaml\";\n\n/** Return the template basename without extension suffixes. */\nexport const getTemplateStem = (filePath: string): string => {\n const fileName = basename(filePath);\n\n if (fileName.endsWith(\".properties.json\")) {\n return fileName.slice(0, -\".properties.json\".length);\n }\n\n if (fileName.endsWith(\".yaml\")) {\n return fileName.slice(0, -\".yaml\".length);\n }\n\n if (fileName.endsWith(\".yml\")) {\n return fileName.slice(0, -\".yml\".length);\n }\n\n return fileName;\n};\n", "/**\n * @packageDocumentation\n * Shared YAML AST helpers for GitHub Actions workflow rules.\n */\n/* eslint-disable @typescript-eslint/prefer-readonly-parameter-types -- YAML AST nodes come from parser-owned mutable types shared across helper boundaries. */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\n/** Default workflow globs used by the exported flat configs. */\nexport const WORKFLOW_FILE_GLOBS: readonly string[] = [\n \".github/workflows/*.{yml,yaml}\",\n];\n\n/** Workflow job mapping paired with its stable identifier key. */\nexport type WorkflowJobEntry = {\n readonly id: string;\n readonly idNode: WorkflowYamlValueNode;\n readonly mapping: AST.YAMLMapping;\n readonly pair: AST.YAMLPair;\n};\n\n/** YAML value node type used by workflow helper APIs. */\ntype WorkflowYamlValueNode = AST.YAMLContent | AST.YAMLWithMeta;\n\n/** Narrow a YAML node to `YAMLWithMeta`. */\nexport const isYamlWithMeta = (\n node: AST.YAMLContent | AST.YAMLNode | AST.YAMLWithMeta | null | undefined\n): node is AST.YAMLWithMeta => node?.type === \"YAMLWithMeta\";\n\n/** Unwrap `YAMLWithMeta` wrappers until the underlying YAML value is reached. */\nexport const unwrapYamlValue = (\n node: null | undefined | WorkflowYamlValueNode\n): AST.YAMLContent | null => {\n if (node === null || node === undefined) {\n return null;\n }\n\n if (isYamlWithMeta(node)) {\n return unwrapYamlValue(node.value);\n }\n\n return node;\n};\n\n/** Narrow a YAML node to a mapping. */\nexport const isYamlMapping = (\n node: null | undefined | WorkflowYamlValueNode\n): node is AST.YAMLMapping => unwrapYamlValue(node)?.type === \"YAMLMapping\";\n\n/** Narrow a YAML node to a sequence. */\nexport const isYamlSequence = (\n node: null | undefined | WorkflowYamlValueNode\n): node is AST.YAMLSequence => unwrapYamlValue(node)?.type === \"YAMLSequence\";\n\n/** Narrow a YAML node to a scalar. */\nexport const isYamlScalar = (\n node: null | undefined | WorkflowYamlValueNode\n): node is AST.YAMLScalar => unwrapYamlValue(node)?.type === \"YAMLScalar\";\n\n/** Resolve the first document's root mapping when linting a workflow file. */\nexport const getWorkflowRoot = (\n context: Rule.RuleContext\n): AST.YAMLMapping | null => {\n const program = context.sourceCode.ast as unknown as AST.YAMLProgram;\n const [document] = program.body;\n const rootNode = unwrapYamlValue(document?.content ?? null);\n\n return rootNode?.type === \"YAMLMapping\" ? rootNode : null;\n};\n\n/** Read a scalar node as a string when possible. */\nexport const getScalarStringValue = (\n node: null | undefined | WorkflowYamlValueNode\n): null | string => {\n const unwrappedNode = unwrapYamlValue(node);\n\n if (unwrappedNode?.type !== \"YAMLScalar\") {\n return null;\n }\n\n if (typeof unwrappedNode.value === \"string\") {\n return unwrappedNode.value;\n }\n\n return \"strValue\" in unwrappedNode &&\n typeof unwrappedNode.strValue === \"string\"\n ? unwrappedNode.strValue\n : null;\n};\n\n/** Read a scalar node as a number when possible. */\nexport const getScalarNumberValue = (\n node: null | undefined | WorkflowYamlValueNode\n): null | number => {\n const unwrappedNode = unwrapYamlValue(node);\n\n if (unwrappedNode?.type !== \"YAMLScalar\") {\n return null;\n }\n\n return typeof unwrappedNode.value === \"number\" ? unwrappedNode.value : null;\n};\n\n/** Determine whether a scalar is a GitHub expression string like `${{ ... }}`. */\nexport const isGithubExpressionScalar = (\n node: null | undefined | WorkflowYamlValueNode\n): boolean => {\n const scalarValue = getScalarStringValue(node);\n\n return (\n scalarValue !== null &&\n scalarValue.trimStart().startsWith(\"${{\") &&\n scalarValue.trimEnd().endsWith(\"}}\")\n );\n};\n\n/** Find a mapping pair by its exact scalar key. */\nexport const getMappingPair = (\n mapping: AST.YAMLMapping,\n key: string\n): AST.YAMLPair | null => {\n for (const pair of mapping.pairs) {\n if (getScalarStringValue(pair.key) === key) {\n return pair;\n }\n }\n\n return null;\n};\n\n/** Resolve a mapping child by key, ensuring the value is a mapping. */\nexport const getMappingValueAsMapping = (\n mapping: AST.YAMLMapping,\n key: string\n): AST.YAMLMapping | null => {\n const pair = getMappingPair(mapping, key);\n const valueNode = unwrapYamlValue(pair?.value ?? null);\n\n return valueNode?.type === \"YAMLMapping\" ? valueNode : null;\n};\n\n/** Resolve a mapping child by key, ensuring the value is a sequence. */\nexport const getMappingValueAsSequence = (\n mapping: AST.YAMLMapping,\n key: string\n): AST.YAMLSequence | null => {\n const pair = getMappingPair(mapping, key);\n const valueNode = unwrapYamlValue(pair?.value ?? null);\n\n return valueNode?.type === \"YAMLSequence\" ? valueNode : null;\n};\n\n/** Enumerate workflow jobs under `jobs`. */\nexport const getWorkflowJobs = (\n root: AST.YAMLMapping\n): readonly WorkflowJobEntry[] => {\n const jobsMapping = getMappingValueAsMapping(root, \"jobs\");\n\n if (jobsMapping === null) {\n return [];\n }\n\n const jobs: WorkflowJobEntry[] = [];\n\n for (const pair of jobsMapping.pairs) {\n const jobId = getScalarStringValue(pair.key);\n const jobMapping = unwrapYamlValue(pair.value);\n\n if (jobId === null || jobMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n if (pair.key === null || pair.key === undefined) {\n continue;\n }\n\n jobs.push({\n id: jobId,\n idNode: pair.key,\n mapping: jobMapping,\n pair,\n });\n }\n\n return jobs;\n};\n\n/** Collect the workflow event names declared under `on`. */\nexport const getWorkflowEventNames = (\n root: AST.YAMLMapping\n): ReadonlySet<string> => {\n const onPair = getMappingPair(root, \"on\");\n const onValue = unwrapYamlValue(onPair?.value ?? null);\n const eventNames = new Set<string>();\n\n if (onValue === null) {\n return eventNames;\n }\n\n if (onValue.type === \"YAMLScalar\") {\n const eventName = getScalarStringValue(onValue);\n\n if (eventName !== null) {\n eventNames.add(eventName);\n }\n\n return eventNames;\n }\n\n if (onValue.type === \"YAMLSequence\") {\n for (const entry of onValue.entries) {\n const eventName = getScalarStringValue(entry);\n\n if (eventName !== null) {\n eventNames.add(eventName);\n }\n }\n\n return eventNames;\n }\n\n if (onValue.type === \"YAMLMapping\") {\n for (const pair of onValue.pairs) {\n const eventName = getScalarStringValue(pair.key);\n\n if (eventName !== null) {\n eventNames.add(eventName);\n }\n }\n }\n\n return eventNames;\n};\n\n/* eslint-enable @typescript-eslint/prefer-readonly-parameter-types -- Re-enable readonly-parameter checks after YAML AST helper declarations. */\n", "/**\n * @packageDocumentation\n * Canonical preset names and docs references used by eslint-plugin-github-actions-2.\n */\nimport {\n ACTION_METADATA_FILE_GLOBS,\n WORKFLOW_TEMPLATE_FILE_GLOBS,\n WORKFLOW_TEMPLATE_PROPERTIES_FILE_GLOBS,\n} from \"./lint-targets.js\";\nimport { WORKFLOW_FILE_GLOBS } from \"./workflow-yaml.js\";\n\n/** Ordered preset names exposed through `plugin.configs`. */\nexport const githubActionsConfigNames = [\n \"actionMetadata\",\n \"workflowTemplateProperties\",\n \"workflowTemplates\",\n \"recommended\",\n \"security\",\n \"strict\",\n \"all\",\n] as const;\n\n/** Supported flat-config preset names exported by the plugin. */\nexport type GithubActionsConfigName = (typeof githubActionsConfigNames)[number];\n\n/** String references used in rule docs metadata and generated docs tables. */\nexport const githubActionsConfigReferenceToName: Readonly<\n Record<string, GithubActionsConfigName>\n> = {\n \"github-actions.configs.actionMetadata\": \"actionMetadata\",\n \"github-actions.configs.all\": \"all\",\n \"github-actions.configs.recommended\": \"recommended\",\n \"github-actions.configs.security\": \"security\",\n \"github-actions.configs.strict\": \"strict\",\n \"github-actions.configs.workflowTemplateProperties\":\n \"workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\": \"workflowTemplates\",\n} as const satisfies Record<string, GithubActionsConfigName>;\n\n/** Valid config reference strings accepted in rule metadata. */\nexport type GithubActionsConfigReference =\n keyof typeof githubActionsConfigReferenceToName;\n\n/** Display metadata for each preset used in README and docs surfaces. */\nexport const githubActionsConfigMetadataByName: Readonly<\n Record<\n GithubActionsConfigName,\n {\n description: string;\n files: readonly string[];\n icon: string;\n presetName: string;\n }\n >\n> = {\n actionMetadata: {\n description:\n \"Linting defaults for GitHub Action metadata files (`action.yml` / `action.yaml`).\",\n files: ACTION_METADATA_FILE_GLOBS,\n icon: \"\uD83E\uDDE9\",\n presetName: \"github-actions:action-metadata\",\n },\n all: {\n description:\n \"Enables every available GitHub Actions workflow rule published by this plugin.\",\n files: [\n ...WORKFLOW_FILE_GLOBS,\n ...ACTION_METADATA_FILE_GLOBS,\n ...WORKFLOW_TEMPLATE_FILE_GLOBS,\n ],\n icon: \"\uD83D\uDFE3\",\n presetName: \"github-actions:all\",\n },\n recommended: {\n description:\n \"Balanced defaults for most repositories authoring GitHub Actions workflows.\",\n files: WORKFLOW_FILE_GLOBS,\n icon: \"\uD83D\uDFE1\",\n presetName: \"github-actions:recommended\",\n },\n security: {\n description:\n \"Security-focused workflow hardening checks for action usage and token scope.\",\n files: WORKFLOW_FILE_GLOBS,\n icon: \"\uD83D\uDEE1\uFE0F\",\n presetName: \"github-actions:security\",\n },\n strict: {\n description:\n \"Opinionated operational guardrails for mature workflow estates.\",\n files: WORKFLOW_FILE_GLOBS,\n icon: \"\uD83D\uDD34\",\n presetName: \"github-actions:strict\",\n },\n workflowTemplateProperties: {\n description:\n \"Linting defaults for workflow-template metadata files (`*.properties.json`).\",\n files: WORKFLOW_TEMPLATE_PROPERTIES_FILE_GLOBS,\n icon: \"\uD83D\uDDC2\uFE0F\",\n presetName: \"github-actions:workflow-template-properties\",\n },\n workflowTemplates: {\n description:\n \"Workflow template package linting for both template YAML and metadata files.\",\n files: WORKFLOW_TEMPLATE_FILE_GLOBS,\n icon: \"\uD83E\uDDF1\",\n presetName: \"github-actions:workflow-templates\",\n },\n} as const;\n", "/**\n * @packageDocumentation\n * Canonical brand/acronym dictionary synced from case-police.\n * Source: https://github.com/antfu/case-police\n */\n\n/**\n * Canonical casing entries merged from case-police dictionaries.\n */\nexport const casePoliceDictionary: Readonly<Record<string, string>> = {\n \"1password\": \"1Password\",\n \"3dtiles\": \"3DTiles\",\n abi: \"ABI\",\n actionscript: \"ActionScript\",\n adblock: \"AdBlock\",\n aiaas: \"AIaaS\",\n airbnb: \"Airbnb\",\n ajax: \"AJAX\",\n alipay: \"Alipay\",\n alphago: \"AlphaGo\",\n amap: \"AMap\",\n amd: \"AMD\",\n angularjs: \"AngularJS\",\n antd: \"AntD\",\n \"ant design\": \"Ant Design\",\n antdesign: \"AntDesign\",\n \"ant design vue\": \"Ant Design Vue\",\n antdesignvue: \"AntDesignVue\",\n antv: \"AntV\",\n api: \"API\",\n apifox: \"Apifox\",\n \"apple pay\": \"Apple Pay\",\n applescript: \"AppleScript\",\n appletalk: \"AppleTalk\",\n \"app store\": \"App Store\",\n arangodb: \"ArangoDB\",\n arcgis: \"ArcGIS\",\n arcmap: \"ArcMap\",\n arcobjects: \"ArcObjects\",\n ast: \"AST\",\n baas: \"BaaS\",\n beego: \"Beego\",\n bitbucket: \"Bitbucket\",\n bittorrent: \"BitTorrent\",\n bluesky: \"Bluesky\",\n bom: \"BOM\",\n bsd: \"BSD\",\n busybox: \"BusyBox\",\n bytedance: \"ByteDance\",\n caas: \"CaaS\",\n cdn: \"CDN\",\n centos: \"CentOS\",\n cesiumjs: \"CesiumJS\",\n chatgpt: \"ChatGPT\",\n circleci: \"CircleCI\",\n citygml: \"CityGML\",\n cityjson: \"CityJSON\",\n cjs: \"CJS\",\n ckeditor: \"CKEditor\",\n clashx: \"ClashX\",\n cli: \"CLI\",\n clickhouse: \"ClickHouse\",\n cloudflare: \"Cloudflare\",\n cloudfront: \"CloudFront\",\n cmake: \"CMake\",\n cncf: \"CNCF\",\n cockroachdb: \"CockroachDB\",\n cocoapods: \"CocoaPods\",\n codepen: \"CodePen\",\n codesandbox: \"CodeSandbox\",\n coffeescript: \"CoffeeScript\",\n commonjs: \"CommonJS\",\n \"composition api\": \"Composition API\",\n compositionapi: \"CompositionAPI\",\n coredns: \"CoreDNS\",\n cors: \"CORS\",\n cpu: \"CPU\",\n crud: \"CRUD\",\n csrf: \"CSRF\",\n css: \"CSS\",\n \"css modules\": \"CSS Modules\",\n csv: \"CSV\",\n daas: \"DaaS\",\n dapr: \"Dapr\",\n datadog: \"Datadog\",\n datagrip: \"DataGrip\",\n db2: \"DB2\",\n dbase: \"dBase\",\n ddos: \"DDoS\",\n definitelytyped: \"DefinitelyTyped\",\n denodeploy: \"DenoDeploy\",\n devops: \"DevOps\",\n devtools: \"DevTools\",\n \"digital ocean\": \"DigitalOcean\",\n digitalocean: \"DigitalOcean\",\n dingtalk: \"DingTalk\",\n directx: \"DirectX\",\n django: \"Django\",\n dns: \"DNS\",\n dom: \"DOM\",\n dos: \"DOS\",\n duckduckgo: \"DuckDuckGo\",\n dynamodb: \"DynamoDB\",\n echarts: \"ECharts\",\n ecmascript: \"ECMAScript\",\n edgedb: \"EdgeDB\",\n eggjs: \"Egg.js\",\n elasticsearch: \"Elasticsearch\",\n \"element plus\": \"Element Plus\",\n elementui: \"ElementUI\",\n es6: \"ES6\",\n esbuild: \"esbuild\",\n esim: \"eSIM\",\n eslint: \"ESLint\",\n esm: \"ESM\",\n esxi: \"ESXi\",\n etcd: \"etcd\",\n faas: \"FaaS\",\n facetime: \"FaceTime\",\n fastapi: \"FastAPI\",\n fbi: \"FBI\",\n ffmpeg: \"FFmpeg\",\n filezilla: \"FileZilla\",\n firefox: \"Firefox\",\n freecodecamp: \"freeCodeCamp\",\n freemarker: \"FreeMarker\",\n ftp: \"FTP\",\n ftps: \"FTPS\",\n gcc: \"GCC\",\n gcp: \"GCP\",\n gdnative: \"GDNative\",\n gdscript: \"GDScript\",\n geforce: \"GeForce\",\n geojson: \"GeoJSON\",\n geopackage: \"GeoPackage\",\n geopandas: \"GeoPandas\",\n geoserver: \"GeoServer\",\n gitbook: \"GitBook\",\n gitea: \"Gitea\",\n gitee: \"Gitee\",\n github: \"GitHub\",\n gitkraken: \"GitKraken\",\n gitlab: \"GitLab\",\n gitops: \"GitOps\",\n gitpod: \"Gitpod\",\n glsl: \"GLSL\",\n gltf: \"glTF\",\n gnome: \"GNOME\",\n gnu: \"GNU\",\n gnupg: \"GnuPG\",\n goland: \"GoLand\",\n \"google pay\": \"Google Pay\",\n gorm: \"GORM\",\n gpl: \"GPL\",\n gps: \"GPS\",\n gpu: \"GPU\",\n graphql: \"GraphQL\",\n \"graph rag\": \"Graph RAG\",\n graphrag: \"GraphRAG\",\n gre: \"GRE\",\n greensock: \"GreenSock\",\n grpc: \"gRPC\",\n gui: \"GUI\",\n hackernews: \"Hacker News\",\n hacpai: \"HacPai\",\n hbase: \"HBase\",\n hbuilderx: \"HBuilderX\",\n hdmi: \"HDMI\",\n hmr: \"HMR\",\n hp: \"HP\",\n html: \"HTML\",\n http: \"HTTP\",\n https: \"HTTPS\",\n iaas: \"IaaS\",\n iac: \"IaC\",\n ibm: \"IBM\",\n ibook: \"iBook\",\n icloud: \"iCloud\",\n idrac: \"iDRAC\",\n iife: \"IIFE\",\n ilo: \"iLO\",\n imessage: \"iMessage\",\n imovie: \"iMovie\",\n imtoken: \"imToken\",\n influxdb: \"InfluxDB\",\n intellij: \"IntelliJ\",\n \"intellij idea\": \"IntelliJ IDEA\",\n ioc: \"IoC\",\n ios: \"iOS\",\n iot: \"IoT\",\n ipados: \"iPadOS\",\n ipc: \"IPC\",\n ipfs: \"IPFS\",\n iphoto: \"iPhoto\",\n ipmi: \"IPMI\",\n ipsec: \"IPsec\",\n iscsi: \"iSCSI\",\n iterm: \"iTerm\",\n itunes: \"iTunes\",\n iwork: \"iWork\",\n javascript: \"JavaScript\",\n jdbc: \"JDBC\",\n jdk: \"JDK\",\n jetbrains: \"JetBrains\",\n jit: \"JIT\",\n jpeg: \"JPEG\",\n jpg: \"JPG\",\n jquery: \"jQuery\",\n jre: \"JRE\",\n jsdelivr: \"jsDelivr\",\n jsdoc: \"JSDoc\",\n jsf: \"JSF\",\n json: \"JSON\",\n jsonp: \"JSONP\",\n jsp: \"JSP\",\n jupyterlab: \"JupyterLab\",\n jwt: \"JWT\",\n katex: \"KaTeX\",\n kcp: \"KCP\",\n kde: \"KDE\",\n kfc: \"KFC\",\n kpi: \"KPI\",\n kubernetes: \"Kubernetes\",\n latex: \"LaTeX\",\n leetcode: \"LeetCode\",\n less: \"Less\",\n lfu: \"LFU\",\n libreoffice: \"LibreOffice\",\n lineageos: \"LineageOS\",\n \"line pay\": \"LINE Pay\",\n linkedin: \"LinkedIn\",\n llvm: \"LLVM\",\n lru: \"LRU\",\n lts: \"LTS\",\n macos: \"macOS\",\n mariadb: \"MariaDB\",\n markdown: \"Markdown\",\n markdownlint: \"MarkdownLint\",\n mathjax: \"MathJax\",\n mathml: \"MathML\",\n mathtype: \"MathType\",\n matlab: \"MATLAB\",\n mcdonald: \"McDonald\",\n mdn: \"MDN\",\n mdx: \"MDX\",\n mediawiki: \"MediaWiki\",\n memcached: \"Memcached\",\n messagepack: \"MessagePack\",\n metamask: \"MetaMask\",\n mkdocs: \"MkDocs\",\n mlaas: \"MLaaS\",\n mlops: \"MLOps\",\n mobx: \"MobX\",\n mongodb: \"MongoDB\",\n mongoose: \"Mongoose\",\n mpaas: \"mPaaS\",\n \"ms-dos\": \"MS-DOS\",\n mvc: \"MVC\",\n mvp: \"MVP\",\n mvvm: \"MVVM\",\n mybatis: \"MyBatis\",\n mysql: \"MySQL\",\n \"naive ui\": \"Naive UI\",\n naiveui: \"NaiveUI\",\n neo4j: \"Neo4j\",\n nestjs: \"NestJS\",\n netbeans: \"NetBeans\",\n netbios: \"NetBIOS\",\n nextjs: \"Next.js\",\n nft: \"NFT\",\n nixos: \"NixOS\",\n nocodb: \"NocoDB\",\n \"node.js\": \"Node.js\",\n nosql: \"NoSQL\",\n \"notepad ++\": \"Notepad++\",\n npm: \"npm\",\n numpy: \"NumPy\",\n nuxtjs: \"NuxtJS\",\n nvidia: \"NVIDIA\",\n oauth: \"OAuth\",\n obs: \"OBS\",\n ocaml: \"OCaml\",\n odbc: \"ODBC\",\n onedrive: \"OneDrive\",\n onenote: \"OneNote\",\n ont: \"ONT\",\n openai: \"OpenAI\",\n openapi: \"OpenAPI\",\n opencv: \"OpenCV\",\n openfaas: \"OpenFaaS\",\n openflow: \"OpenFlow\",\n opengauss: \"openGauss\",\n opengl: \"OpenGL\",\n \"opengl es\": \"OpenGL ES\",\n openjdk: \"OpenJDK\",\n openlayers: \"OpenLayers\",\n openpgp: \"OpenPGP\",\n opensea: \"OpenSea\",\n openssl: \"OpenSSL\",\n openstack: \"OpenStack\",\n openstreetmap: \"OpenStreetMap\",\n opensuse: \"openSUSE\",\n openvino: \"OpenVINO\",\n openwrt: \"OpenWrt\",\n opnsense: \"OPNsense\",\n orm: \"ORM\",\n oss: \"OSS\",\n paas: \"PaaS\",\n pagerduty: \"PagerDuty\",\n pagp: \"PAgP\",\n paypal: \"PayPal\",\n pdf: \"PDF\",\n pdo: \"PDO\",\n photoshop: \"Photoshop\",\n php: \"PHP\",\n phpstorm: \"PhpStorm\",\n pihole: \"Pi-hole\",\n planetscale: \"PlanetScale\",\n posix: \"POSIX\",\n postcss: \"PostCSS\",\n postgis: \"PostGIS\",\n postgresql: \"PostgreSQL\",\n potplayer: \"PotPlayer\",\n powerpoint: \"PowerPoint\",\n powershell: \"PowerShell\",\n premid: \"PreMiD\",\n primevue: \"PrimeVue\",\n producthunt: \"Product Hunt\",\n protobuf: \"Protobuf\",\n pwa: \"PWA\",\n pycharm: \"PyCharm\",\n pytorch: \"PyTorch\",\n qemu: \"QEMU\",\n qgis: \"QGIS\",\n qtscript: \"QtScript\",\n quic: \"QUIC\",\n raii: \"RAII\",\n \"react native\": \"React Native\",\n redhat: \"RedHat\",\n redisearch: \"RediSearch\",\n redisjson: \"RedisJSON\",\n rescript: \"ReScript\",\n restful: \"RESTful\",\n rethinkdb: \"RethinkDB\",\n rfc: \"RFC\",\n rom: \"ROM\",\n rpc: \"RPC\",\n rss: \"RSS\",\n rss3: \"RSS3\",\n rsshub: \"RSSHub\",\n rust: \"Rust\",\n rxdb: \"RxDB\",\n rxjs: \"RxJS\",\n saas: \"SaaS\",\n \"samsung pay\": \"Samsung Pay\",\n sass: \"Sass\",\n scss: \"SCSS\",\n sdk: \"SDK\",\n segmentfault: \"SegmentFault\",\n seo: \"SEO\",\n sip: \"SIP\",\n smtp: \"SMTP\",\n \"socket.io\": \"Socket.IO\",\n solarwinds: \"SolarWinds\",\n spatiallite: \"SpatialLite\",\n \"spir-v\": \"SPIR-V\",\n springboot: \"SpringBoot\",\n springcloud: \"SpringCloud\",\n springmvc: \"SpringMVC\",\n sql: \"SQL\",\n sqlite: \"SQLite\",\n sqlserver: \"SQLServer\",\n sre: \"SRE\",\n ssg: \"SSG\",\n ssh: \"SSH\",\n sso: \"SSO\",\n ssr: \"SSR\",\n stackblitz: \"StackBlitz\",\n stackit: \"STACKIT\",\n stackoverflow: \"Stack Overflow\",\n storybook: \"Storybook\",\n stp: \"STP\",\n stylus: \"Stylus\",\n \"sublime text\": \"Sublime Text\",\n surrealdb: \"SurrealDB\",\n sveltekit: \"SvelteKit\",\n svg: \"SVG\",\n svn: \"SVN\",\n \"tailwind css\": \"Tailwind CSS\",\n tailwindcss: \"TailwindCSS\",\n tcp: \"TCP\",\n teamviewer: \"TeamViewer\",\n tensorflow: \"TensorFlow\",\n testflight: \"TestFlight\",\n tex: \"TeX\",\n threejs: \"ThreeJS\",\n tianocore: \"TianoCore\",\n tidb: \"TiDB\",\n tiflash: \"TiFlash\",\n tiktok: \"TikTok\",\n tikv: \"TiKV\",\n tls: \"TLS\",\n toml: \"TOML\",\n \"travis ci\": \"Travis CI\",\n trpc: \"tRPC\",\n tsc: \"TSC\",\n tsconfig: \"TSConfig\",\n tsdoc: \"TSDoc\",\n tsdx: \"TSdx\",\n turbopack: \"Turbopack\",\n turborepo: \"Turborepo\",\n typeorm: \"TypeORM\",\n typescript: \"TypeScript\",\n udp: \"UDP\",\n umd: \"UMD\",\n uniapp: \"uniapp\",\n unifi: \"UniFi\",\n unix: \"UNIX\",\n unjs: \"UnJS\",\n unocss: \"UnoCSS\",\n upnp: \"UPnP\",\n uri: \"URI\",\n url: \"URL\",\n usb: \"USB\",\n v2ex: \"V2EX\",\n vercel: \"Vercel\",\n videolan: \"VideoLAN\",\n vim: \"Vim\",\n virtualbox: \"VirtualBox\",\n \"visual studio\": \"Visual Studio\",\n \"visual studio code\": \"Visual Studio Code\",\n vitepress: \"VitePress\",\n vividcortex: \"VividCortex\",\n vlan: \"VLAN\",\n vlc: \"VLC\",\n vmware: \"VMware\",\n vnc: \"VNC\",\n voip: \"VoIP\",\n vpn: \"VPN\",\n vps: \"VPS\",\n \"vs code\": \"VS Code\",\n vscode: \"VS Code\",\n \"vs codium\": \"VSCodium\",\n vscodium: \"VSCodium\",\n \"vue cli\": \"Vue CLI\",\n vuefes: \"Vue Fes\",\n vuepress: \"VuePress\",\n vueuse: \"VueUse\",\n vulkan: \"Vulkan\",\n w3c: \"W3C\",\n wasm: \"Wasm\",\n watchos: \"watchOS\",\n webar: \"WebAR\",\n \"web assembly\": \"WebAssembly\",\n webassembly: \"WebAssembly\",\n webgl: \"WebGL\",\n webgpu: \"WebGPU\",\n webkit: \"WebKit\",\n webpack: \"webpack\",\n webrtc: \"WebRTC\",\n websocket: \"WebSocket\",\n webstorm: \"WebStorm\",\n webvr: \"WebVR\",\n webxr: \"WebXR\",\n wechat: \"WeChat\",\n \"wechat pay\": \"WeChat Pay\",\n wgsl: \"WGSL\",\n whatsapp: \"WhatsApp\",\n wifi: \"Wi-Fi\",\n \"windi css\": \"Windi CSS\",\n windicss: \"WindiCSS\",\n wireguard: \"WireGuard\",\n wlan: \"WLAN\",\n wordpress: \"WordPress\",\n wsa: \"WSA\",\n wsl: \"WSL\",\n xaas: \"XaaS\",\n xhtml: \"XHTML\",\n xmind: \"XMind\",\n xml: \"XML\",\n xss: \"XSS\",\n xstate: \"XState\",\n yaml: \"YAML\",\n yapi: \"YApi\",\n youtube: \"YouTube\",\n};\n", "/**\n * @packageDocumentation\n * Shared casing helpers for naming-oriented GitHub Actions rules.\n */\n\nimport { casePoliceDictionary } from \"./case-police-dictionary.js\";\n\n/** Supported naming conventions used by workflow naming rules. */\nexport const githubActionsCasingKinds = [\n \"camelCase\",\n \"kebab-case\",\n \"PascalCase\",\n \"snake_case\",\n \"Title Case\",\n \"Train-Case\",\n \"SCREAMING_SNAKE_CASE\",\n] as const;\n\n/** String literal union of supported naming conventions. */\nexport type GithubActionsCasingKind = (typeof githubActionsCasingKinds)[number];\n\n/** Casing variants that exclude title-cased words with spaces. */\nexport const githubActionsNonTitleCasingKinds = [\n \"camelCase\",\n \"kebab-case\",\n \"PascalCase\",\n \"snake_case\",\n \"Train-Case\",\n \"SCREAMING_SNAKE_CASE\",\n] as const;\n\n/** String literal union of supported non-title casing conventions. */\nexport type GithubActionsNonTitleCasingKind =\n (typeof githubActionsNonTitleCasingKinds)[number];\n\n/** Determine whether a character is an ASCII letter or digit. */\nconst isAlphaNumericCharacter = (character: string): boolean => {\n const codePoint = character.codePointAt(0) ?? -1;\n\n return (\n (codePoint >= 48 && codePoint <= 57) ||\n (codePoint >= 65 && codePoint <= 90) ||\n (codePoint >= 97 && codePoint <= 122)\n );\n};\n\n/** Determine whether a character is an ASCII uppercase letter. */\nconst isUppercaseCharacter = (character: string): boolean => {\n const codePoint = character.codePointAt(0) ?? -1;\n\n return codePoint >= 65 && codePoint <= 90;\n};\n\n/** Determine whether a character is an ASCII lowercase letter. */\nconst isLowercaseCharacter = (character: string): boolean => {\n const codePoint = character.codePointAt(0) ?? -1;\n\n return codePoint >= 97 && codePoint <= 122;\n};\n\n/** Normalize a free-form identifier or label into lowercase word tokens. */\nconst splitIntoWords = (value: string): readonly string[] => {\n const words: string[] = [];\n let currentWord = \"\";\n\n for (let index = 0; index < value.length; index += 1) {\n const character = value[index];\n\n if (character === undefined) {\n continue;\n }\n\n if (!isAlphaNumericCharacter(character)) {\n if (currentWord.length > 0) {\n words.push(currentWord.toLowerCase());\n currentWord = \"\";\n }\n\n continue;\n }\n\n const previousCharacter = index > 0 ? value[index - 1] : undefined;\n const nextCharacter =\n index + 1 < value.length ? value[index + 1] : undefined;\n const startsNewWord =\n currentWord.length > 0 &&\n previousCharacter !== undefined &&\n ((isLowercaseCharacter(previousCharacter) &&\n isUppercaseCharacter(character)) ||\n (isUppercaseCharacter(previousCharacter) &&\n isUppercaseCharacter(character) &&\n nextCharacter !== undefined &&\n isLowercaseCharacter(nextCharacter)));\n\n if (startsNewWord) {\n words.push(currentWord.toLowerCase());\n currentWord = character;\n\n continue;\n }\n\n currentWord += character;\n }\n\n if (currentWord.length > 0) {\n words.push(currentWord.toLowerCase());\n }\n\n return words;\n};\n\n/** Uppercase the first character of a normalized word token. */\nconst capitalizeWord = (word: string): string =>\n word.length === 0\n ? word\n : `${word[0]?.toUpperCase() ?? \"\"}${word.slice(1)}`;\n\n/** Case-police dictionary match shape keyed by collapsed word tokens. */\ntype CasePoliceDictionaryMatch = {\n readonly canonical: string;\n readonly tokenCount: number;\n};\n\n/** Index case-police entries by collapsed key and track longest token span. */\nconst buildCasePoliceDictionaryIndex = (): {\n readonly matchesByCollapsedKey: ReadonlyMap<\n string,\n readonly CasePoliceDictionaryMatch[]\n >;\n readonly maxTokenSpan: number;\n} => {\n const matchesByCollapsedKey = new Map<\n string,\n CasePoliceDictionaryMatch[]\n >();\n let maxTokenSpan = 1;\n\n for (const [dictionaryKey, canonical] of Object.entries(\n casePoliceDictionary\n )) {\n const keyWords = splitIntoWords(dictionaryKey);\n\n if (keyWords.length === 0) {\n continue;\n }\n\n const tokenCount = keyWords.length;\n const collapsedKey = keyWords.join(\"\");\n const existingMatches = matchesByCollapsedKey.get(collapsedKey) ?? [];\n const isDuplicateMatch = existingMatches.some(\n (existingMatch) =>\n existingMatch.canonical === canonical &&\n existingMatch.tokenCount === tokenCount\n );\n\n if (!isDuplicateMatch) {\n existingMatches.push({\n canonical,\n tokenCount,\n });\n matchesByCollapsedKey.set(collapsedKey, existingMatches);\n }\n\n if (tokenCount > maxTokenSpan) {\n maxTokenSpan = tokenCount;\n }\n }\n\n return {\n matchesByCollapsedKey,\n maxTokenSpan,\n };\n};\n\n/** Precomputed case-police dictionary index used by Title/Train conversions. */\nconst casePoliceDictionaryIndex = buildCasePoliceDictionaryIndex();\n\n/**\n * Resolve normalized words into title-style segments using the case-police\n * dictionary. Falls back to naive capitalization for unknown tokens.\n */\nconst resolveCasePoliceTitleSegments = (\n words: readonly string[]\n): readonly string[] => {\n const segments: string[] = [];\n\n for (let index = 0; index < words.length; ) {\n const remainingWordCount = words.length - index;\n const maxSpan = Math.min(\n casePoliceDictionaryIndex.maxTokenSpan,\n remainingWordCount\n );\n\n let matched = false;\n\n for (let span = maxSpan; span >= 1; span -= 1) {\n const collapsedCandidate = words\n .slice(index, index + span)\n .join(\"\");\n const candidateMatches =\n casePoliceDictionaryIndex.matchesByCollapsedKey.get(\n collapsedCandidate\n );\n\n if (candidateMatches === undefined) {\n continue;\n }\n\n const exactTokenCountMatch = candidateMatches.find(\n (candidateMatch) => candidateMatch.tokenCount === span\n );\n const selectedMatch = exactTokenCountMatch ?? candidateMatches[0];\n\n if (selectedMatch === undefined) {\n continue;\n }\n\n segments.push(selectedMatch.canonical);\n index += span;\n matched = true;\n\n break;\n }\n\n if (matched) {\n continue;\n }\n\n const currentWord = words[index];\n\n if (currentWord === undefined) {\n index += 1;\n\n continue;\n }\n\n segments.push(capitalizeWord(currentWord));\n index += 1;\n }\n\n return segments;\n};\n\n/** Convert a value into the exact requested casing convention. */\nexport const convertToGithubActionsCasing = (\n value: string,\n casingKind: GithubActionsCasingKind\n): string => {\n const words = splitIntoWords(value);\n const titleSegments = resolveCasePoliceTitleSegments(words);\n\n if (words.length === 0) {\n return value;\n }\n\n switch (casingKind) {\n case \"camelCase\": {\n const [firstWord = \"\", ...remainingWords] = words;\n\n return `${firstWord}${remainingWords.map((word) => capitalizeWord(word)).join(\"\")}`;\n }\n\n case \"kebab-case\": {\n return words.join(\"-\");\n }\n\n case \"PascalCase\": {\n return words.map((word) => capitalizeWord(word)).join(\"\");\n }\n\n case \"SCREAMING_SNAKE_CASE\": {\n return words.map((word) => word.toUpperCase()).join(\"_\");\n }\n\n case \"snake_case\": {\n return words.join(\"_\");\n }\n\n case \"Title Case\": {\n return titleSegments.join(\" \");\n }\n\n case \"Train-Case\": {\n return titleSegments\n .flatMap((segment) => segment.split(/\\s+/u))\n .filter((segment) => segment.length > 0)\n .join(\"-\");\n }\n\n default: {\n return value;\n }\n }\n};\n\n/** Determine whether a value already satisfies a requested casing convention. */\nexport const matchesGithubActionsCasing = (\n value: string,\n casingKind: GithubActionsCasingKind\n): boolean => convertToGithubActionsCasing(value, casingKind) === value;\n", "/**\n * @packageDocumentation\n * Enforce a consistent naming convention for workflow names.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n convertToGithubActionsCasing,\n type GithubActionsCasingKind,\n githubActionsCasingKinds,\n matchesGithubActionsCasing,\n} from \"../_internal/casing.js\";\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Object-style configuration for `action-name-casing`. */\ntype ActionNameCasingObjectOption = Partial<\n Record<GithubActionsCasingKind, boolean>\n> & {\n readonly ignores?: readonly string[];\n};\n\n/** Rule options for `action-name-casing`. */\ntype ActionNameCasingOptions = [\n (ActionNameCasingObjectOption | GithubActionsCasingKind)?,\n];\n\n/** Default casing enforced for workflow names. */\nconst DEFAULT_ACTION_NAME_CASING: GithubActionsCasingKind = \"Title Case\";\n\n/**\n * Normalize action-name-casing options into allowed casings and ignore\n * patterns.\n */\nconst normalizeActionNameCasingOptions = (\n option: Readonly<\n ActionNameCasingObjectOption | GithubActionsCasingKind | undefined\n >\n): {\n allowedCasings: readonly GithubActionsCasingKind[];\n ignoredNames: readonly string[];\n} => {\n if (option === undefined || typeof option === \"string\") {\n return {\n allowedCasings: [option ?? DEFAULT_ACTION_NAME_CASING],\n ignoredNames: [],\n };\n }\n\n const allowedCasings = githubActionsCasingKinds.filter(\n (casingKind) => option[casingKind] === true\n );\n\n return {\n allowedCasings:\n allowedCasings.length > 0\n ? allowedCasings\n : [DEFAULT_ACTION_NAME_CASING],\n ignoredNames: [...(option.ignores ?? [])],\n };\n};\n\n/** Rule implementation for enforcing workflow-name casing. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const [option] = context.options as ActionNameCasingOptions;\n const { allowedCasings, ignoredNames } =\n normalizeActionNameCasingOptions(option ?? undefined);\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const namePair = getMappingPair(root, \"name\");\n const nameNode = unwrapYamlValue(namePair?.value ?? null);\n const nameValue = getScalarStringValue(nameNode);\n\n if (\n namePair === null ||\n nameNode?.type !== \"YAMLScalar\" ||\n nameValue === null ||\n nameValue.trim().length === 0 ||\n ignoredNames.includes(nameValue)\n ) {\n return;\n }\n\n const matchesAllowedCasing = allowedCasings.some((casingKind) =>\n matchesGithubActionsCasing(nameValue, casingKind)\n );\n\n if (!matchesAllowedCasing) {\n const [firstAllowedCasing] = allowedCasings;\n\n context.report({\n data: {\n caseTypes: allowedCasings.join(\", \"),\n name: nameValue,\n },\n fix:\n firstAllowedCasing !== undefined &&\n allowedCasings.length === 1\n ? (fixer) =>\n fixer.replaceTextRange(\n nameNode.range,\n convertToGithubActionsCasing(\n nameValue,\n firstAllowedCasing\n )\n )\n : undefined,\n messageId: \"nameDoesNotMatchCasing\",\n node: nameNode as AST.YAMLNode as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n defaultOptions: [DEFAULT_ACTION_NAME_CASING],\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"enforce a consistent casing convention for workflow `name` values.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R009\",\n ruleNumber: 9,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/action-name-casing\",\n },\n fixable: \"code\",\n messages: {\n nameDoesNotMatchCasing:\n \"Workflow name '{{name}}' is not in the configured casing: {{caseTypes}}.\",\n },\n schema: [\n {\n anyOf: [\n {\n description:\n \"Single allowed casing convention for the workflow `name` value.\",\n enum: githubActionsCasingKinds,\n type: \"string\",\n },\n {\n additionalProperties: false,\n description:\n \"Allowed casing conventions and ignore patterns for the workflow `name` value.\",\n properties: {\n camelCase: {\n description: \"Allow camelCase workflow names.\",\n type: \"boolean\",\n },\n ignores: {\n description:\n \"Literal workflow names that should be ignored by this rule.\",\n items: {\n type: \"string\",\n },\n type: \"array\",\n uniqueItems: true,\n },\n \"kebab-case\": {\n description: \"Allow kebab-case workflow names.\",\n type: \"boolean\",\n },\n PascalCase: {\n description: \"Allow PascalCase workflow names.\",\n type: \"boolean\",\n },\n SCREAMING_SNAKE_CASE: {\n description:\n \"Allow SCREAMING_SNAKE_CASE workflow names.\",\n type: \"boolean\",\n },\n snake_case: {\n description: \"Allow snake_case workflow names.\",\n type: \"boolean\",\n },\n \"Title Case\": {\n description: \"Allow Title Case workflow names.\",\n type: \"boolean\",\n },\n \"Train-Case\": {\n description: \"Allow Train-Case workflow names.\",\n type: \"boolean\",\n },\n },\n type: \"object\",\n },\n ],\n description:\n \"Configure one or more allowed casing conventions for workflow `name` values.\",\n },\n ],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Enforce a consistent naming convention for workflow job identifiers.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n type GithubActionsNonTitleCasingKind,\n githubActionsNonTitleCasingKinds,\n matchesGithubActionsCasing,\n} from \"../_internal/casing.js\";\nimport {\n getWorkflowJobs,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Object-style configuration for `job-id-casing`. */\ntype JobIdCasingObjectOption = Partial<\n Record<GithubActionsNonTitleCasingKind, boolean>\n> & {\n readonly ignores?: readonly string[];\n};\n\n/** Rule options for `job-id-casing`. */\ntype JobIdCasingOptions = [\n (GithubActionsNonTitleCasingKind | JobIdCasingObjectOption)?,\n];\n\n/** Default casing enforced for workflow job ids. */\nconst DEFAULT_JOB_ID_CASING: GithubActionsNonTitleCasingKind = \"kebab-case\";\n\n/** Normalize job-id-casing options into allowed casings and ignore patterns. */\nconst normalizeJobIdCasingOptions = (\n option: Readonly<\n GithubActionsNonTitleCasingKind | JobIdCasingObjectOption | undefined\n >\n): {\n allowedCasings: readonly GithubActionsNonTitleCasingKind[];\n ignoredJobIds: readonly string[];\n} => {\n if (option === undefined || typeof option === \"string\") {\n return {\n allowedCasings: [option ?? DEFAULT_JOB_ID_CASING],\n ignoredJobIds: [],\n };\n }\n\n const allowedCasings = githubActionsNonTitleCasingKinds.filter(\n (casingKind) => option[casingKind] === true\n );\n\n return {\n allowedCasings:\n allowedCasings.length > 0\n ? allowedCasings\n : [DEFAULT_JOB_ID_CASING],\n ignoredJobIds: [...(option.ignores ?? [])],\n };\n};\n\n/** Rule implementation for enforcing job-id casing. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const [option] = context.options as JobIdCasingOptions;\n const { allowedCasings, ignoredJobIds } = normalizeJobIdCasingOptions(\n option ?? undefined\n );\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n if (ignoredJobIds.includes(job.id)) {\n continue;\n }\n\n const matchesAllowedCasing = allowedCasings.some(\n (casingKind) =>\n matchesGithubActionsCasing(job.id, casingKind)\n );\n\n if (!matchesAllowedCasing) {\n context.report({\n data: {\n caseTypes: allowedCasings.join(\", \"),\n jobId: job.id,\n },\n messageId: \"jobIdDoesNotMatchCasing\",\n node: job.idNode as unknown as Rule.Node,\n });\n }\n }\n },\n };\n },\n meta: {\n defaultOptions: [DEFAULT_JOB_ID_CASING],\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"enforce a consistent casing convention for workflow job identifiers.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R010\",\n ruleNumber: 10,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/job-id-casing\",\n },\n messages: {\n jobIdDoesNotMatchCasing:\n \"Job id '{{jobId}}' is not in the configured casing: {{caseTypes}}.\",\n },\n schema: [\n {\n anyOf: [\n {\n description:\n \"Single allowed casing convention for workflow job ids.\",\n enum: githubActionsNonTitleCasingKinds,\n type: \"string\",\n },\n {\n additionalProperties: false,\n description:\n \"Allowed casing conventions and ignore patterns for workflow job ids.\",\n properties: {\n camelCase: {\n description: \"Allow camelCase job ids.\",\n type: \"boolean\",\n },\n ignores: {\n description:\n \"Literal job ids that should be ignored by this rule.\",\n items: {\n type: \"string\",\n },\n type: \"array\",\n uniqueItems: true,\n },\n \"kebab-case\": {\n description: \"Allow kebab-case job ids.\",\n type: \"boolean\",\n },\n PascalCase: {\n description: \"Allow PascalCase job ids.\",\n type: \"boolean\",\n },\n SCREAMING_SNAKE_CASE: {\n description:\n \"Allow SCREAMING_SNAKE_CASE job ids.\",\n type: \"boolean\",\n },\n snake_case: {\n description: \"Allow snake_case job ids.\",\n type: \"boolean\",\n },\n \"Train-Case\": {\n description: \"Allow Train-Case job ids.\",\n type: \"boolean\",\n },\n },\n type: \"object\",\n },\n ],\n description:\n \"Configure one or more allowed casing conventions for workflow job ids.\",\n },\n ],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Enforce an upper bound on the number of jobs declared in one workflow file.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingValueAsMapping,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule options for `max-jobs-per-action`. */\ntype MaxJobsPerActionOptions = [number?];\n\n/** Default maximum number of jobs allowed in a single workflow file. */\nconst DEFAULT_MAX_JOBS = 3;\n\n/** Rule implementation for limiting workflow job counts. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const [configuredMaxJobs = DEFAULT_MAX_JOBS] =\n context.options as MaxJobsPerActionOptions;\n const maxJobs =\n configuredMaxJobs >= 1 ? configuredMaxJobs : DEFAULT_MAX_JOBS;\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const jobsMapping = getMappingValueAsMapping(root, \"jobs\");\n\n if (jobsMapping === null) {\n return;\n }\n\n const jobCount = jobsMapping.pairs.length;\n\n if (jobCount > maxJobs) {\n context.report({\n data: {\n count: String(jobCount),\n limit: String(maxJobs),\n },\n messageId: \"tooManyJobs\",\n node: jobsMapping as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n defaultOptions: [DEFAULT_MAX_JOBS],\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"enforce a maximum number of jobs per workflow file so large pipelines stay modular and reviewable.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R011\",\n ruleNumber: 11,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/max-jobs-per-action\",\n },\n messages: {\n tooManyJobs:\n \"This workflow defines {{count}} jobs, which exceeds the configured maximum of {{limit}}.\",\n },\n schema: [\n {\n description:\n \"Maximum number of jobs allowed in a single GitHub Actions workflow file.\",\n minimum: 1,\n type: \"integer\",\n },\n ],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow case-insensitive collisions between action input ids.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isActionMetadataFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for case-insensitive input id collision detection. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isActionMetadataFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n const inputsMapping =\n root === null\n ? null\n : getMappingValueAsMapping(root, \"inputs\");\n\n if (inputsMapping === null) {\n return;\n }\n\n const inputByCanonicalId = new Map<string, string>();\n\n for (const pair of inputsMapping.pairs) {\n const inputId = getScalarStringValue(pair.key);\n\n if (inputId === null) {\n continue;\n }\n\n const canonicalId = inputId.toLowerCase();\n const firstSeenInputId =\n inputByCanonicalId.get(canonicalId);\n\n if (firstSeenInputId === undefined) {\n inputByCanonicalId.set(canonicalId, inputId);\n\n continue;\n }\n\n if (firstSeenInputId === inputId) {\n continue;\n }\n\n context.report({\n data: {\n firstInputId: firstSeenInputId,\n inputId,\n },\n messageId: \"collidingInputId\",\n node: pair.key as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.actionMetadata\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow case-insensitive collisions between action input ids.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R048\",\n ruleNumber: 48,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-case-insensitive-input-id-collision\",\n },\n messages: {\n collidingInputId:\n \"Input '{{inputId}}' collides with '{{firstInputId}}' when normalized case-insensitively.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Generic YAML AST traversal utilities shared by lint rules.\n */\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport { getScalarStringValue, unwrapYamlValue } from \"./workflow-yaml.js\";\n/* eslint-disable @typescript-eslint/prefer-readonly-parameter-types -- Traversal operates on parser-provided mutable AST node types. */\n\n/** Visit every string scalar contained in a YAML subtree. */\nexport const visitYamlStringScalars = (\n node: AST.YAMLContent | AST.YAMLWithMeta | null | undefined,\n visitor: (node: Readonly<AST.YAMLScalar>, value: string) => void\n): void => {\n const unwrappedNode = unwrapYamlValue(node ?? null);\n\n if (unwrappedNode === null) {\n return;\n }\n\n if (unwrappedNode.type === \"YAMLScalar\") {\n const scalarValue = getScalarStringValue(unwrappedNode);\n\n if (scalarValue !== null) {\n visitor(unwrappedNode, scalarValue);\n }\n\n return;\n }\n\n if (unwrappedNode.type === \"YAMLSequence\") {\n for (const entry of unwrappedNode.entries) {\n visitYamlStringScalars(entry, visitor);\n }\n\n return;\n }\n\n if (unwrappedNode.type !== \"YAMLMapping\") {\n return;\n }\n\n for (const pair of unwrappedNode.pairs) {\n visitYamlStringScalars(pair.value ?? null, visitor);\n }\n};\n\n/** Collect every string scalar value from a YAML subtree. */\nexport const collectYamlStringScalars = (\n node: AST.YAMLContent | AST.YAMLWithMeta | null | undefined\n): readonly string[] => {\n const values: string[] = [];\n\n visitYamlStringScalars(node, (_node, value) => {\n values.push(value);\n });\n\n return values;\n};\n\n/* eslint-enable @typescript-eslint/prefer-readonly-parameter-types -- Re-enable readonly-parameter checks outside YAML traversal internals. */\n", "/**\n * @packageDocumentation\n * Disallow INPUT_* environment variable access inside composite action runs.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isActionMetadataFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\nimport { visitYamlStringScalars } from \"../_internal/yaml-traversal.js\";\n\n/** Composite-action INPUT_* environment variable reference detector. */\nconst inputEnvironmentPattern = /\\bINPUT_[\\dA-Z_]+\\b/g;\n\n/** Rule implementation for composite input access style checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isActionMetadataFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n const runsMapping =\n root === null\n ? null\n : getMappingValueAsMapping(root, \"runs\");\n\n if (runsMapping === null) {\n return;\n }\n\n const usingRuntime = getScalarStringValue(\n runsMapping.pairs.find(\n (pair) => getScalarStringValue(pair.key) === \"using\"\n )?.value\n );\n\n if (usingRuntime !== \"composite\") {\n return;\n }\n\n visitYamlStringScalars(runsMapping, (node, value) => {\n const firstMatch = value.match(\n inputEnvironmentPattern\n )?.[0];\n\n if (firstMatch === undefined) {\n return;\n }\n\n context.report({\n data: {\n inputEnvironmentReference: firstMatch,\n },\n messageId: \"compositeInputEnvAccess\",\n node: node as unknown as Rule.Node,\n });\n });\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.actionMetadata\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow `INPUT_*` environment-variable access in composite actions and require `inputs.*` context references.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R049\",\n ruleNumber: 49,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-composite-input-env-access\",\n },\n messages: {\n compositeInputEnvAccess:\n \"Composite actions should reference inputs via `inputs.*`, not environment variable '{{inputEnvironmentReference}}'.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow deprecated Node.js action runtimes.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isActionMetadataFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Deprecated Node runtime values for `runs.using`. */\nconst deprecatedNodeRuntimes = new Set([\"node12\", \"node16\"]);\n\n/** Rule implementation for deprecated Node runtime checks in action metadata. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isActionMetadataFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const runsMapping = getMappingValueAsMapping(root, \"runs\");\n\n if (runsMapping === null) {\n return;\n }\n\n const usingPair = runsMapping.pairs.find(\n (pair) => getScalarStringValue(pair.key) === \"using\"\n );\n const usingRuntime = getScalarStringValue(usingPair?.value);\n\n if (\n usingRuntime === null ||\n !deprecatedNodeRuntimes.has(usingRuntime)\n ) {\n return;\n }\n\n context.report({\n data: {\n runtime: usingRuntime,\n },\n messageId: \"deprecatedNodeRuntime\",\n node: (usingPair?.value ??\n usingPair) as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.actionMetadata\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow deprecated Node.js runtimes in action metadata `runs.using`.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R044\",\n ruleNumber: 44,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-deprecated-node-runtime\",\n },\n messages: {\n deprecatedNodeRuntime:\n \"Action metadata uses deprecated runtime `{{runtime}}` for `runs.using`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow duplicate step IDs in composite actions.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isActionMetadataFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for duplicate composite step ID checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isActionMetadataFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n const runsMapping =\n root === null\n ? null\n : getMappingValueAsMapping(root, \"runs\");\n\n if (runsMapping === null) {\n return;\n }\n\n const usingRuntime = getScalarStringValue(\n getMappingPair(runsMapping, \"using\")?.value\n );\n\n if (usingRuntime !== \"composite\") {\n return;\n }\n\n const stepsSequence = getMappingValueAsSequence(\n runsMapping,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n return;\n }\n\n const firstSeenByStepId = new Set<string>();\n\n for (const stepEntry of stepsSequence.entries) {\n const stepMapping = unwrapYamlValue(stepEntry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const stepIdPair = getMappingPair(stepMapping, \"id\");\n const stepId = getScalarStringValue(stepIdPair?.value);\n\n if (stepId === null) {\n continue;\n }\n\n if (!firstSeenByStepId.has(stepId)) {\n firstSeenByStepId.add(stepId);\n\n continue;\n }\n\n context.report({\n data: {\n stepId,\n },\n messageId: \"duplicateCompositeStepId\",\n node: (stepIdPair?.value ??\n stepIdPair) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.actionMetadata\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow duplicate step IDs in `runs.steps` for composite actions.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R051\",\n ruleNumber: 51,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-duplicate-composite-step-id\",\n },\n messages: {\n duplicateCompositeStepId:\n \"Composite step id '{{stepId}}' is declared more than once.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Helpers for reading workflow-template metadata from `.properties.json` files.\n */\n/* eslint-disable @typescript-eslint/prefer-readonly-parameter-types -- YAML parser AST nodes are third-party mutable structures; readonly wrappers reduce interoperability across helper APIs. */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport { dirname, join } from \"node:path\";\n\nimport {\n getMappingPair,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"./workflow-yaml.js\";\n\n/** Read and return the template metadata root mapping if present. */\nexport const getWorkflowTemplatePropertiesRoot = (\n context: Rule.RuleContext\n): AST.YAMLMapping | null => getWorkflowRoot(context);\n\n/** Read a scalar string property from workflow-template metadata. */\nexport const getWorkflowTemplateStringProperty = (\n root: AST.YAMLMapping,\n key: string\n): null | string => getScalarStringValue(getMappingPair(root, key)?.value);\n\n/** Resolve `filePatterns` entries with both node and scalar string value. */\nexport const getWorkflowTemplateFilePatternEntries = (\n root: AST.YAMLMapping\n): readonly Readonly<{ node: AST.YAMLNode; value: string }>[] => {\n const filePatternsSequence = getMappingValueAsSequence(\n root,\n \"filePatterns\"\n );\n\n if (filePatternsSequence === null) {\n return [];\n }\n\n const entries: Readonly<{ node: AST.YAMLNode; value: string }>[] = [];\n\n for (const entry of filePatternsSequence.entries) {\n const entryValue = getScalarStringValue(entry);\n\n if (entryValue === null || entry === null || entry === undefined) {\n continue;\n }\n\n entries.push({\n node: entry,\n value: entryValue,\n });\n }\n\n return entries;\n};\n/* eslint-enable @typescript-eslint/prefer-readonly-parameter-types -- Re-enable readonly-parameter checks outside parser AST helper signatures. */\n\n/** Build the matching `.properties.json` path for a template YAML path. */\nexport const getPairedTemplatePropertiesPath = (filePath: string): string => {\n const stem = filePath.endsWith(\".yaml\")\n ? filePath.slice(0, -\".yaml\".length)\n : filePath.slice(0, -\".yml\".length);\n\n return `${stem}.properties.json`;\n};\n\n/** Build both valid template YAML paths for a `.properties.json` path. */\nexport const getPairedTemplateYamlPaths = (\n filePath: string\n): readonly [string, string] => {\n const fileDirectory = dirname(filePath);\n const fileName = filePath.slice(fileDirectory.length + 1);\n const stem = fileName.slice(0, -\".properties.json\".length);\n\n return [\n join(fileDirectory, `${stem}.yml`),\n join(fileDirectory, `${stem}.yaml`),\n ];\n};\n", "/**\n * @packageDocumentation\n * Disallow empty or whitespace-only `filePatterns` entries.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowTemplatePropertiesFile } from \"../_internal/lint-targets.js\";\nimport {\n getWorkflowTemplateFilePatternEntries,\n getWorkflowTemplatePropertiesRoot,\n} from \"../_internal/workflow-template-properties.js\";\n\n/** Rule implementation for empty template file pattern checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowTemplatePropertiesRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const {\n node,\n value,\n } of getWorkflowTemplateFilePatternEntries(root)) {\n if (value.trim().length > 0) {\n continue;\n }\n\n context.report({\n messageId: \"emptyTemplateFilePattern\",\n node: node as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow empty or whitespace-only entries in workflow-template `filePatterns`.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R060\",\n ruleNumber: 60,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-empty-template-file-pattern\",\n },\n messages: {\n emptyTemplateFilePattern:\n \"Template `filePatterns` entries must be non-empty regex strings.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow defining jobs as reusable workflow invocations via `uses`.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getWorkflowJobs,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for disallowing reusable-workflow jobs. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n const usesPair = getMappingPair(job.mapping, \"uses\");\n\n if (usesPair === null) {\n continue;\n }\n\n context.report({\n data: {\n jobId: job.id,\n },\n messageId: \"externalJob\",\n node: (usesPair.value ??\n usesPair) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow reusable-workflow jobs declared with `jobs.<id>.uses` when you want every job defined inline in the workflow file.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R012\",\n ruleNumber: 12,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-external-job\",\n },\n messages: {\n externalJob:\n \"Job '{{jobId}}' uses a reusable workflow via `uses`. Define the job inline instead.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow hardcoded default branch names in workflow templates.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowTemplateYamlFile } from \"../_internal/lint-targets.js\";\nimport { getWorkflowRoot } from \"../_internal/workflow-yaml.js\";\nimport { visitYamlStringScalars } from \"../_internal/yaml-traversal.js\";\n\n/** Branch literals that should be replaced with `$default-branch` in templates. */\nconst hardcodedDefaultBranchNames = new Set([\"main\", \"master\"]);\n\n/** Rule implementation for hardcoded default branch checks in templates. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isWorkflowTemplateYamlFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n visitYamlStringScalars(root, (node, value) => {\n if (!hardcodedDefaultBranchNames.has(value.trim())) {\n return;\n }\n\n context.report({\n data: {\n branchName: value,\n },\n messageId: \"hardcodedDefaultBranch\",\n node: node as unknown as Rule.Node,\n });\n });\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow hardcoded `main`/`master` branch literals in workflow template YAML files.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R068\",\n ruleNumber: 68,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-hardcoded-default-branch-in-template\",\n },\n messages: {\n hardcodedDefaultBranch:\n \"Template contains hardcoded default branch '{{branchName}}'; prefer `$default-branch` placeholder.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow including `.svg` extension in workflow-template `iconName`.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowTemplatePropertiesFile } from \"../_internal/lint-targets.js\";\nimport {\n getWorkflowTemplatePropertiesRoot,\n getWorkflowTemplateStringProperty,\n} from \"../_internal/workflow-template-properties.js\";\n\n/** Rule implementation for `iconName` extension checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowTemplatePropertiesRoot(context);\n\n if (root === null) {\n return;\n }\n\n const iconName = getWorkflowTemplateStringProperty(\n root,\n \"iconName\"\n );\n\n if (iconName === null) {\n return;\n }\n\n if (!iconName.toLowerCase().endsWith(\".svg\")) {\n return;\n }\n\n context.report({\n data: {\n iconName,\n },\n messageId: \"iconNameIncludesExtension\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow `.svg` extensions in workflow-template `iconName` values.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R063\",\n ruleNumber: 63,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-icon-file-extension-in-template-icon-name\",\n },\n messages: {\n iconNameIncludesExtension:\n \"Template `iconName` '{{iconName}}' should omit the `.svg` extension.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow broad reusable-workflow secret inheritance.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Determine whether a job references a reusable workflow. */\nconst isReusableWorkflowJob = (\n jobMapping: Readonly<AST.YAMLMapping>\n): boolean => getMappingPair(jobMapping, \"uses\") !== null;\n\n/** Determine whether a secrets pair uses the broad `inherit` shortcut. */\nconst isInheritSecretsValue = (\n secretsPair: Readonly<NonNullable<ReturnType<typeof getMappingPair>>>\n): boolean => getScalarStringValue(secretsPair.value)?.trim() === \"inherit\";\n\n/** Rule implementation for disallowing reusable-workflow `secrets: inherit`. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n if (!isReusableWorkflowJob(job.mapping)) {\n continue;\n }\n\n const secretsPair = getMappingPair(job.mapping, \"secrets\");\n\n if (\n secretsPair === null ||\n !isInheritSecretsValue(secretsPair)\n ) {\n continue;\n }\n\n context.report({\n data: {\n jobId: job.id,\n },\n messageId: \"inheritedSecrets\",\n node: secretsPair.value as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.security\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow `secrets: inherit` on reusable-workflow jobs so callers pass only the named secrets each workflow actually needs.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R026\",\n ruleNumber: 26,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-inherit-secrets\",\n },\n messages: {\n inheritedSecrets:\n \"Job '{{jobId}}' uses `secrets: inherit`. Pass only the specific named secrets the called workflow requires.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Shared helpers for extracting GitHub Actions `${{ ... }}` expressions.\n */\n\n/** Determine whether a character can begin a GitHub expression identifier. */\nconst isIdentifierStart = (character: string | undefined): boolean => {\n if (character === undefined) {\n return false;\n }\n\n return /[A-Z_a-z]/u.test(character);\n};\n\n/** Determine whether a character can continue a GitHub expression identifier. */\nconst isIdentifierContinue = (character: string | undefined): boolean => {\n if (character === undefined) {\n return false;\n }\n\n return /[\\w-]/u.test(character);\n};\n\n/** Known root context names available in GitHub Actions expressions. */\nconst knownContextRoots: ReadonlySet<string> = new Set([\n \"env\",\n \"github\",\n \"inputs\",\n \"job\",\n \"jobs\",\n \"matrix\",\n \"needs\",\n \"runner\",\n \"secrets\",\n \"steps\",\n \"strategy\",\n \"vars\",\n]);\n\n/** Extract every embedded GitHub expression body from a scalar value. */\nexport const getGithubExpressionBodies = (value: string): readonly string[] => {\n const expressions: string[] = [];\n let searchStart = 0;\n\n while (searchStart < value.length) {\n const startOffset = value.indexOf(\"${{\", searchStart);\n\n if (startOffset === -1) {\n break;\n }\n\n const endOffset = value.indexOf(\"}}\", startOffset + 3);\n\n if (endOffset === -1) {\n break;\n }\n\n const expression = value.slice(startOffset + 3, endOffset).trim();\n\n if (expression.length > 0) {\n expressions.push(expression);\n }\n\n searchStart = endOffset + 2;\n }\n\n return expressions;\n};\n\n/** Collect referenced root contexts from embedded GitHub expressions. */\nexport const getReferencedContextRoots = (value: string): readonly string[] => {\n const roots = new Set<string>();\n\n for (const expression of getGithubExpressionBodies(value)) {\n let index = 0;\n\n while (index < expression.length) {\n const character = expression[index];\n const previousCharacter = expression[index - 1];\n\n if (\n !isIdentifierStart(character) ||\n isIdentifierContinue(previousCharacter)\n ) {\n index += 1;\n\n continue;\n }\n\n let endOffset = index + 1;\n\n while (isIdentifierContinue(expression[endOffset])) {\n endOffset += 1;\n }\n\n const token = expression.slice(index, endOffset);\n const nextChar = expression[endOffset];\n\n if (nextChar !== \".\" && nextChar !== \"[\") {\n index = endOffset;\n\n continue;\n }\n\n const normalizedToken = token.toLowerCase();\n\n if (knownContextRoots.has(normalizedToken)) {\n roots.add(normalizedToken);\n }\n\n index = endOffset;\n }\n }\n\n return [...roots];\n};\n", "/**\n * @packageDocumentation\n * Disallow unavailable contexts inside workflow and job concurrency expressions.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getGithubExpressionBodies,\n getReferencedContextRoots,\n} from \"../_internal/github-expressions.js\";\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Allowed contexts for top-level workflow `concurrency`. */\nconst allowedWorkflowConcurrencyContexts: ReadonlySet<string> = new Set([\n \"github\",\n \"inputs\",\n \"vars\",\n]);\n\n/** Allowed contexts for `jobs.<job_id>.concurrency`. */\nconst allowedJobConcurrencyContexts: ReadonlySet<string> = new Set([\n \"github\",\n \"inputs\",\n \"matrix\",\n \"needs\",\n \"strategy\",\n \"vars\",\n]);\n\n/** Determine whether a scalar contains any GitHub expressions. */\nconst containsGithubExpression = (value: string): boolean =>\n getGithubExpressionBodies(value).length > 0;\n\n/** Collect disallowed context roots for the provided scalar value. */\nconst getDisallowedContexts = (\n value: string,\n allowedContexts: ReadonlySet<string>\n): readonly string[] =>\n getReferencedContextRoots(value).filter(\n (contextRoot) => !allowedContexts.has(contextRoot)\n );\n\n/** Check a single concurrency scalar for unsupported context usage. */\nconst reportInvalidContexts = (\n context: Readonly<Rule.RuleContext>,\n options: Readonly<{\n readonly allowedContexts: ReadonlySet<string>;\n readonly field: string;\n readonly jobId: string | undefined;\n readonly messageId:\n | \"invalidJobConcurrencyContext\"\n | \"invalidWorkflowConcurrencyContext\";\n readonly node: unknown;\n readonly value: string;\n }>\n): void => {\n if (!containsGithubExpression(options.value)) {\n return;\n }\n\n const disallowedContexts = getDisallowedContexts(\n options.value,\n options.allowedContexts\n );\n\n if (disallowedContexts.length === 0) {\n return;\n }\n\n context.report({\n data: {\n contexts: disallowedContexts.join(\", \"),\n field: options.field,\n jobId: options.jobId,\n },\n messageId: options.messageId,\n node: options.node as Rule.Node,\n });\n};\n\n/** Inspect a workflow-level or job-level concurrency declaration. */\nconst inspectConcurrencyValue = (\n context: Readonly<Rule.RuleContext>,\n options: Readonly<{\n readonly allowedContexts: ReadonlySet<string>;\n readonly concurrencyNode: Parameters<typeof unwrapYamlValue>[0];\n readonly jobId: string | undefined;\n readonly messageId:\n | \"invalidJobConcurrencyContext\"\n | \"invalidWorkflowConcurrencyContext\";\n }>\n): void => {\n const concurrencyValue = unwrapYamlValue(options.concurrencyNode);\n\n if (concurrencyValue === null) {\n return;\n }\n\n if (concurrencyValue.type === \"YAMLScalar\") {\n const scalarValue = getScalarStringValue(concurrencyValue);\n\n if (scalarValue === null || scalarValue.trim().length === 0) {\n return;\n }\n\n reportInvalidContexts(context, {\n allowedContexts: options.allowedContexts,\n field: \"concurrency\",\n jobId: options.jobId,\n messageId: options.messageId,\n node: concurrencyValue,\n value: scalarValue,\n });\n\n return;\n }\n\n if (concurrencyValue.type !== \"YAMLMapping\") {\n return;\n }\n\n for (const fieldName of [\"group\", \"cancel-in-progress\"] as const) {\n const fieldPair = getMappingPair(concurrencyValue, fieldName);\n\n if (fieldPair === null) {\n continue;\n }\n\n const fieldValueNode = unwrapYamlValue(fieldPair.value);\n const fieldValue = getScalarStringValue(fieldValueNode);\n\n if (fieldValue === null || fieldValue.trim().length === 0) {\n continue;\n }\n\n reportInvalidContexts(context, {\n allowedContexts: options.allowedContexts,\n field: `concurrency.${fieldName}`,\n jobId: options.jobId,\n messageId: options.messageId,\n node: fieldValueNode ?? fieldPair,\n value: fieldValue,\n });\n }\n};\n\n/** Rule implementation for validating concurrency context usage. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const workflowConcurrencyPair = getMappingPair(\n root,\n \"concurrency\"\n );\n\n if (workflowConcurrencyPair !== null) {\n inspectConcurrencyValue(context, {\n allowedContexts: allowedWorkflowConcurrencyContexts,\n concurrencyNode: workflowConcurrencyPair.value,\n jobId: undefined,\n messageId: \"invalidWorkflowConcurrencyContext\",\n });\n }\n\n for (const job of getWorkflowJobs(root)) {\n const jobConcurrencyPair = getMappingPair(\n job.mapping,\n \"concurrency\"\n );\n\n if (jobConcurrencyPair === null) {\n continue;\n }\n\n inspectConcurrencyValue(context, {\n allowedContexts: allowedJobConcurrencyContexts,\n concurrencyNode: jobConcurrencyPair.value,\n jobId: job.id,\n messageId: \"invalidJobConcurrencyContext\",\n });\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow unavailable contexts in workflow-level and job-level `concurrency` expressions.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R042\",\n ruleNumber: 42,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-invalid-concurrency-context\",\n },\n messages: {\n invalidJobConcurrencyContext:\n \"Job '{{jobId}}' `{{field}}` references unsupported context access ({{contexts}}). Job-level concurrency may only reference `github`, `needs`, `strategy`, `matrix`, `inputs`, and `vars`.\",\n invalidWorkflowConcurrencyContext:\n \"Workflow `{{field}}` references unsupported context access ({{contexts}}). Top-level concurrency may only reference `github`, `inputs`, and `vars`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow invalid keys in GitHub Actions workflow mappings.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingValueAsMapping,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Valid top-level workflow keys. */\nconst VALID_TOP_LEVEL_KEYS = new Set<string>([\n \"concurrency\",\n \"defaults\",\n \"env\",\n \"jobs\",\n \"name\",\n \"on\",\n \"permissions\",\n \"run-name\",\n]);\n\n/** Valid job-level keys under `jobs.<job_id>`. */\nconst VALID_JOB_KEYS = new Set<string>([\n \"concurrency\",\n \"container\",\n \"continue-on-error\",\n \"defaults\",\n \"env\",\n \"environment\",\n \"if\",\n \"name\",\n \"needs\",\n \"outputs\",\n \"permissions\",\n \"runs-on\",\n \"secrets\",\n \"services\",\n \"steps\",\n \"strategy\",\n \"timeout-minutes\",\n \"uses\",\n \"with\",\n]);\n\n/** Valid strategy keys under `jobs.<job_id>.strategy`. */\nconst VALID_STRATEGY_KEYS = new Set<string>([\n \"fail-fast\",\n \"matrix\",\n \"max-parallel\",\n]);\n\n/** Valid container and service keys. */\nconst VALID_CONTAINER_OR_SERVICE_KEYS = new Set<string>([\n \"credentials\",\n \"env\",\n \"image\",\n \"options\",\n \"ports\",\n \"volumes\",\n]);\n\n/** Valid step keys under `jobs.<job_id>.steps[]`. */\nconst VALID_STEP_KEYS = new Set<string>([\n \"continue-on-error\",\n \"env\",\n \"id\",\n \"if\",\n \"name\",\n \"run\",\n \"shell\",\n \"timeout-minutes\",\n \"uses\",\n \"with\",\n \"working-directory\",\n]);\n\n/** Report invalid mapping keys for one workflow section. */\nconst reportInvalidKeys = (\n context: Readonly<Rule.RuleContext>,\n mapping: Readonly<AST.YAMLMapping>,\n validKeys: ReadonlySet<string>,\n messageId:\n | \"invalidContainerKey\"\n | \"invalidJobKey\"\n | \"invalidServiceKey\"\n | \"invalidStepKey\"\n | \"invalidStrategyKey\"\n | \"invalidTopLevelKey\"\n): void => {\n for (const pair of mapping.pairs) {\n const keyValue = getScalarStringValue(pair.key);\n\n if (keyValue === null || validKeys.has(keyValue)) {\n continue;\n }\n\n context.report({\n data: {\n key: keyValue,\n },\n messageId,\n node: (pair.key ?? pair) as unknown as Rule.Node,\n });\n }\n};\n\n/** Rule implementation for validating workflow mapping keys. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n reportInvalidKeys(\n context,\n root,\n VALID_TOP_LEVEL_KEYS,\n \"invalidTopLevelKey\"\n );\n\n for (const job of getWorkflowJobs(root)) {\n reportInvalidKeys(\n context,\n job.mapping,\n VALID_JOB_KEYS,\n \"invalidJobKey\"\n );\n\n const strategyMapping = getMappingValueAsMapping(\n job.mapping,\n \"strategy\"\n );\n\n if (strategyMapping !== null) {\n reportInvalidKeys(\n context,\n strategyMapping,\n VALID_STRATEGY_KEYS,\n \"invalidStrategyKey\"\n );\n }\n\n const containerMapping = getMappingValueAsMapping(\n job.mapping,\n \"container\"\n );\n\n if (containerMapping !== null) {\n reportInvalidKeys(\n context,\n containerMapping,\n VALID_CONTAINER_OR_SERVICE_KEYS,\n \"invalidContainerKey\"\n );\n }\n\n const servicesMapping = getMappingValueAsMapping(\n job.mapping,\n \"services\"\n );\n\n if (servicesMapping !== null) {\n for (const servicePair of servicesMapping.pairs) {\n const serviceMapping = unwrapYamlValue(\n servicePair.value\n );\n\n if (serviceMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n reportInvalidKeys(\n context,\n serviceMapping,\n VALID_CONTAINER_OR_SERVICE_KEYS,\n \"invalidServiceKey\"\n );\n }\n }\n\n const stepsSequence = getMappingValueAsSequence(\n job.mapping,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n continue;\n }\n\n for (const step of stepsSequence.entries) {\n const stepMapping = unwrapYamlValue(step);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n reportInvalidKeys(\n context,\n stepMapping,\n VALID_STEP_KEYS,\n \"invalidStepKey\"\n );\n }\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow unsupported keys in common GitHub Actions workflow mappings.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R019\",\n ruleNumber: 19,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-invalid-key\",\n },\n messages: {\n invalidContainerKey:\n \"`{{key}}` is not a valid key for a job `container` block.\",\n invalidJobKey:\n \"`{{key}}` is not a valid key for a workflow job definition.\",\n invalidServiceKey:\n \"`{{key}}` is not a valid key for a job `services` entry.\",\n invalidStepKey: \"`{{key}}` is not a valid key for a workflow step.\",\n invalidStrategyKey:\n \"`{{key}}` is not a valid key for a job `strategy` block.\",\n invalidTopLevelKey:\n \"`{{key}}` is not a valid top-level workflow key.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow unsupported keys on jobs that call reusable workflows.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Supported keywords for jobs that call reusable workflows via `uses`. */\nconst reusableWorkflowJobKeys = [\n \"name\",\n \"uses\",\n \"with\",\n \"secrets\",\n \"strategy\",\n \"needs\",\n \"if\",\n \"concurrency\",\n \"permissions\",\n] as const;\n\n/** Constant-time lookup for supported reusable-workflow caller job keys. */\nconst reusableWorkflowJobKeySet: ReadonlySet<string> = new Set(\n reusableWorkflowJobKeys\n);\n\n/** Determine whether a job calls a reusable workflow. */\nconst isReusableWorkflowJob = (\n jobMapping: Readonly<AST.YAMLMapping>\n): boolean => getMappingPair(jobMapping, \"uses\") !== null;\n\n/** Rule implementation for validating reusable-workflow caller job keys. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n if (!isReusableWorkflowJob(job.mapping)) {\n continue;\n }\n\n for (const pair of job.mapping.pairs) {\n const key = getScalarStringValue(pair.key);\n\n if (\n key === null ||\n reusableWorkflowJobKeySet.has(key)\n ) {\n continue;\n }\n\n context.report({\n data: {\n allowedKeys: reusableWorkflowJobKeys.join(\", \"),\n jobId: job.id,\n key,\n },\n messageId: \"invalidReusableWorkflowJobKey\",\n node: pair.key as unknown as Rule.Node,\n });\n }\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow unsupported keys on jobs that call reusable workflows via `jobs.<job_id>.uses`.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R041\",\n ruleNumber: 41,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-invalid-reusable-workflow-job-key\",\n },\n messages: {\n invalidReusableWorkflowJobKey:\n \"Job '{{jobId}}' calls a reusable workflow via `uses`, so `{{key}}` is not supported here. Caller jobs may only use: {{allowedKeys}}.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow invalid regular expressions in workflow-template `filePatterns`.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowTemplatePropertiesFile } from \"../_internal/lint-targets.js\";\nimport {\n getWorkflowTemplateFilePatternEntries,\n getWorkflowTemplatePropertiesRoot,\n} from \"../_internal/workflow-template-properties.js\";\n\n/** Construct a unicode regex from a pattern string. */\nconst createUnicodeRegex = (pattern: string): RegExp =>\n // eslint-disable-next-line security/detect-non-literal-regexp -- Intentional syntax validation of user-provided regex patterns.\n new RegExp(pattern, \"u\");\n\n/** Rule implementation for validating `filePatterns` regex syntax. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowTemplatePropertiesRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const {\n node,\n value,\n } of getWorkflowTemplateFilePatternEntries(root)) {\n try {\n createUnicodeRegex(value);\n } catch {\n context.report({\n data: {\n pattern: value,\n },\n messageId: \"invalidTemplateFilePatternRegex\",\n node: node as unknown as Rule.Node,\n });\n }\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow syntactically invalid regexes in workflow-template `filePatterns`.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R059\",\n ruleNumber: 59,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-invalid-template-file-pattern-regex\",\n },\n messages: {\n invalidTemplateFilePatternRegex:\n \"Template `filePatterns` entry '{{pattern}}' is not a valid regular expression.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow invalid reusable workflow output values.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getGithubExpressionBodies,\n getReferencedContextRoots,\n} from \"../_internal/github-expressions.js\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Match reusable workflow output mappings to job outputs. */\nconst jobsOutputReferencePattern =\n /jobs\\.[A-Z_a-z][\\w-]*\\.outputs\\.[A-Z_a-z][\\w-]*/;\n\n/** Allowed expression contexts for `on.workflow_call.outputs.*.value`. */\nconst allowedWorkflowCallOutputContexts: ReadonlySet<string> = new Set([\n \"github\",\n \"inputs\",\n \"jobs\",\n \"vars\",\n]);\n\n/** Determine whether a scalar value reads at least one declared job output. */\nconst hasJobsOutputReference = (value: string): boolean =>\n getGithubExpressionBodies(value).some((expression) =>\n jobsOutputReferencePattern.test(expression)\n );\n\n/** Rule implementation for validating reusable workflow output values. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const onMapping = getMappingValueAsMapping(root, \"on\");\n\n if (onMapping === null) {\n return;\n }\n\n const workflowCallMapping = unwrapYamlValue(\n getMappingPair(onMapping, \"workflow_call\")?.value ?? null\n );\n\n if (workflowCallMapping?.type !== \"YAMLMapping\") {\n return;\n }\n\n const outputsMapping = getMappingValueAsMapping(\n workflowCallMapping,\n \"outputs\"\n );\n\n if (outputsMapping === null) {\n return;\n }\n\n for (const pair of outputsMapping.pairs) {\n const outputId = getScalarStringValue(pair.key);\n const outputMapping = unwrapYamlValue(pair.value);\n\n if (\n outputId === null ||\n outputMapping?.type !== \"YAMLMapping\"\n ) {\n continue;\n }\n\n const valuePair = getMappingPair(outputMapping, \"value\");\n const value = getScalarStringValue(\n valuePair?.value ?? null\n );\n\n if (\n valuePair === null ||\n value === null ||\n value.trim().length === 0\n ) {\n continue;\n }\n\n const disallowedContexts = getReferencedContextRoots(\n value\n ).filter(\n (contextRoot) =>\n !allowedWorkflowCallOutputContexts.has(contextRoot)\n );\n\n if (disallowedContexts.length > 0) {\n context.report({\n data: {\n contexts: disallowedContexts.join(\", \"),\n outputId,\n },\n messageId: \"invalidContext\",\n node: (valuePair.value ??\n valuePair) as unknown as Rule.Node,\n });\n\n continue;\n }\n\n if (!hasJobsOutputReference(value)) {\n context.report({\n data: {\n outputId,\n },\n messageId: \"missingJobOutputReference\",\n node: (valuePair.value ??\n valuePair) as unknown as Rule.Node,\n });\n }\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow `workflow_call` output values that use unavailable contexts or fail to map from `jobs.<job_id>.outputs.<output_name>`.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R040\",\n ruleNumber: 40,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-invalid-workflow-call-output-value\",\n },\n messages: {\n invalidContext:\n \"`workflow_call` output '{{outputId}}' uses unsupported context access in `value` ({{contexts}}). Reusable workflow output values may only reference `github`, `jobs`, `vars`, and `inputs`.\",\n missingJobOutputReference:\n \"`workflow_call` output '{{outputId}}' must map `value` from a job output such as `jobs.build.outputs.artifact`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow path separators in workflow-template `iconName` values.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowTemplatePropertiesFile } from \"../_internal/lint-targets.js\";\nimport {\n getWorkflowTemplatePropertiesRoot,\n getWorkflowTemplateStringProperty,\n} from \"../_internal/workflow-template-properties.js\";\n\n/** Rule implementation for icon path-separator checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowTemplatePropertiesRoot(context);\n\n if (root === null) {\n return;\n }\n\n const iconName = getWorkflowTemplateStringProperty(\n root,\n \"iconName\"\n );\n\n if (\n iconName === null ||\n (!iconName.includes(\"/\") && !iconName.includes(\"\\\\\"))\n ) {\n return;\n }\n\n context.report({\n data: {\n iconName,\n },\n messageId: \"iconNameContainsPathSeparator\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow path separators in workflow-template `iconName` values.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R064\",\n ruleNumber: 64,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-path-separators-in-template-icon-name\",\n },\n messages: {\n iconNameContainsPathSeparator:\n \"Template `iconName` '{{iconName}}' should be a plain icon token, not a path.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow `runs.post-if` when `runs.post` is not declared.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isActionMetadataFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for invalid `runs.post-if` usage. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isActionMetadataFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n const runsMapping =\n root === null\n ? null\n : getMappingValueAsMapping(root, \"runs\");\n\n if (runsMapping === null) {\n return;\n }\n\n const postIfPair = getMappingPair(runsMapping, \"post-if\");\n\n if (\n postIfPair === null ||\n getMappingPair(runsMapping, \"post\")\n ) {\n return;\n }\n\n context.report({\n messageId: \"postIfWithoutPost\",\n node: (postIfPair.value ??\n postIfPair) as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.actionMetadata\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow `runs.post-if` when `runs.post` is not configured in action metadata.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R046\",\n ruleNumber: 46,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-post-if-without-post\",\n },\n messages: {\n postIfWithoutPost:\n \"`runs.post-if` is set, but `runs.post` is missing. Remove `post-if` or add `post`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow checking out pull-request head content in `pull_request_target` workflows.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowEventNames,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Detect `actions/checkout` references. */\nconst isCheckoutActionReference = (reference: string): boolean =>\n reference.startsWith(\"actions/checkout@\");\n\n/** Detect risky PR-head references in checkout parameters. */\nconst hasPullRequestHeadReference = (value: string): boolean =>\n /\\bgithub\\.head_ref\\b/u.test(value) ||\n /\\bgithub\\.event\\.pull_request\\.head\\./u.test(value);\n\n/**\n * Rule implementation for disallowing pull-request head checkouts in\n * pull_request_target.\n */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const eventNames = getWorkflowEventNames(root);\n\n if (!eventNames.has(\"pull_request_target\")) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n const stepsSequence = getMappingValueAsSequence(\n job.mapping,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n continue;\n }\n\n for (const entry of stepsSequence.entries) {\n const stepMapping = unwrapYamlValue(entry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const usesPair = getMappingPair(stepMapping, \"uses\");\n const usesReference = getScalarStringValue(\n usesPair?.value ?? null\n );\n\n if (\n usesPair === null ||\n usesReference === null ||\n !isCheckoutActionReference(usesReference)\n ) {\n continue;\n }\n\n const withMapping = getMappingValueAsMapping(\n stepMapping,\n \"with\"\n );\n\n if (withMapping === null) {\n continue;\n }\n\n for (const key of [\"ref\", \"repository\"] as const) {\n const optionPair = getMappingPair(withMapping, key);\n const optionValue = getScalarStringValue(\n optionPair?.value ?? null\n );\n\n if (\n optionPair === null ||\n optionValue === null ||\n !hasPullRequestHeadReference(optionValue)\n ) {\n continue;\n }\n\n context.report({\n data: {\n jobId: job.id,\n key,\n },\n messageId: \"pullRequestHeadCheckout\",\n node: (optionPair.value ??\n optionPair) as unknown as Rule.Node,\n });\n }\n }\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.security\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow `actions/checkout` configurations in `pull_request_target` workflows that fetch pull request head refs, SHAs, or repositories into a privileged run.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R030\",\n ruleNumber: 30,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-pr-head-checkout-in-pull-request-target\",\n },\n messages: {\n pullRequestHeadCheckout:\n \"Job '{{jobId}}' uses `actions/checkout` with `with.{{key}}` pointing at pull request head content inside a `pull_request_target` workflow. Avoid checking out untrusted PR head code in this privileged trigger.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow `runs.pre-if` when `runs.pre` is not declared.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isActionMetadataFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for invalid `runs.pre-if` usage. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isActionMetadataFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n const runsMapping =\n root === null\n ? null\n : getMappingValueAsMapping(root, \"runs\");\n\n if (runsMapping === null) {\n return;\n }\n\n const preIfPair = getMappingPair(runsMapping, \"pre-if\");\n\n if (preIfPair === null || getMappingPair(runsMapping, \"pre\")) {\n return;\n }\n\n context.report({\n messageId: \"preIfWithoutPre\",\n node: (preIfPair.value ??\n preIfPair) as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.actionMetadata\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow `runs.pre-if` when `runs.pre` is not configured in action metadata.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R045\",\n ruleNumber: 45,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-pre-if-without-pre\",\n },\n messages: {\n preIfWithoutPre:\n \"`runs.pre-if` is set, but `runs.pre` is missing. Remove `pre-if` or add `pre`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow action inputs that are both required and defaulted.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isActionMetadataFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for contradictory action input definitions. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isActionMetadataFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n const inputsMapping =\n root === null\n ? null\n : getMappingValueAsMapping(root, \"inputs\");\n\n if (inputsMapping === null) {\n return;\n }\n\n for (const pair of inputsMapping.pairs) {\n const inputId = getScalarStringValue(pair.key);\n const inputMapping = unwrapYamlValue(pair.value);\n\n if (\n inputId === null ||\n inputMapping?.type !== \"YAMLMapping\"\n ) {\n continue;\n }\n\n const requiredPair = getMappingPair(\n inputMapping,\n \"required\"\n );\n const defaultPair = getMappingPair(inputMapping, \"default\");\n\n if (requiredPair === null || defaultPair === null) {\n continue;\n }\n\n const requiredValue = unwrapYamlValue(requiredPair.value);\n\n if (\n requiredValue?.type !== \"YAMLScalar\" ||\n requiredValue.value !== true\n ) {\n continue;\n }\n\n context.report({\n data: {\n inputId,\n },\n messageId: \"requiredInputWithDefault\",\n node: (defaultPair.value ??\n defaultPair) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.actionMetadata\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow action inputs that set both `required: true` and `default`.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R047\",\n ruleNumber: 47,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-required-input-with-default\",\n },\n messages: {\n requiredInputWithDefault:\n \"Input '{{inputId}}' sets both `required: true` and `default`, which is contradictory for action callers.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow direct secret references in `if` conditionals.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Direct secret-access patterns that GitHub discourages in `if` conditionals. */\nconst directSecretsPatterns = [\n /\\bsecrets\\.\\w+\\b/u,\n /\\bsecrets\\[[\"'][^\"'\\]]+[\"']\\]/u,\n] as const;\n\n/**\n * Determine whether an `if` expression directly references the `secrets`\n * context.\n */\nconst hasDirectSecretsReference = (expression: string): boolean =>\n directSecretsPatterns.some((pattern) => pattern.test(expression));\n\n/** Report a direct-secrets conditional reference. */\nconst reportDirectSecretsConditional = (\n context: Readonly<Rule.RuleContext>,\n ifPair: Readonly<AST.YAMLPair>,\n scope: string\n): void => {\n context.report({\n data: {\n scope,\n },\n messageId: \"directSecretsInIf\",\n node: ifPair.value as unknown as Rule.Node,\n });\n};\n\n/** Rule implementation for disallowing direct secret usage in `if` conditionals. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n const jobIfPair = getMappingPair(job.mapping, \"if\");\n const jobIfExpression = getScalarStringValue(\n jobIfPair?.value ?? null\n );\n\n if (\n jobIfPair !== null &&\n jobIfExpression !== null &&\n hasDirectSecretsReference(jobIfExpression)\n ) {\n reportDirectSecretsConditional(\n context,\n jobIfPair,\n `job '${job.id}'`\n );\n }\n\n const stepsSequence = getMappingValueAsSequence(\n job.mapping,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n continue;\n }\n\n for (const entry of stepsSequence.entries) {\n const stepMapping = unwrapYamlValue(entry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const stepIfPair = getMappingPair(stepMapping, \"if\");\n const stepIfExpression = getScalarStringValue(\n stepIfPair?.value ?? null\n );\n\n if (\n stepIfPair === null ||\n stepIfExpression === null ||\n !hasDirectSecretsReference(stepIfExpression)\n ) {\n continue;\n }\n\n reportDirectSecretsConditional(\n context,\n stepIfPair,\n `a step in job '${job.id}'`\n );\n }\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.security\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow direct `secrets.*` references in job and step `if` conditionals; move secret values into `env` first and condition on that instead.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R027\",\n ruleNumber: 27,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-secrets-in-if\",\n },\n messages: {\n directSecretsInIf:\n \"Do not reference `secrets` directly in {{scope}} `if` conditionals. Assign the secret to `env` first, then check the environment variable.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow self-hosted runners on fork-capable pull request events.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowEventNames,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Pull-request-adjacent events that can be invoked from forked PR activity. */\nconst forkPullRequestEventNames = [\n \"issue_comment\",\n \"pull_request\",\n \"pull_request_review\",\n \"pull_request_review_comment\",\n \"pull_request_target\",\n] as const;\n\n/** Fast lookup set for fork-capable pull request events. */\nconst forkPullRequestEventNameSet: ReadonlySet<string> = new Set(\n forkPullRequestEventNames\n);\n\n/** Determine whether a scalar string denotes the self-hosted runner label. */\nconst isSelfHostedRunnerLabel = (value: string): boolean =>\n value.trim().toLowerCase() === \"self-hosted\";\n\n/** Determine whether a runs-on node selects a self-hosted runner. */\nconst hasSelfHostedRunner = (\n node: null | Readonly<AST.YAMLContent | AST.YAMLWithMeta>\n): boolean => {\n const unwrappedNode = unwrapYamlValue(\n node as AST.YAMLContent | AST.YAMLWithMeta | null\n );\n\n if (unwrappedNode === null) {\n return false;\n }\n\n if (unwrappedNode.type === \"YAMLScalar\") {\n const value = getScalarStringValue(unwrappedNode);\n\n return value !== null && isSelfHostedRunnerLabel(value);\n }\n\n if (unwrappedNode.type === \"YAMLSequence\") {\n return unwrappedNode.entries.some((entry) => {\n const value = getScalarStringValue(entry);\n\n return value !== null && isSelfHostedRunnerLabel(value);\n });\n }\n\n if (unwrappedNode.type !== \"YAMLMapping\") {\n return false;\n }\n\n return hasSelfHostedRunner(\n getMappingPair(unwrappedNode, \"labels\")?.value ?? null\n );\n};\n\n/** Rule implementation for blocking self-hosted runners on fork PR events. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const triggeringForkPullRequestEvents = [\n ...getWorkflowEventNames(root),\n ]\n .filter((eventName) =>\n forkPullRequestEventNameSet.has(eventName)\n )\n .toSorted((left, right) => left.localeCompare(right));\n\n if (triggeringForkPullRequestEvents.length === 0) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n const runsOnPair = getMappingPair(job.mapping, \"runs-on\");\n\n if (\n runsOnPair === null ||\n !hasSelfHostedRunner(runsOnPair.value ?? null)\n ) {\n continue;\n }\n\n context.report({\n data: {\n events: triggeringForkPullRequestEvents.join(\", \"),\n jobId: job.id,\n },\n messageId: \"selfHostedRunnerOnForkPullRequestEvent\",\n node: (runsOnPair.value ??\n runsOnPair) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.security\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow self-hosted runners in workflows triggered by fork-capable pull-request events that can execute untrusted contributor activity.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R036\",\n ruleNumber: 36,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-self-hosted-runner-on-fork-pr-events\",\n },\n messages: {\n selfHostedRunnerOnForkPullRequestEvent:\n \"Job '{{jobId}}' uses a self-hosted runner in a workflow triggered by {{events}}, which can be invoked from forked or Dependabot pull requests. Prefer GitHub-hosted runners, or isolate the workload behind hardened ephemeral self-hosted infrastructure.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow workflow-template file patterns that target subdirectory paths.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowTemplatePropertiesFile } from \"../_internal/lint-targets.js\";\nimport {\n getWorkflowTemplateFilePatternEntries,\n getWorkflowTemplatePropertiesRoot,\n} from \"../_internal/workflow-template-properties.js\";\n\n/** Rule implementation for root-directory-oriented template file pattern checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowTemplatePropertiesRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const {\n node,\n value,\n } of getWorkflowTemplateFilePatternEntries(root)) {\n if (!value.includes(\"/\") && !value.includes(\"\\\\\")) {\n continue;\n }\n\n context.report({\n data: {\n pattern: value,\n },\n messageId: \"subdirectoryTemplateFilePattern\",\n node: node as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow workflow-template `filePatterns` that match subdirectory paths instead of repository-root files.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R062\",\n ruleNumber: 62,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-subdirectory-template-file-pattern\",\n },\n messages: {\n subdirectoryTemplateFilePattern:\n \"Template file pattern '{{pattern}}' targets subdirectory paths; workflow-template file patterns should match repository-root files.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow `$default-branch` placeholder usage outside workflow template files.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n isWorkflowTemplatePropertiesFile,\n isWorkflowTemplateYamlFile,\n} from \"../_internal/lint-targets.js\";\nimport { getWorkflowRoot } from \"../_internal/workflow-yaml.js\";\nimport { visitYamlStringScalars } from \"../_internal/yaml-traversal.js\";\n\n/** Placeholder token supported in template files. */\nconst defaultBranchPlaceholder = \"$default-branch\";\n\n/** Rule implementation for invalid placeholder usage outside templates. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (isWorkflowTemplateYamlFile(context.filename)) {\n return;\n }\n\n if (isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n visitYamlStringScalars(root, (node, value) => {\n if (!value.includes(defaultBranchPlaceholder)) {\n return;\n }\n\n context.report({\n messageId: \"templatePlaceholderOutsideTemplate\",\n node: node as unknown as Rule.Node,\n });\n });\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow `$default-branch` placeholder usage outside workflow template YAML files.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R069\",\n ruleNumber: 69,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-template-placeholder-in-non-template-workflow\",\n },\n messages: {\n templatePlaceholderOutsideTemplate:\n \"`$default-branch` is intended for workflow template files and should not be used in regular workflow YAML files.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow workflow-wide environment variables under the top-level `env` key.\n */\nimport type { Rule } from \"eslint\";\n\nimport { getMappingPair, getWorkflowRoot } from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for disallowing top-level workflow env. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const envPair = getMappingPair(root, \"env\");\n\n if (envPair !== null) {\n context.report({\n messageId: \"topLevelEnv\",\n node: envPair.key as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow top-level workflow `env` when you want environment variables scoped closer to the jobs and steps that use them.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R013\",\n ruleNumber: 13,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-top-level-env\",\n },\n messages: {\n topLevelEnv:\n \"Avoid top-level workflow `env`; prefer job-level or step-level `env` declarations instead.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow declaring workflow permissions at the top level.\n */\nimport type { Rule } from \"eslint\";\n\nimport { getMappingPair, getWorkflowRoot } from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for disallowing top-level workflow permissions. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const permissionsPair = getMappingPair(root, \"permissions\");\n\n if (permissionsPair !== null) {\n context.report({\n messageId: \"topLevelPermissions\",\n node: permissionsPair.key as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\"github-actions.configs.all\"],\n description:\n \"disallow top-level workflow `permissions` when you want every job to declare its own token scope explicitly.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R014\",\n ruleNumber: 14,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-top-level-permissions\",\n },\n messages: {\n topLevelPermissions:\n \"Avoid top-level workflow `permissions`; declare `permissions` on each job instead.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow universal catch-all regexes in template `filePatterns`.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowTemplatePropertiesFile } from \"../_internal/lint-targets.js\";\nimport {\n getWorkflowTemplateFilePatternEntries,\n getWorkflowTemplatePropertiesRoot,\n} from \"../_internal/workflow-template-properties.js\";\n\n/** Normalized regex strings treated as universal catch-all template patterns. */\nconst universalTemplateFilePatterns = new Set([\n \".*\",\n \".+\",\n \"^.*$\",\n \"^.+$\",\n]);\n\n/** Rule implementation for universal template file pattern checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowTemplatePropertiesRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const {\n node,\n value,\n } of getWorkflowTemplateFilePatternEntries(root)) {\n const normalizedPattern = value.trim();\n\n if (!universalTemplateFilePatterns.has(normalizedPattern)) {\n continue;\n }\n\n context.report({\n data: {\n pattern: value,\n },\n messageId: \"universalTemplateFilePattern\",\n node: node as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow universal catch-all regexes in workflow-template `filePatterns`.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R061\",\n ruleNumber: 61,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-universal-template-file-pattern\",\n },\n messages: {\n universalTemplateFilePattern:\n \"Template file pattern '{{pattern}}' is too broad and matches nearly every repository.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow references to undeclared inputs in composite action metadata.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isActionMetadataFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\nimport { visitYamlStringScalars } from \"../_internal/yaml-traversal.js\";\n\n/**\n * Pattern for extracting `inputs.<input_id>` references from expression-like\n * strings.\n */\nconst inputReferencePattern = /inputs\\.(?<inputId>[^\\s.\\]}]+)/g;\n\n/** Rule implementation for unknown composite input references. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isActionMetadataFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const runsMapping = getMappingValueAsMapping(root, \"runs\");\n\n if (runsMapping === null) {\n return;\n }\n\n const usingRuntime = getScalarStringValue(\n runsMapping.pairs.find(\n (pair) =>\n pair !== null &&\n getScalarStringValue(pair.key) === \"using\"\n )?.value\n );\n\n if (usingRuntime !== \"composite\") {\n return;\n }\n\n const inputsMapping = getMappingValueAsMapping(root, \"inputs\");\n const declaredInputIds = new Set<string>();\n\n if (inputsMapping !== null) {\n for (const pair of inputsMapping.pairs) {\n const inputId = getScalarStringValue(pair.key);\n\n if (inputId !== null) {\n declaredInputIds.add(inputId);\n }\n }\n }\n\n visitYamlStringScalars(runsMapping, (node, value) => {\n for (const match of value.matchAll(inputReferencePattern)) {\n const inputId = match.groups?.[\"inputId\"];\n\n if (\n inputId === undefined ||\n declaredInputIds.has(inputId)\n ) {\n continue;\n }\n\n context.report({\n data: {\n inputId,\n },\n messageId: \"unknownInputReference\",\n node: node as unknown as Rule.Node,\n });\n }\n });\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.actionMetadata\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow `inputs.<id>` references in composite action metadata when the input id is not declared.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R050\",\n ruleNumber: 50,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-unknown-input-reference-in-composite\",\n },\n messages: {\n unknownInputReference:\n \"Composite action references `inputs.{{inputId}}`, but that input is not declared in `inputs`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow references to undeclared job outputs.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/**\n * `needs.<job_id>.outputs.<output_name>` references inside workflow\n * expressions.\n */\nconst needsOutputReferencePattern =\n /needs\\.(?<neededJobId>[A-Z_a-z][\\w-]*)\\.outputs\\.(?<outputName>[A-Z_a-z][\\w-]*)/g;\n\n/**\n * `jobs.<job_id>.outputs.<output_name>` references inside reusable workflow\n * outputs.\n */\nconst jobsOutputReferencePattern =\n /jobs\\.(?<jobId>[A-Z_a-z][\\w-]*)\\.outputs\\.(?<outputName>[A-Z_a-z][\\w-]*)/g;\n\n/** Visit every string scalar reachable from a YAML value node. */\nconst visitStringScalars = (\n node: null | Readonly<AST.YAMLContent | AST.YAMLWithMeta>,\n visitor: (node: Readonly<AST.YAMLScalar>, value: string) => void\n): void => {\n const unwrappedNode = unwrapYamlValue(\n node as AST.YAMLContent | AST.YAMLWithMeta | null\n );\n\n if (unwrappedNode === null) {\n return;\n }\n\n if (unwrappedNode.type === \"YAMLScalar\") {\n const value = getScalarStringValue(unwrappedNode);\n\n if (value !== null) {\n visitor(unwrappedNode, value);\n }\n\n return;\n }\n\n if (unwrappedNode.type === \"YAMLSequence\") {\n for (const entry of unwrappedNode.entries) {\n visitStringScalars(entry, visitor);\n }\n\n return;\n }\n\n if (unwrappedNode.type !== \"YAMLMapping\") {\n return;\n }\n\n for (const pair of unwrappedNode.pairs) {\n visitStringScalars(pair.value ?? null, visitor);\n }\n};\n\n/** Collect declared output names from a job definition. */\nconst getDeclaredJobOutputNames = (\n jobMapping: Readonly<AST.YAMLMapping>\n): ReadonlySet<string> => {\n const outputsMapping = getMappingValueAsMapping(jobMapping, \"outputs\");\n const outputNames = new Set<string>();\n\n if (outputsMapping === null) {\n return outputNames;\n }\n\n for (const pair of outputsMapping.pairs) {\n const outputName = getScalarStringValue(pair.key);\n\n if (outputName !== null) {\n outputNames.add(outputName);\n }\n }\n\n return outputNames;\n};\n\n/** Collect the direct `needs` dependencies configured for a job. */\nconst getDirectNeedsJobIds = (\n jobMapping: Readonly<AST.YAMLMapping>\n): ReadonlySet<string> => {\n const needsPair = getMappingPair(jobMapping, \"needs\");\n const needsValue = unwrapYamlValue(needsPair?.value ?? null);\n const directNeeds = new Set<string>();\n\n if (needsValue === null) {\n return directNeeds;\n }\n\n if (needsValue.type === \"YAMLScalar\") {\n const jobId = getScalarStringValue(needsValue);\n\n if (jobId !== null) {\n directNeeds.add(jobId);\n }\n\n return directNeeds;\n }\n\n if (needsValue.type !== \"YAMLSequence\") {\n return directNeeds;\n }\n\n for (const entry of needsValue.entries) {\n const jobId = getScalarStringValue(entry);\n\n if (jobId !== null) {\n directNeeds.add(jobId);\n }\n }\n\n return directNeeds;\n};\n\n/** Rule implementation for validating job output references. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const jobs = getWorkflowJobs(root);\n const declaredOutputsByJobId = new Map(\n jobs.map((job) => [\n job.id,\n getDeclaredJobOutputNames(job.mapping),\n ])\n );\n\n const onMapping = getMappingValueAsMapping(root, \"on\");\n const workflowCallMapping =\n onMapping === null\n ? null\n : getMappingValueAsMapping(onMapping, \"workflow_call\");\n const workflowCallOutputsMapping =\n workflowCallMapping === null\n ? null\n : getMappingValueAsMapping(\n workflowCallMapping,\n \"outputs\"\n );\n\n if (workflowCallOutputsMapping !== null) {\n for (const pair of workflowCallOutputsMapping.pairs) {\n const reusableOutputName = getScalarStringValue(\n pair.key\n );\n const reusableOutputMapping = unwrapYamlValue(\n pair.value\n );\n\n if (\n reusableOutputName === null ||\n reusableOutputMapping?.type !== \"YAMLMapping\"\n ) {\n continue;\n }\n\n const valuePair = getMappingPair(\n reusableOutputMapping,\n \"value\"\n );\n\n visitStringScalars(\n valuePair?.value ?? null,\n (node, value) => {\n for (const match of value.matchAll(\n jobsOutputReferencePattern\n )) {\n const reference = match[0];\n const jobId = match.groups?.[\"jobId\"];\n const outputName =\n match.groups?.[\"outputName\"];\n\n if (\n jobId === undefined ||\n outputName === undefined\n ) {\n continue;\n }\n\n const declaredOutputNames =\n declaredOutputsByJobId.get(jobId);\n\n if (declaredOutputNames === undefined) {\n context.report({\n data: {\n jobId,\n reference,\n reusableOutputName,\n },\n messageId:\n \"unknownReusableWorkflowJob\",\n node: node as unknown as Rule.Node,\n });\n\n continue;\n }\n\n if (declaredOutputNames.has(outputName)) {\n continue;\n }\n\n context.report({\n data: {\n jobId,\n outputName,\n reference,\n reusableOutputName,\n },\n messageId:\n \"unknownReusableWorkflowJobOutput\",\n node: node as unknown as Rule.Node,\n });\n }\n }\n );\n }\n }\n\n for (const job of jobs) {\n const directNeedsJobIds = getDirectNeedsJobIds(job.mapping);\n\n visitStringScalars(job.mapping, (node, value) => {\n for (const match of value.matchAll(\n needsOutputReferencePattern\n )) {\n const reference = match[0];\n const neededJobId = match.groups?.[\"neededJobId\"];\n const outputName = match.groups?.[\"outputName\"];\n\n if (\n neededJobId === undefined ||\n outputName === undefined\n ) {\n continue;\n }\n\n const declaredOutputNames =\n declaredOutputsByJobId.get(neededJobId);\n\n if (declaredOutputNames === undefined) {\n context.report({\n data: {\n currentJobId: job.id,\n neededJobId,\n reference,\n },\n messageId: \"unknownNeedsJob\",\n node: node as unknown as Rule.Node,\n });\n\n continue;\n }\n\n if (!directNeedsJobIds.has(neededJobId)) {\n context.report({\n data: {\n currentJobId: job.id,\n neededJobId,\n reference,\n },\n messageId: \"missingNeedsDependency\",\n node: node as unknown as Rule.Node,\n });\n\n continue;\n }\n\n if (declaredOutputNames.has(outputName)) {\n continue;\n }\n\n context.report({\n data: {\n currentJobId: job.id,\n neededJobId,\n outputName,\n reference,\n },\n messageId: \"unknownNeedsOutput\",\n node: node as unknown as Rule.Node,\n });\n }\n });\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow `needs.*.outputs.*` and reusable-workflow `jobs.*.outputs.*` references that point at undeclared jobs or outputs.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R037\",\n ruleNumber: 37,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-unknown-job-output-reference\",\n },\n messages: {\n missingNeedsDependency:\n \"Job '{{currentJobId}}' references `{{reference}}`, but job '{{neededJobId}}' is not listed in that job's direct `needs` dependencies.\",\n unknownNeedsJob:\n \"Job '{{currentJobId}}' references `{{reference}}`, but job '{{neededJobId}}' is not declared in this workflow.\",\n unknownNeedsOutput:\n \"Job '{{currentJobId}}' references `{{reference}}`, but job '{{neededJobId}}' does not declare output '{{outputName}}' under `jobs.{{neededJobId}}.outputs`.\",\n unknownReusableWorkflowJob:\n \"Reusable workflow output '{{reusableOutputName}}' references `{{reference}}`, but job '{{jobId}}' is not declared in this workflow.\",\n unknownReusableWorkflowJobOutput:\n \"Reusable workflow output '{{reusableOutputName}}' references `{{reference}}`, but job '{{jobId}}' does not declare output '{{outputName}}' under `jobs.{{jobId}}.outputs`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow references to undefined or not-yet-available steps.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Step context references using property dereference syntax. */\nconst stepReferencePattern =\n /steps\\.(?<stepId>[A-Z_a-z][\\w-]*)\\.(?:outputs\\.[A-Z_a-z][\\w-]*|conclusion|outcome)/g;\n\n/**\n * Visit every string scalar in a job, tracking the current step index when\n * applicable.\n */\nconst visitJobStringScalars = (\n node: null | Readonly<AST.YAMLContent | AST.YAMLWithMeta>,\n visitor: (\n node: Readonly<AST.YAMLScalar>,\n value: string,\n currentStepIndex: null | number\n ) => void,\n currentStepIndex: null | number = null\n): void => {\n const unwrappedNode = unwrapYamlValue(\n node as AST.YAMLContent | AST.YAMLWithMeta | null\n );\n\n if (unwrappedNode === null) {\n return;\n }\n\n if (unwrappedNode.type === \"YAMLScalar\") {\n const value = getScalarStringValue(unwrappedNode);\n\n if (value !== null) {\n visitor(unwrappedNode, value, currentStepIndex);\n }\n\n return;\n }\n\n if (unwrappedNode.type === \"YAMLSequence\") {\n for (const entry of unwrappedNode.entries) {\n visitJobStringScalars(entry, visitor, currentStepIndex);\n }\n\n return;\n }\n\n if (unwrappedNode.type !== \"YAMLMapping\") {\n return;\n }\n\n const stepsSequence = getMappingValueAsSequence(unwrappedNode, \"steps\");\n\n if (stepsSequence !== null) {\n for (const [stepIndex, entry] of stepsSequence.entries.entries()) {\n visitJobStringScalars(entry, visitor, stepIndex);\n }\n }\n\n for (const pair of unwrappedNode.pairs) {\n if (getScalarStringValue(pair.key) === \"steps\") {\n continue;\n }\n\n visitJobStringScalars(pair.value ?? null, visitor, currentStepIndex);\n }\n};\n\n/** Collect the first declared index for each step id in a job. */\nconst getStepIndexById = (\n jobMapping: Readonly<AST.YAMLMapping>\n): ReadonlyMap<string, number> => {\n const stepsSequence = getMappingValueAsSequence(jobMapping, \"steps\");\n const stepIndexById = new Map<string, number>();\n\n if (stepsSequence === null) {\n return stepIndexById;\n }\n\n for (const [stepIndex, entry] of stepsSequence.entries.entries()) {\n const stepMapping = unwrapYamlValue(entry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const stepId = getScalarStringValue(\n getMappingPair(stepMapping, \"id\")?.value ?? null\n );\n\n if (stepId !== null && !stepIndexById.has(stepId)) {\n stepIndexById.set(stepId, stepIndex);\n }\n }\n\n return stepIndexById;\n};\n\n/** Rule implementation for validating step context references. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n const stepIndexById = getStepIndexById(job.mapping);\n\n visitJobStringScalars(\n job.mapping,\n (node, value, currentStepIndex) => {\n for (const match of value.matchAll(\n stepReferencePattern\n )) {\n const reference = match[0];\n const stepId = match.groups?.[\"stepId\"];\n\n if (stepId === undefined) {\n continue;\n }\n\n const referencedStepIndex =\n stepIndexById.get(stepId);\n\n if (referencedStepIndex === undefined) {\n context.report({\n data: {\n jobId: job.id,\n reference,\n stepId,\n },\n messageId: \"unknownStepReference\",\n node: node as unknown as Rule.Node,\n });\n\n continue;\n }\n\n if (\n currentStepIndex === null ||\n referencedStepIndex < currentStepIndex\n ) {\n continue;\n }\n\n context.report({\n data: {\n jobId: job.id,\n reference,\n stepId,\n },\n messageId:\n \"stepReferenceBeforeAvailability\",\n node: node as unknown as Rule.Node,\n });\n }\n }\n );\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow `steps.<id>.*` references that target a missing step id or a step that has not run yet.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R038\",\n ruleNumber: 38,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-unknown-step-reference\",\n },\n messages: {\n stepReferenceBeforeAvailability:\n \"Job '{{jobId}}' references `{{reference}}` before step '{{stepId}}' has run. The `steps` context only contains prior steps in the same job.\",\n unknownStepReference:\n \"Job '{{jobId}}' references `{{reference}}`, but no step with `id: {{stepId}}` exists in that job.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow directly interpolating untrusted event inputs inside `run` steps.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/**\n * Untrusted workflow-expression sources that should not be embedded directly in\n * `run`.\n */\nconst untrustedRunExpressionSources = [\n {\n fragments: [\n \"github.event.pull_request.body\",\n \"github.event.pull_request.title\",\n ],\n source: \"pull request title/body\",\n },\n {\n fragments: [\"github.event.issue.body\", \"github.event.issue.title\"],\n source: \"issue title/body\",\n },\n {\n fragments: [\"github.event.comment.body\"],\n source: \"comment body\",\n },\n {\n fragments: [\"github.event.review.body\"],\n source: \"review body\",\n },\n {\n fragments: [\n \"github.event.discussion.body\",\n \"github.event.discussion.title\",\n ],\n source: \"discussion title/body\",\n },\n {\n fragments: [\"github.event.discussion_comment.body\"],\n source: \"discussion comment body\",\n },\n {\n fragments: [\"github.event.client_payload.\"],\n source: \"repository_dispatch client payload\",\n },\n] as const;\n\n/** Resolve the first matching untrusted expression source inside a run script. */\nconst getUnsafeRunSource = (runScript: string): null | string => {\n for (const source of untrustedRunExpressionSources) {\n if (source.fragments.some((fragment) => runScript.includes(fragment))) {\n return source.source;\n }\n }\n\n return null;\n};\n\n/** Rule implementation for disallowing unsafe direct interpolation in `run`. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n const stepsSequence = getMappingValueAsSequence(\n job.mapping,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n continue;\n }\n\n for (const entry of stepsSequence.entries) {\n const stepMapping = unwrapYamlValue(entry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const runPair = getMappingPair(stepMapping, \"run\");\n const runScript = getScalarStringValue(\n runPair?.value ?? null\n );\n\n if (runPair === null || runScript === null) {\n continue;\n }\n\n const unsafeSource = getUnsafeRunSource(runScript);\n\n if (unsafeSource === null) {\n continue;\n }\n\n context.report({\n data: {\n jobId: job.id,\n source: unsafeSource,\n },\n messageId: \"unsafeRunInterpolation\",\n node: (runPair.value ??\n runPair) as unknown as Rule.Node,\n });\n }\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.security\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow directly embedding untrusted event payload values inside `run` scripts; move them through `env` first or pass them to an action input.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R029\",\n ruleNumber: 29,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-untrusted-input-in-run\",\n },\n messages: {\n unsafeRunInterpolation:\n \"Job '{{jobId}}' interpolates untrusted {{source}} directly inside `run`. Assign the value to `env` first or pass it to an action input.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow declared inputs that are never used in a composite action.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isActionMetadataFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\nimport { collectYamlStringScalars } from \"../_internal/yaml-traversal.js\";\n\n/** Matches `inputs.<id>` references in composite-step string values. */\nconst INPUT_REFERENCE_PATTERN = /inputs\\.(?<inputId>[\\w-]+)/gu;\n\n/** Rule implementation for unused composite input checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isActionMetadataFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const runsMapping = getMappingValueAsMapping(root, \"runs\");\n const inputsMapping = getMappingValueAsMapping(root, \"inputs\");\n\n if (runsMapping === null || inputsMapping === null) {\n return;\n }\n\n const usingRuntime = getScalarStringValue(\n getMappingPair(runsMapping, \"using\")?.value\n );\n\n if (usingRuntime !== \"composite\") {\n return;\n }\n\n const allScalarValues = collectYamlStringScalars(runsMapping);\n const referencedInputIds = new Set<string>();\n\n for (const scalarValue of allScalarValues) {\n for (const match of scalarValue.matchAll(\n INPUT_REFERENCE_PATTERN\n )) {\n const matchedInputId = match.groups?.[\"inputId\"];\n\n if (matchedInputId === undefined) {\n continue;\n }\n\n referencedInputIds.add(matchedInputId);\n }\n }\n\n for (const inputPair of inputsMapping.pairs) {\n const inputId = getScalarStringValue(inputPair.key);\n\n if (inputId === null) {\n continue;\n }\n\n if (referencedInputIds.has(inputId)) {\n continue;\n }\n\n context.report({\n data: {\n inputId,\n },\n messageId: \"unusedCompositeInput\",\n node: inputPair.key as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.actionMetadata\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow declared composite-action inputs that are never referenced.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R053\",\n ruleNumber: 53,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-unused-input-in-composite\",\n },\n messages: {\n unusedCompositeInput:\n \"Composite action input '{{inputId}}' is declared but never referenced via `inputs.{{inputId}}`.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow broad `write-all` GitHub token permissions.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Determine whether a permissions node is the broad `write-all` shortcut. */\nconst isWriteAllPermissionsValue = (\n permissionsPair: Readonly<AST.YAMLPair>\n): boolean =>\n getScalarStringValue(permissionsPair.value)?.trim().toLowerCase() ===\n \"write-all\";\n\n/** Rule implementation for disallowing `permissions: write-all`. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const reportWriteAll = (\n permissionsPair: Readonly<AST.YAMLPair>,\n scope: string\n ): void => {\n context.report({\n data: {\n scope,\n },\n messageId: \"writeAllPermissions\",\n node: permissionsPair.value as unknown as Rule.Node,\n });\n };\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const workflowPermissionsPair = getMappingPair(\n root,\n \"permissions\"\n );\n\n if (\n workflowPermissionsPair !== null &&\n isWriteAllPermissionsValue(workflowPermissionsPair)\n ) {\n reportWriteAll(\n workflowPermissionsPair,\n \"top-level workflow `permissions`\"\n );\n }\n\n for (const job of getWorkflowJobs(root)) {\n const jobPermissionsPair = getMappingPair(\n job.mapping,\n \"permissions\"\n );\n\n if (\n jobPermissionsPair !== null &&\n isWriteAllPermissionsValue(jobPermissionsPair)\n ) {\n reportWriteAll(\n jobPermissionsPair,\n `job '${job.id}' permissions`\n );\n }\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.security\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow `permissions: write-all` so workflows and jobs keep GitHub token scopes least-privileged.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R023\",\n ruleNumber: 23,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-write-all-permissions\",\n },\n messages: {\n writeAllPermissions:\n \"Avoid `write-all` in {{scope}}. Declare only the specific write scopes the workflow or job actually needs.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require immutable full-length SHA pins for third-party actions and reusable workflows.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Full commit SHA pattern recommended by GitHub for pinning action refs. */\nconst FULL_SHA_PATTERN = /^[0-9a-f]{40}$/u;\n\n/** Determine whether a `uses` reference is a local action path. */\nconst isLocalActionReference = (reference: string): boolean =>\n reference.startsWith(\"./\");\n\n/** Determine whether a `uses` reference is a Docker image reference. */\nconst isDockerReference = (reference: string): boolean =>\n reference.startsWith(\"docker://\");\n\n/** Determine whether a `uses` reference targets a reusable workflow. */\nconst isReusableWorkflowReference = (reference: string): boolean =>\n reference.includes(\"/.github/workflows/\");\n\n/** Extract the ref segment after the final `@` delimiter. */\nconst getReferenceRef = (reference: string): null | string => {\n const delimiterIndex = reference.lastIndexOf(\"@\");\n\n return delimiterIndex === -1 ? null : reference.slice(delimiterIndex + 1);\n};\n\n/** Determine whether a GitHub `uses` reference must be SHA pinned. */\nconst shouldValidateUsesReference = (reference: string): boolean =>\n !isLocalActionReference(reference) && !isDockerReference(reference);\n\n/**\n * Rule implementation for requiring immutable SHA pins on external uses\n * references.\n */\nconst rule: Rule.RuleModule = {\n create(context) {\n const reportReference = (\n node: Readonly<NonNullable<Rule.Node>>,\n reference: string\n ): void => {\n if (!shouldValidateUsesReference(reference)) {\n return;\n }\n\n const ref = getReferenceRef(reference);\n\n if (ref !== null && FULL_SHA_PATTERN.test(ref)) {\n return;\n }\n\n context.report({\n data: {\n ref: ref ?? \"<missing ref>\",\n reference,\n },\n messageId: isReusableWorkflowReference(reference)\n ? \"unpinnedReusableWorkflow\"\n : \"unpinnedAction\",\n node: node as Rule.Node,\n });\n };\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n const reusableWorkflowPair = getMappingPair(\n job.mapping,\n \"uses\"\n );\n const reusableWorkflowReference = getScalarStringValue(\n reusableWorkflowPair?.value ?? null\n );\n\n if (\n reusableWorkflowPair !== null &&\n reusableWorkflowReference !== null\n ) {\n reportReference(\n (reusableWorkflowPair.value ??\n reusableWorkflowPair) as unknown as Rule.Node,\n reusableWorkflowReference\n );\n }\n\n const stepsSequence = getMappingValueAsSequence(\n job.mapping,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n continue;\n }\n\n for (const entry of stepsSequence.entries) {\n const stepMapping = unwrapYamlValue(entry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const usesPair = getMappingPair(stepMapping, \"uses\");\n const usesReference = getScalarStringValue(\n usesPair?.value ?? null\n );\n\n if (usesPair === null || usesReference === null) {\n continue;\n }\n\n reportReference(\n (usesPair.value ??\n usesPair) as unknown as Rule.Node,\n usesReference\n );\n }\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.security\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require third-party `uses` references to pin full-length commit SHAs instead of mutable tags or branches.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R003\",\n ruleNumber: 3,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/pin-action-shas\",\n },\n messages: {\n unpinnedAction:\n \"Action reference '{{reference}}' should pin a full 40-character commit SHA instead of '{{ref}}'.\",\n unpinnedReusableWorkflow:\n \"Reusable workflow reference '{{reference}}' should pin a full 40-character commit SHA instead of '{{ref}}'.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Prefer `action.yml` over `action.yaml` for action metadata.\n */\nimport type { Rule } from \"eslint\";\n\n/** Rule implementation for preferring `action.yml`. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!context.filename.toLowerCase().endsWith(\"action.yaml\")) {\n return;\n }\n\n context.report({\n messageId: \"preferActionYml\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.actionMetadata\",\n \"github-actions.configs.all\",\n ],\n description:\n \"require action metadata files to prefer `action.yml` over `action.yaml`.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R043\",\n ruleNumber: 43,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/prefer-action-yml\",\n },\n messages: {\n preferActionYml:\n \"Prefer naming action metadata files `action.yml` instead of `action.yaml`.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Prefer matrix fail-fast behavior over explicitly disabling it.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n isGithubExpressionScalar,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for discouraging `strategy.fail-fast: false`. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n const strategyPair = getMappingPair(\n job.mapping,\n \"strategy\"\n );\n const strategyValue = unwrapYamlValue(\n strategyPair?.value ?? null\n );\n\n if (strategyValue?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const failFastPair = getMappingPair(\n strategyValue,\n \"fail-fast\"\n );\n\n if (\n failFastPair === null ||\n isGithubExpressionScalar(failFastPair.value)\n ) {\n continue;\n }\n\n const failFastValue = unwrapYamlValue(failFastPair.value);\n const failFastText = getScalarStringValue(\n failFastPair.value\n );\n\n if (\n failFastValue?.type === \"YAMLScalar\" &&\n (failFastValue.value === false ||\n failFastText === \"false\")\n ) {\n context.report({\n data: {\n jobId: job.id,\n },\n messageId: \"failFastDisabled\",\n node: (failFastPair.value ??\n failFastPair) as unknown as Rule.Node,\n });\n }\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow `strategy.fail-fast: false` so failing matrix jobs can stop redundant work sooner.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R015\",\n ruleNumber: 15,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/prefer-fail-fast\",\n },\n messages: {\n failFastDisabled:\n \"Job '{{jobId}}' disables `strategy.fail-fast`. Prefer `true` or a GitHub expression instead.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Enforce a consistent file extension for workflow files.\n */\nimport type { Rule } from \"eslint\";\n\nimport { extname } from \"node:path\";\n\n/** Supported workflow filename extensions. */\nconst workflowFileExtensions = [\"yaml\", \"yml\"] as const;\n\n/** Allowed workflow filename extension. */\ntype WorkflowFileExtension = (typeof workflowFileExtensions)[number];\n\n/** Object-style options for `prefer-file-extension`. */\ntype WorkflowFileExtensionOptionObject = {\n readonly caseSensitive?: boolean;\n readonly extension?: WorkflowFileExtension;\n};\n\n/** Rule options for `prefer-file-extension`. */\ntype WorkflowFileExtensionOptions = [\n (WorkflowFileExtension | WorkflowFileExtensionOptionObject)?,\n];\n\n/** Default workflow file extension. */\nconst DEFAULT_WORKFLOW_FILE_EXTENSION: WorkflowFileExtension = \"yml\";\n\n/** Normalize file extension options into a consistent runtime shape. */\nconst normalizePreferFileExtensionOptions = (\n option: Readonly<\n undefined | WorkflowFileExtension | WorkflowFileExtensionOptionObject\n >\n): {\n caseSensitive: boolean;\n extension: WorkflowFileExtension;\n} => {\n if (option === undefined || typeof option === \"string\") {\n return {\n caseSensitive: true,\n extension: option ?? DEFAULT_WORKFLOW_FILE_EXTENSION,\n };\n }\n\n return {\n caseSensitive: option.caseSensitive ?? true,\n extension: option.extension ?? DEFAULT_WORKFLOW_FILE_EXTENSION,\n };\n};\n\n/** Rule implementation for enforcing workflow file extensions. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const [option] = context.options as WorkflowFileExtensionOptions;\n const { caseSensitive, extension } =\n normalizePreferFileExtensionOptions(option ?? undefined);\n\n return {\n Program(node) {\n const actualExtensionWithDot = extname(context.filename);\n\n if (actualExtensionWithDot.length === 0) {\n return;\n }\n\n const actualExtension = actualExtensionWithDot.slice(1);\n\n if (actualExtension === undefined) {\n return;\n }\n\n const normalizedActualExtension = caseSensitive\n ? actualExtension\n : actualExtension.toLowerCase();\n const normalizedExpectedExtension = caseSensitive\n ? extension\n : extension.toLowerCase();\n\n if (normalizedActualExtension === normalizedExpectedExtension) {\n return;\n }\n\n context.report({\n data: {\n actual: `.${actualExtension}`,\n expected: `.${extension}`,\n },\n messageId: \"unexpectedExtension\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n defaultOptions: [DEFAULT_WORKFLOW_FILE_EXTENSION],\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"enforce a consistent file extension for GitHub Actions workflow files.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R020\",\n ruleNumber: 20,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/prefer-file-extension\",\n },\n messages: {\n unexpectedExtension:\n \"Expected workflow files to use the {{expected}} extension, but found {{actual}}.\",\n },\n schema: [\n {\n anyOf: [\n {\n description: \"Expected workflow filename extension.\",\n enum: workflowFileExtensions,\n type: \"string\",\n },\n {\n additionalProperties: false,\n description: \"Workflow filename extension options.\",\n properties: {\n caseSensitive: {\n description:\n \"Whether extension matching should preserve case.\",\n type: \"boolean\",\n },\n extension: {\n description:\n \"Expected workflow filename extension.\",\n enum: workflowFileExtensions,\n type: \"string\",\n },\n },\n type: \"object\",\n },\n ],\n description:\n \"Workflow filename extension preference, either as a simple extension string or an option object.\",\n },\n ],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Prefer the `inputs` context over `github.event.inputs` in manual workflows.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getScalarStringValue,\n getWorkflowEventNames,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Legacy workflow_dispatch inputs context prefix. */\nconst githubEventInputsPrefix = \"github.event.inputs.\";\n\n/** Preferred workflow_dispatch inputs context prefix. */\nconst inputsContextPrefix = \"inputs.\";\n\n/** Check whether a scalar string references the legacy inputs context. */\nconst hasGithubEventInputsReference = (value: string): boolean =>\n value.includes(githubEventInputsPrefix);\n\n/** Replace legacy workflow_dispatch inputs references with the preferred form. */\nconst replaceGithubEventInputsReferences = (value: string): string =>\n value.replaceAll(githubEventInputsPrefix, inputsContextPrefix);\n\n/** Visit every string scalar reachable from a YAML value node. */\nconst visitStringScalars = (\n node: null | Readonly<AST.YAMLContent | AST.YAMLWithMeta>,\n visitor: (node: Readonly<AST.YAMLScalar>, value: string) => void\n): void => {\n const unwrappedNode = unwrapYamlValue(\n node as AST.YAMLContent | AST.YAMLWithMeta | null\n );\n\n if (unwrappedNode === null) {\n return;\n }\n\n if (unwrappedNode.type === \"YAMLScalar\") {\n const value = getScalarStringValue(unwrappedNode);\n\n if (value !== null) {\n visitor(unwrappedNode, value);\n }\n\n return;\n }\n\n if (unwrappedNode.type === \"YAMLSequence\") {\n for (const entry of unwrappedNode.entries) {\n visitStringScalars(entry, visitor);\n }\n\n return;\n }\n\n if (unwrappedNode.type !== \"YAMLMapping\") {\n return;\n }\n\n for (const pair of unwrappedNode.pairs) {\n visitStringScalars(pair.value ?? null, visitor);\n }\n};\n\n/** Rule implementation for preferring the `inputs` context. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const eventNames = getWorkflowEventNames(root);\n\n if (!eventNames.has(\"workflow_dispatch\")) {\n return;\n }\n\n visitStringScalars(root, (node, value) => {\n if (!hasGithubEventInputsReference(value)) {\n return;\n }\n\n context.report({\n fix: (fixer) => {\n const originalText = context.sourceCode.text.slice(\n node.range[0],\n node.range[1]\n );\n const fixedText =\n replaceGithubEventInputsReferences(\n originalText\n );\n\n return originalText === fixedText\n ? null\n : fixer.replaceTextRange(node.range, fixedText);\n },\n messageId: \"preferInputsContext\",\n node: node as unknown as Rule.Node,\n });\n });\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"enforce the `inputs` context instead of `github.event.inputs` in `workflow_dispatch` workflows so boolean inputs preserve their native type semantics.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R033\",\n ruleNumber: 33,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/prefer-inputs-context\",\n },\n fixable: \"code\",\n messages: {\n preferInputsContext:\n \"Prefer `inputs.*` over `github.event.inputs.*` in `workflow_dispatch` workflows because the `inputs` context preserves booleans and is the documented shorthand.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Enforce a consistent style for step-level `uses:` references.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Supported `uses:` reference styles. */\nconst usesStyles = [\n \"branch\",\n \"commit\",\n \"release\",\n] as const;\n\n/** Object-style configuration for `prefer-step-uses-style`. */\ntype PreferStepUsesStyleObjectOption = Partial<\n Record<\"branch\" | \"commit\" | \"release\", boolean>\n> & {\n readonly allowDocker?: boolean;\n readonly allowRepository?: boolean;\n readonly ignores?: readonly string[];\n};\n\n/** String literal union of supported `uses:` styles. */\ntype StepUsesStyle = (typeof usesStyles)[number];\n\n/** Default `uses:` style enforced by the rule. */\nconst DEFAULT_STEP_USES_STYLE: StepUsesStyle = \"commit\";\n\n/** Normalize prefer-step-uses-style options into a consistent runtime shape. */\nconst normalizeStepUsesStyleOptions = (\n option: Readonly<\n PreferStepUsesStyleObjectOption | StepUsesStyle | undefined\n >\n): {\n allowDocker: boolean;\n allowedStyles: readonly StepUsesStyle[];\n allowRepository: boolean;\n ignoredReferences: readonly string[];\n} => {\n if (option === undefined || typeof option === \"string\") {\n return {\n allowDocker: false,\n allowedStyles: [option ?? DEFAULT_STEP_USES_STYLE],\n allowRepository: false,\n ignoredReferences: [],\n };\n }\n\n const allowedStyles = usesStyles.filter((style) => option[style] === true);\n\n return {\n allowDocker: option.allowDocker ?? false,\n allowedStyles:\n allowedStyles.length > 0\n ? allowedStyles\n : [DEFAULT_STEP_USES_STYLE],\n allowRepository: option.allowRepository ?? false,\n ignoredReferences: [...(option.ignores ?? [])],\n };\n};\n\n/** Parse a step-level `uses:` reference into its normalized style. */\nconst parseStepUsesReference = (\n reference: string\n): {\n isDocker: boolean;\n isRepository: boolean;\n style: StepUsesStyle;\n} => {\n if (reference.startsWith(\"./\")) {\n return {\n isDocker: false,\n isRepository: true,\n style: DEFAULT_STEP_USES_STYLE,\n };\n }\n\n if (reference.startsWith(\"docker://\")) {\n return {\n isDocker: true,\n isRepository: false,\n style: DEFAULT_STEP_USES_STYLE,\n };\n }\n\n const delimiterIndex = reference.lastIndexOf(\"@\");\n const ref =\n delimiterIndex === -1 ? \"\" : reference.slice(delimiterIndex + 1);\n\n let isReleaseStyle = ref.startsWith(\"v\") && ref.length > 1;\n\n if (isReleaseStyle) {\n for (const character of ref.slice(1)) {\n if (character !== \".\" && (character < \"0\" || character > \"9\")) {\n isReleaseStyle = false;\n break;\n }\n }\n }\n\n if (/^[0-9a-f]{40}$/u.test(ref)) {\n return {\n isDocker: false,\n isRepository: false,\n style: \"commit\",\n };\n }\n\n if (isReleaseStyle) {\n return {\n isDocker: false,\n isRepository: false,\n style: \"release\",\n };\n }\n\n return {\n isDocker: false,\n isRepository: false,\n style: \"branch\",\n };\n};\n\n/** Rule implementation for enforcing step-level `uses:` reference style. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const [option] = context.options as [\n (PreferStepUsesStyleObjectOption | StepUsesStyle)?,\n ];\n const {\n allowDocker,\n allowedStyles,\n allowRepository,\n ignoredReferences,\n } = normalizeStepUsesStyleOptions(option ?? undefined);\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n const stepsSequence = getMappingValueAsSequence(\n job.mapping,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n continue;\n }\n\n for (const entry of stepsSequence.entries) {\n const stepMapping = unwrapYamlValue(entry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const usesPair = getMappingPair(stepMapping, \"uses\");\n const usesReference = getScalarStringValue(\n usesPair?.value ?? null\n );\n\n if (usesPair === null || usesReference === null) {\n continue;\n }\n\n if (ignoredReferences.includes(usesReference)) {\n continue;\n }\n\n const parsedReference =\n parseStepUsesReference(usesReference);\n\n if (parsedReference.isRepository) {\n if (!allowRepository) {\n context.report({\n messageId: \"repositoryActionDisallowed\",\n node: (usesPair.value ??\n usesPair) as unknown as Rule.Node,\n });\n }\n\n continue;\n }\n\n if (parsedReference.isDocker) {\n if (!allowDocker) {\n context.report({\n messageId: \"dockerActionDisallowed\",\n node: (usesPair.value ??\n usesPair) as unknown as Rule.Node,\n });\n }\n\n continue;\n }\n\n if (!allowedStyles.includes(parsedReference.style)) {\n context.report({\n data: {\n style: parsedReference.style,\n },\n messageId: \"styleDisallowed\",\n node: (usesPair.value ??\n usesPair) as unknown as Rule.Node,\n });\n }\n }\n }\n },\n };\n },\n meta: {\n defaultOptions: [DEFAULT_STEP_USES_STYLE],\n docs: {\n configs: [\"github-actions.configs.all\"],\n description:\n \"enforce a consistent style for step-level `uses` references.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R016\",\n ruleNumber: 16,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/prefer-step-uses-style\",\n },\n messages: {\n dockerActionDisallowed:\n \"Docker-based `uses` references are disallowed by this rule configuration.\",\n repositoryActionDisallowed:\n \"Repository-local `uses` references are disallowed by this rule configuration.\",\n styleDisallowed:\n \"Step `uses` references with style '{{style}}' are disallowed by this rule configuration.\",\n },\n schema: [\n {\n anyOf: [\n {\n description:\n \"Single allowed style for step-level `uses` references.\",\n enum: usesStyles,\n type: \"string\",\n },\n {\n additionalProperties: false,\n description:\n \"Allowed styles and exceptions for step-level `uses` references.\",\n properties: {\n allowDocker: {\n description:\n \"Allow Docker-based step `uses` references such as docker://alpine:3.20.\",\n type: \"boolean\",\n },\n allowRepository: {\n description:\n \"Allow repository-local step `uses` references such as ./.github/actions/foo.\",\n type: \"boolean\",\n },\n branch: {\n description:\n \"Allow branch-style references such as @main.\",\n type: \"boolean\",\n },\n commit: {\n description:\n \"Allow full-commit-SHA references such as @0123...abcd.\",\n type: \"boolean\",\n },\n ignores: {\n description:\n \"Literal step `uses` references that should be ignored by this rule.\",\n items: {\n type: \"string\",\n },\n type: \"array\",\n uniqueItems: true,\n },\n release: {\n description:\n \"Allow release-style references such as @v4 or @v4.2.0.\",\n type: \"boolean\",\n },\n },\n type: \"object\",\n },\n ],\n description:\n \"Configure the allowed styles for step-level `uses` references.\",\n },\n ],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Prefer `.yml` over `.yaml` for workflow template YAML files.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n isWorkflowTemplateYamlFile,\n usesYamlExtension,\n} from \"../_internal/lint-targets.js\";\n\n/** Rule implementation for template YAML extension preference checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!isWorkflowTemplateYamlFile(context.filename)) {\n return;\n }\n\n if (!usesYamlExtension(context.filename)) {\n return;\n }\n\n context.report({\n messageId: \"preferTemplateYml\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"require workflow template files to prefer `.yml` over `.yaml`.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R066\",\n ruleNumber: 66,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/prefer-template-yml-extension\",\n },\n messages: {\n preferTemplateYml:\n \"Prefer `.yml` for workflow template files instead of `.yaml`.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require every workflow file to declare a human-readable top-level name.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring a string workflow name. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n context.report({\n messageId: \"missingName\",\n node: node as unknown as Rule.Node,\n });\n\n return;\n }\n\n const namePair = getMappingPair(root, \"name\");\n\n if (namePair === null) {\n context.report({\n messageId: \"missingName\",\n node: root as unknown as Rule.Node,\n });\n\n return;\n }\n\n const nameValue = getScalarStringValue(namePair.value);\n\n if (nameValue === null || nameValue.trim().length === 0) {\n context.report({\n messageId: \"invalidName\",\n node: (namePair.value ??\n namePair) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require a non-empty string workflow `name` so workflow runs stay readable in the GitHub Actions UI.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R005\",\n ruleNumber: 5,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-action-name\",\n },\n messages: {\n invalidName: \"Workflow `name` must be a non-empty string.\",\n missingName:\n \"Add a top-level workflow `name` so runs are identifiable in the GitHub Actions UI.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require every workflow file to declare a run-name string.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring a string workflow run-name. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n context.report({\n messageId: \"missingRunName\",\n node: node as unknown as Rule.Node,\n });\n\n return;\n }\n\n const runNamePair = getMappingPair(root, \"run-name\");\n\n if (runNamePair === null) {\n context.report({\n messageId: \"missingRunName\",\n node: root as unknown as Rule.Node,\n });\n\n return;\n }\n\n const runNameValue = getScalarStringValue(runNamePair.value);\n\n if (runNameValue === null || runNameValue.trim().length === 0) {\n context.report({\n messageId: \"invalidRunName\",\n node: (runNamePair.value ??\n runNamePair) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require a non-empty string workflow `run-name` when you want queued and in-progress runs to remain self-describing.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R006\",\n ruleNumber: 6,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-action-run-name\",\n },\n messages: {\n invalidRunName: \"Workflow `run-name` must be a non-empty string.\",\n missingRunName:\n \"Add a top-level workflow `run-name` so individual workflow runs are easier to distinguish.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require a checkout step before using repository-local actions.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Determine whether a step uses the checkout action. */\nconst isCheckoutActionReference = (reference: string): boolean =>\n reference.startsWith(\"actions/checkout@\");\n\n/** Determine whether a step uses a repository-local action path. */\nconst isLocalActionReference = (reference: string): boolean =>\n reference.startsWith(\"./\");\n\n/** Rule implementation for requiring checkout before local actions. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n const stepsSequence = getMappingValueAsSequence(\n job.mapping,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n continue;\n }\n\n let hasSeenCheckout = false;\n\n for (const entry of stepsSequence.entries) {\n const stepMapping = unwrapYamlValue(entry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const usesPair = getMappingPair(stepMapping, \"uses\");\n const usesReference = getScalarStringValue(\n usesPair?.value ?? null\n );\n\n if (usesPair === null || usesReference === null) {\n continue;\n }\n\n if (isCheckoutActionReference(usesReference)) {\n hasSeenCheckout = true;\n continue;\n }\n\n if (\n isLocalActionReference(usesReference) &&\n !hasSeenCheckout\n ) {\n context.report({\n data: {\n jobId: job.id,\n reference: usesReference,\n },\n messageId: \"missingCheckoutBeforeLocalAction\",\n node: (usesPair.value ??\n usesPair) as unknown as Rule.Node,\n });\n }\n }\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require an `actions/checkout` step before using repository-local step actions so local action paths resolve reliably.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R025\",\n ruleNumber: 25,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-checkout-before-local-action\",\n },\n messages: {\n missingCheckoutBeforeLocalAction:\n \"Job '{{jobId}}' uses local action '{{reference}}' before any `actions/checkout` step. Check out the repository first.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require `name` on composite action steps.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isActionMetadataFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring names on composite steps. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isActionMetadataFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n const runsMapping =\n root === null\n ? null\n : getMappingValueAsMapping(root, \"runs\");\n\n if (runsMapping === null) {\n return;\n }\n\n const usingRuntime = getScalarStringValue(\n getMappingPair(runsMapping, \"using\")?.value\n );\n\n if (usingRuntime !== \"composite\") {\n return;\n }\n\n const stepsSequence = getMappingValueAsSequence(\n runsMapping,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n return;\n }\n\n for (const [\n index,\n stepEntry,\n ] of stepsSequence.entries.entries()) {\n const stepMapping = unwrapYamlValue(stepEntry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const nameValue = getScalarStringValue(\n getMappingPair(stepMapping, \"name\")?.value\n );\n\n if (nameValue !== null && nameValue.trim().length > 0) {\n continue;\n }\n\n context.report({\n data: {\n index: String(index + 1),\n },\n messageId: \"missingCompositeStepName\",\n node: stepMapping as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.actionMetadata\",\n \"github-actions.configs.all\",\n ],\n description:\n \"require each composite action step to declare a descriptive `name`.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R052\",\n ruleNumber: 52,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-composite-step-name\",\n },\n messages: {\n missingCompositeStepName:\n \"Composite step #{{index}} should declare a non-empty `name` for readability and debugging.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require every GitHub Actions job to declare a string name.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring explicit job names. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const jobsMapping = getMappingValueAsMapping(root, \"jobs\");\n\n if (jobsMapping === null) {\n return;\n }\n\n for (const pair of jobsMapping.pairs) {\n const jobId = getScalarStringValue(pair.key) ?? \"<unknown>\";\n const jobValue = unwrapYamlValue(pair.value);\n\n if (jobValue?.type !== \"YAMLMapping\") {\n context.report({\n data: { jobId },\n messageId: \"missingJobName\",\n node: (pair.value ?? pair) as unknown as Rule.Node,\n });\n\n continue;\n }\n\n const namePair = getMappingPair(jobValue, \"name\");\n\n if (namePair === null) {\n context.report({\n data: { jobId },\n messageId: \"missingJobName\",\n node: pair.key as AST.YAMLNode as unknown as Rule.Node,\n });\n\n continue;\n }\n\n const nameValue = getScalarStringValue(namePair.value);\n\n if (nameValue === null || nameValue.trim().length === 0) {\n context.report({\n data: { jobId },\n messageId: \"invalidJobName\",\n node: (namePair.value ??\n namePair) as unknown as Rule.Node,\n });\n }\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require every workflow job to declare a non-empty string `name` for readable run summaries.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R007\",\n ruleNumber: 7,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-job-name\",\n },\n messages: {\n invalidJobName:\n \"Job '{{jobId}}' must set `name` to a non-empty string.\",\n missingJobName:\n \"Job '{{jobId}}' is missing a human-readable `name`.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require every workflow step to declare a string name.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring explicit job step names. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n const stepsSequence = getMappingValueAsSequence(\n job.mapping,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n continue;\n }\n\n for (const entry of stepsSequence.entries) {\n const stepMapping = unwrapYamlValue(entry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const namePair = getMappingPair(stepMapping, \"name\");\n\n if (namePair === null) {\n context.report({\n data: {\n jobId: job.id,\n },\n messageId: \"missingStepName\",\n node: stepMapping as unknown as Rule.Node,\n });\n\n continue;\n }\n\n const nameValue = getScalarStringValue(namePair.value);\n\n if (\n nameValue === null ||\n nameValue.trim().length === 0\n ) {\n context.report({\n data: {\n jobId: job.id,\n },\n messageId: \"invalidStepName\",\n node: (namePair.value ??\n namePair) as unknown as Rule.Node,\n });\n }\n }\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require every workflow step to declare a non-empty string `name` so job logs remain readable.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R008\",\n ruleNumber: 8,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-job-step-name\",\n },\n messages: {\n invalidStepName:\n \"A step in job '{{jobId}}' must set `name` to a non-empty string.\",\n missingStepName:\n \"A step in job '{{jobId}}' is missing a human-readable `name`.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require bounded job timeouts for GitHub Actions jobs.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getScalarNumberValue,\n getWorkflowJobs,\n getWorkflowRoot,\n isGithubExpressionScalar,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule options for `require-job-timeout-minutes`. */\ntype RequireJobTimeoutMinutesOptions = [\n {\n readonly maxMinutes?: number;\n }?,\n];\n\n/** Default upper bound used when validating workflow job timeouts. */\nconst DEFAULT_MAX_MINUTES = 60;\n\n/** Rule implementation for requiring bounded timeout-minutes on workflow jobs. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const [options] = context.options as RequireJobTimeoutMinutesOptions;\n const maxMinutes = options?.maxMinutes ?? DEFAULT_MAX_MINUTES;\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n if (getMappingPair(job.mapping, \"uses\") !== null) {\n continue;\n }\n\n const timeoutPair = getMappingPair(\n job.mapping,\n \"timeout-minutes\"\n );\n\n if (timeoutPair === null) {\n context.report({\n data: {\n jobId: job.id,\n },\n messageId: \"missingTimeout\",\n node: job.idNode,\n });\n\n continue;\n }\n\n if (isGithubExpressionScalar(timeoutPair.value)) {\n continue;\n }\n\n const timeoutMinutes = getScalarNumberValue(\n timeoutPair.value\n );\n\n if (\n timeoutMinutes === null ||\n !Number.isInteger(timeoutMinutes) ||\n timeoutMinutes <= 0\n ) {\n context.report({\n data: {\n jobId: job.id,\n },\n messageId: \"invalidTimeout\",\n node: timeoutPair.value ?? timeoutPair,\n });\n\n continue;\n }\n\n if (timeoutMinutes > maxMinutes) {\n context.report({\n data: {\n actualMinutes: String(timeoutMinutes),\n jobId: job.id,\n maxMinutes: String(maxMinutes),\n },\n messageId: \"timeoutTooLarge\",\n node: timeoutPair.value ?? timeoutPair,\n });\n }\n }\n },\n };\n },\n meta: {\n defaultOptions: [{}],\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require every non-reusable workflow job to define a bounded `timeout-minutes` value.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R002\",\n ruleNumber: 2,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-job-timeout-minutes\",\n },\n messages: {\n invalidTimeout:\n \"Job '{{jobId}}' has an invalid `timeout-minutes` value. Use a positive integer or a GitHub expression.\",\n missingTimeout:\n \"Job '{{jobId}}' is missing `timeout-minutes`. Add an explicit timeout to prevent hung runners from waiting indefinitely.\",\n timeoutTooLarge:\n \"Job '{{jobId}}' sets `timeout-minutes` to {{actualMinutes}}, which exceeds the configured maximum of {{maxMinutes}}.\",\n },\n schema: [\n {\n additionalProperties: false,\n description:\n \"Optional configuration for the maximum allowed job timeout in minutes.\",\n properties: {\n maxMinutes: {\n description:\n \"Maximum allowed timeout-minutes value for a non-reusable workflow job.\",\n minimum: 1,\n type: \"integer\",\n },\n },\n type: \"object\",\n },\n ],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require merge-queue-aware workflows to listen for merge_group.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Determine whether the workflow declares a specific trigger event. */\nconst hasTriggerEvent = (\n root: Readonly<AST.YAMLMapping>,\n eventName: string\n): boolean => {\n const onPair = getMappingPair(root, \"on\");\n const onValue = unwrapYamlValue(onPair?.value ?? null);\n\n if (onValue === null) {\n return false;\n }\n\n if (onValue.type === \"YAMLScalar\") {\n return getScalarStringValue(onValue) === eventName;\n }\n\n if (onValue.type === \"YAMLSequence\") {\n return onValue.entries.some(\n (entry) =>\n entry !== null && getScalarStringValue(entry) === eventName\n );\n }\n\n if (onValue.type !== \"YAMLMapping\") {\n return false;\n }\n\n return getMappingPair(onValue, eventName) !== null;\n};\n\n/** Rule implementation for requiring merge_group triggers. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null || !hasTriggerEvent(root, \"pull_request\")) {\n return;\n }\n\n if (hasTriggerEvent(root, \"merge_group\")) {\n return;\n }\n\n const onPair = getMappingPair(root, \"on\");\n const onValue = unwrapYamlValue(onPair?.value ?? null);\n\n if (onValue === null) {\n return;\n }\n\n context.report({\n messageId: \"missingMergeGroup\",\n node: onValue as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require pull-request validation workflows to include the `merge_group` trigger so required checks also run for merge queues.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R035\",\n ruleNumber: 35,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-merge-group-trigger\",\n },\n messages: {\n missingMergeGroup:\n \"Workflows that validate pull requests should also listen to `merge_group` so required status checks are reported when pull requests enter a merge queue.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require base-branch scoping for `pull_request_target` triggers.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Determine whether a branch filter node is meaningfully configured. */\nconst hasConfiguredBranchFilter = (\n node: null | Readonly<AST.YAMLPair> | undefined\n): boolean => {\n const valueNode = unwrapYamlValue(node?.value ?? null);\n\n if (valueNode === null) {\n return false;\n }\n\n if (valueNode.type === \"YAMLScalar\") {\n const value = getScalarStringValue(valueNode);\n\n return value !== null && value.trim().length > 0;\n }\n\n if (valueNode.type !== \"YAMLSequence\") {\n return false;\n }\n\n return valueNode.entries.some((entry) => {\n const value = getScalarStringValue(entry);\n\n return value !== null && value.trim().length > 0;\n });\n};\n\n/** Rule implementation for requiring `pull_request_target` branch filters. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const reportMissingBranchFilter = (\n node: Readonly<AST.YAMLNode>\n ): void => {\n context.report({\n messageId: \"missingBranchFilter\",\n node: node as unknown as Rule.Node,\n });\n };\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const onPair = getMappingPair(root, \"on\");\n const onValue = unwrapYamlValue(onPair?.value ?? null);\n\n if (onValue === null) {\n return;\n }\n\n if (onValue.type === \"YAMLScalar\") {\n if (\n getScalarStringValue(onValue) === \"pull_request_target\"\n ) {\n reportMissingBranchFilter(onValue);\n }\n\n return;\n }\n\n if (onValue.type === \"YAMLSequence\") {\n for (const entry of onValue.entries) {\n if (\n entry !== null &&\n getScalarStringValue(entry) ===\n \"pull_request_target\"\n ) {\n reportMissingBranchFilter(entry);\n }\n }\n\n return;\n }\n\n const onMapping = getMappingValueAsMapping(root, \"on\");\n\n if (onMapping === null) {\n return;\n }\n\n const pullRequestTargetPair = getMappingPair(\n onMapping,\n \"pull_request_target\"\n );\n const pullRequestTargetValue = unwrapYamlValue(\n pullRequestTargetPair?.value ?? null\n );\n\n if (pullRequestTargetPair === null) {\n return;\n }\n\n if (pullRequestTargetValue?.type !== \"YAMLMapping\") {\n reportMissingBranchFilter(\n (pullRequestTargetPair.value ??\n pullRequestTargetPair) as AST.YAMLNode\n );\n\n return;\n }\n\n const branchesPair = getMappingPair(\n pullRequestTargetValue,\n \"branches\"\n );\n const branchesIgnorePair = getMappingPair(\n pullRequestTargetValue,\n \"branches-ignore\"\n );\n\n if (\n hasConfiguredBranchFilter(branchesPair) ||\n hasConfiguredBranchFilter(branchesIgnorePair)\n ) {\n return;\n }\n\n reportMissingBranchFilter(pullRequestTargetValue);\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.security\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require `on.pull_request_target` triggers to scope target base branches with `branches` or `branches-ignore` so privileged workflows do not react to every branch by default.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R032\",\n ruleNumber: 32,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-pull-request-target-branches\",\n },\n messages: {\n missingBranchFilter:\n \"`on.pull_request_target` should declare a non-empty `branches` or `branches-ignore` filter to scope which base branches can trigger this privileged workflow.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require `run` steps to declare an explicit shell directly or through defaults.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Runtime status for a discovered shell declaration. */\ntype ShellDeclarationState = \"invalid\" | \"missing\" | \"valid\";\n\n/** Inspect a shell pair and determine whether it is usable. */\nconst getShellDeclarationState = (\n shellPair: null | Readonly<AST.YAMLPair>\n): ShellDeclarationState => {\n if (shellPair === null) {\n return \"missing\";\n }\n\n const shellValue = getScalarStringValue(shellPair.value);\n\n return shellValue !== null && shellValue.trim().length > 0\n ? \"valid\"\n : \"invalid\";\n};\n\n/** Resolve `defaults.run.shell` from a mapping when present. */\nconst getRunDefaultsShellPair = (\n mapping: Readonly<AST.YAMLMapping>\n): AST.YAMLPair | null => {\n const defaultsMapping = getMappingValueAsMapping(mapping, \"defaults\");\n\n if (defaultsMapping === null) {\n return null;\n }\n\n const runDefaultsMapping = getMappingValueAsMapping(defaultsMapping, \"run\");\n\n return runDefaultsMapping === null\n ? null\n : getMappingPair(runDefaultsMapping, \"shell\");\n};\n\n/** Rule implementation for requiring explicit shells on run steps. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const reportInvalidShell = (\n shellPair: Readonly<AST.YAMLPair>,\n scope: string\n ): void => {\n context.report({\n data: {\n scope,\n },\n messageId: \"invalidShell\",\n node: (shellPair.value ?? shellPair) as unknown as Rule.Node,\n });\n };\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const workflowShellPair = getRunDefaultsShellPair(root);\n const workflowShellState =\n getShellDeclarationState(workflowShellPair);\n\n if (\n workflowShellPair !== null &&\n workflowShellState === \"invalid\"\n ) {\n reportInvalidShell(\n workflowShellPair,\n \"workflow `defaults.run.shell`\"\n );\n }\n\n for (const job of getWorkflowJobs(root)) {\n const jobShellPair = getRunDefaultsShellPair(job.mapping);\n const jobShellState =\n getShellDeclarationState(jobShellPair);\n\n if (jobShellPair !== null && jobShellState === \"invalid\") {\n reportInvalidShell(\n jobShellPair,\n `job '${job.id}' defaults.run.shell`\n );\n }\n\n const stepsSequence = getMappingValueAsSequence(\n job.mapping,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n continue;\n }\n\n for (const entry of stepsSequence.entries) {\n const stepMapping = unwrapYamlValue(entry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const runPair = getMappingPair(stepMapping, \"run\");\n\n if (runPair === null) {\n continue;\n }\n\n const stepShellPair = getMappingPair(\n stepMapping,\n \"shell\"\n );\n const stepShellState =\n getShellDeclarationState(stepShellPair);\n\n if (stepShellPair !== null) {\n if (stepShellState === \"valid\") {\n continue;\n }\n\n reportInvalidShell(\n stepShellPair,\n `a run step in job '${job.id}'`\n );\n\n continue;\n }\n\n if (\n jobShellState !== \"missing\" ||\n workflowShellState !== \"missing\"\n ) {\n continue;\n }\n\n context.report({\n data: {\n jobId: job.id,\n },\n messageId: \"missingShell\",\n node: (runPair.value ??\n stepMapping) as unknown as Rule.Node,\n });\n }\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require `run` steps to use an explicit shell directly or through `defaults.run.shell` so execution behavior stays predictable across runners.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R021\",\n ruleNumber: 21,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-run-step-shell\",\n },\n messages: {\n invalidShell:\n \"{{scope}} must set `shell` to a non-empty string when declared.\",\n missingShell:\n \"A `run` step in job '{{jobId}}' should declare `shell` explicitly or inherit it from `defaults.run.shell`.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require `categories` in workflow-template properties metadata.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowTemplatePropertiesFile } from \"../_internal/lint-targets.js\";\nimport {\n getWorkflowTemplatePropertiesRoot,\n getWorkflowTemplateStringProperty,\n} from \"../_internal/workflow-template-properties.js\";\nimport { getMappingValueAsSequence } from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring template categories. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowTemplatePropertiesRoot(context);\n\n if (root === null) {\n return;\n }\n\n const categoriesSequence = getMappingValueAsSequence(\n root,\n \"categories\"\n );\n\n if (\n categoriesSequence !== null &&\n categoriesSequence.entries.length > 0\n ) {\n return;\n }\n\n const templateName =\n getWorkflowTemplateStringProperty(root, \"name\") ??\n \"<unnamed-template>\";\n\n context.report({\n data: {\n templateName,\n },\n messageId: \"missingCategories\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"require non-empty `categories` in workflow-template metadata.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R057\",\n ruleNumber: 57,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-template-categories\",\n },\n messages: {\n missingCategories:\n \"Workflow template '{{templateName}}' should declare at least one category in `categories`.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require `filePatterns` in workflow-template properties metadata.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowTemplatePropertiesFile } from \"../_internal/lint-targets.js\";\nimport {\n getWorkflowTemplatePropertiesRoot,\n getWorkflowTemplateStringProperty,\n} from \"../_internal/workflow-template-properties.js\";\nimport { getMappingValueAsSequence } from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring non-empty template file patterns. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowTemplatePropertiesRoot(context);\n\n if (root === null) {\n return;\n }\n\n const filePatternsSequence = getMappingValueAsSequence(\n root,\n \"filePatterns\"\n );\n\n if (\n filePatternsSequence !== null &&\n filePatternsSequence.entries.length > 0\n ) {\n return;\n }\n\n const templateName =\n getWorkflowTemplateStringProperty(root, \"name\") ??\n \"<unnamed-template>\";\n\n context.report({\n data: {\n templateName,\n },\n messageId: \"missingFilePatterns\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"require non-empty `filePatterns` in workflow-template metadata.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R058\",\n ruleNumber: 58,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-template-file-patterns\",\n },\n messages: {\n missingFilePatterns:\n \"Workflow template '{{templateName}}' should declare `filePatterns` to improve chooser relevance.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require local workflow-template icon files referenced by `iconName` to exist.\n */\nimport type { Rule } from \"eslint\";\n\nimport { existsSync } from \"node:fs\";\nimport { dirname, join } from \"node:path\";\n\nimport { isWorkflowTemplatePropertiesFile } from \"../_internal/lint-targets.js\";\nimport {\n getWorkflowTemplatePropertiesRoot,\n getWorkflowTemplateStringProperty,\n} from \"../_internal/workflow-template-properties.js\";\n\n/** Rule implementation for template icon file existence checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowTemplatePropertiesRoot(context);\n\n if (root === null) {\n return;\n }\n\n const iconName = getWorkflowTemplateStringProperty(\n root,\n \"iconName\"\n );\n\n if (iconName === null || iconName.trim().length === 0) {\n return;\n }\n\n if (iconName.startsWith(\"octicon \")) {\n return;\n }\n\n const iconFilePath = join(\n dirname(context.filename),\n `${iconName}.svg`\n );\n\n if (existsSync(iconFilePath)) {\n return;\n }\n\n context.report({\n data: {\n iconFilePath,\n iconName,\n },\n messageId: \"missingTemplateIconFile\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"require local `iconName` references in workflow-template metadata to point to existing SVG files.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R065\",\n ruleNumber: 65,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-template-icon-file-exists\",\n },\n messages: {\n missingTemplateIconFile:\n \"Template `iconName` '{{iconName}}' should resolve to an existing icon file at '{{iconFilePath}}'.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require `iconName` in workflow-template properties.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowTemplatePropertiesFile } from \"../_internal/lint-targets.js\";\nimport {\n getWorkflowTemplatePropertiesRoot,\n getWorkflowTemplateStringProperty,\n} from \"../_internal/workflow-template-properties.js\";\n\n/** Rule implementation for requiring `iconName` in template properties metadata. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowTemplatePropertiesRoot(context);\n\n if (root === null) {\n return;\n }\n\n const iconName = getWorkflowTemplateStringProperty(\n root,\n \"iconName\"\n );\n\n if (iconName !== null && iconName.trim().length > 0) {\n return;\n }\n\n context.report({\n messageId: \"missingIconName\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"require `iconName` in workflow-template `.properties.json` metadata.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R056\",\n ruleNumber: 56,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-template-icon-name\",\n },\n messages: {\n missingIconName:\n \"Workflow template metadata should define a non-empty `iconName`.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require template workflow YAML files to declare a non-empty top-level `name`.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowTemplateYamlFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring workflow names in template YAML files. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!isWorkflowTemplateYamlFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const namePair = getMappingPair(root, \"name\");\n const workflowName = getScalarStringValue(namePair?.value);\n\n if (workflowName !== null && workflowName.trim().length > 0) {\n return;\n }\n\n context.report({\n messageId: \"missingTemplateWorkflowName\",\n node: (namePair ?? node) as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"require workflow template YAML files to declare a non-empty top-level `name`.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R067\",\n ruleNumber: 67,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-template-workflow-name\",\n },\n messages: {\n missingTemplateWorkflowName:\n \"Workflow template files should declare a non-empty top-level `name`.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require explicit activity `types` for selected multi-activity workflow events.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Events where explicit `types` improve trigger precision. */\nconst eventsRequiringTypes = new Set<string>([\n \"branch_protection_rule\",\n \"check_run\",\n \"check_suite\",\n \"discussion\",\n \"discussion_comment\",\n \"issue_comment\",\n \"issues\",\n \"label\",\n \"merge_group\",\n \"milestone\",\n \"pull_request_review\",\n \"pull_request_review_comment\",\n \"registry_package\",\n \"release\",\n \"repository_dispatch\",\n \"watch\",\n \"workflow_run\",\n]);\n\n/** Determine whether an event `types` node is meaningfully configured. */\nconst hasConfiguredTypes = (\n node: null | Readonly<AST.YAMLPair> | undefined\n): boolean => {\n const valueNode = unwrapYamlValue(node?.value ?? null);\n\n if (valueNode === null) {\n return false;\n }\n\n if (valueNode.type === \"YAMLScalar\") {\n const value = getScalarStringValue(valueNode);\n\n return value !== null && value.trim().length > 0;\n }\n\n if (valueNode.type !== \"YAMLSequence\") {\n return false;\n }\n\n return valueNode.entries.some((entry) => {\n const value = getScalarStringValue(entry);\n\n return value !== null && value.trim().length > 0;\n });\n};\n\n/** Rule implementation for requiring explicit event activity types. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const reportMissingTypes = (\n node: Readonly<AST.YAMLNode>,\n eventName: string\n ): void => {\n context.report({\n data: {\n event: eventName,\n },\n messageId: \"missingTypes\",\n node: node as unknown as Rule.Node,\n });\n };\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const onPair = getMappingPair(root, \"on\");\n const onValue = unwrapYamlValue(onPair?.value ?? null);\n\n if (onValue === null) {\n return;\n }\n\n if (onValue.type === \"YAMLScalar\") {\n const eventName = getScalarStringValue(onValue);\n\n if (\n eventName !== null &&\n eventsRequiringTypes.has(eventName)\n ) {\n reportMissingTypes(onValue, eventName);\n }\n\n return;\n }\n\n if (onValue.type === \"YAMLSequence\") {\n for (const entry of onValue.entries) {\n const eventName = getScalarStringValue(entry);\n\n if (\n entry !== null &&\n eventName !== null &&\n eventsRequiringTypes.has(eventName)\n ) {\n reportMissingTypes(entry, eventName);\n }\n }\n\n return;\n }\n\n const onMapping = getMappingValueAsMapping(root, \"on\");\n\n if (onMapping === null) {\n return;\n }\n\n for (const pair of onMapping.pairs) {\n const eventName = getScalarStringValue(pair.key);\n\n if (\n eventName === null ||\n !eventsRequiringTypes.has(eventName)\n ) {\n continue;\n }\n\n const eventValue = unwrapYamlValue(pair.value);\n\n if (eventValue?.type !== \"YAMLMapping\") {\n reportMissingTypes(\n (pair.value ?? pair.key) as AST.YAMLNode,\n eventName\n );\n\n continue;\n }\n\n if (\n hasConfiguredTypes(getMappingPair(eventValue, \"types\"))\n ) {\n continue;\n }\n\n reportMissingTypes(eventValue, eventName);\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require explicit `types` filters for selected multi-activity workflow events so workflows do not subscribe to every supported activity implicitly.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R031\",\n ruleNumber: 31,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-trigger-types\",\n },\n messages: {\n missingTypes:\n \"`on.{{event}}` should declare a non-empty `types` filter so the workflow is scoped to explicit activity types.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require explicit types for reusable workflow inputs.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Allowed GitHub reusable workflow input types. */\nconst allowedWorkflowCallInputTypes = [\n \"boolean\",\n \"number\",\n \"string\",\n] as const;\n\n/** Constant-time lookup for supported reusable workflow input types. */\nconst allowedWorkflowCallInputTypeSet: ReadonlySet<string> = new Set(\n allowedWorkflowCallInputTypes\n);\n\n/** Rule implementation for requiring explicit workflow_call input types. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const onMapping = getMappingValueAsMapping(root, \"on\");\n\n if (onMapping === null) {\n return;\n }\n\n const workflowCallMapping = unwrapYamlValue(\n getMappingPair(onMapping, \"workflow_call\")?.value ?? null\n );\n\n if (workflowCallMapping?.type !== \"YAMLMapping\") {\n return;\n }\n\n const inputsMapping = getMappingValueAsMapping(\n workflowCallMapping,\n \"inputs\"\n );\n\n if (inputsMapping === null) {\n return;\n }\n\n for (const pair of inputsMapping.pairs) {\n const inputId = getScalarStringValue(pair.key);\n const inputMapping = unwrapYamlValue(pair.value);\n\n if (\n inputId === null ||\n inputMapping?.type !== \"YAMLMapping\"\n ) {\n continue;\n }\n\n const typePair = getMappingPair(inputMapping, \"type\");\n\n if (typePair === null) {\n context.report({\n data: {\n inputId,\n },\n messageId: \"missingType\",\n node: pair.key as unknown as Rule.Node,\n });\n\n continue;\n }\n\n const typeValue = getScalarStringValue(typePair.value);\n\n if (\n typeValue === null ||\n !allowedWorkflowCallInputTypeSet.has(typeValue)\n ) {\n context.report({\n data: {\n allowedTypes:\n allowedWorkflowCallInputTypes.join(\", \"),\n inputId,\n },\n messageId: \"invalidType\",\n node: (typePair.value ??\n typePair) as unknown as Rule.Node,\n });\n }\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require every `workflow_call` input to declare one of the documented reusable-workflow input types so callers and validators agree on interface semantics.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R034\",\n ruleNumber: 34,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-workflow-call-input-type\",\n },\n messages: {\n invalidType:\n \"`workflow_call` input '{{inputId}}' must set `type` to one of: {{allowedTypes}}.\",\n missingType:\n \"`workflow_call` input '{{inputId}}' should declare `type` explicitly.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require reusable workflow outputs to declare a non-empty `value`.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring explicit reusable-workflow output values. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const onMapping = getMappingValueAsMapping(root, \"on\");\n\n if (onMapping === null) {\n return;\n }\n\n const workflowCallMapping = unwrapYamlValue(\n getMappingPair(onMapping, \"workflow_call\")?.value ?? null\n );\n\n if (workflowCallMapping?.type !== \"YAMLMapping\") {\n return;\n }\n\n const outputsMapping = getMappingValueAsMapping(\n workflowCallMapping,\n \"outputs\"\n );\n\n if (outputsMapping === null) {\n return;\n }\n\n for (const pair of outputsMapping.pairs) {\n const outputId = getScalarStringValue(pair.key);\n const outputMapping = unwrapYamlValue(pair.value);\n\n if (\n outputId === null ||\n outputMapping?.type !== \"YAMLMapping\"\n ) {\n continue;\n }\n\n const valuePair = getMappingPair(outputMapping, \"value\");\n\n if (valuePair === null) {\n context.report({\n data: {\n outputId,\n },\n messageId: \"missingValue\",\n node: pair.key as unknown as Rule.Node,\n });\n\n continue;\n }\n\n const value = getScalarStringValue(valuePair.value);\n\n if (value === null || value.trim().length === 0) {\n context.report({\n data: {\n outputId,\n },\n messageId: \"invalidValue\",\n node: (valuePair.value ??\n valuePair) as unknown as Rule.Node,\n });\n }\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require every `workflow_call` output to declare a non-empty `value` so reusable workflows expose concrete runtime output mappings.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R039\",\n ruleNumber: 39,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-workflow-call-output-value\",\n },\n messages: {\n invalidValue:\n \"`workflow_call` output '{{outputId}}' must set `value` to a non-empty scalar expression.\",\n missingValue:\n \"`workflow_call` output '{{outputId}}' should declare `value` explicitly.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require top-level workflow concurrency controls for relevant workflow triggers.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowEventNames,\n getWorkflowRoot,\n isGithubExpressionScalar,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Default event set that most benefits from workflow-level concurrency. */\nconst DEFAULT_TRIGGER_EVENTS = [\n \"merge_group\",\n \"pull_request\",\n \"pull_request_target\",\n \"push\",\n \"workflow_dispatch\",\n] as const;\n\n/** Rule options for `require-workflow-concurrency`. */\ntype RequireWorkflowConcurrencyOptions = [\n {\n readonly onlyForEvents?: readonly string[];\n readonly requireCancelInProgress?: boolean;\n }?,\n];\n\n/** Rule implementation for requiring workflow-level concurrency controls. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const [options] = context.options as RequireWorkflowConcurrencyOptions;\n const requiredTriggerEvents = new Set<string>(\n options?.onlyForEvents ?? DEFAULT_TRIGGER_EVENTS\n );\n const requireCancelInProgress =\n options?.requireCancelInProgress ?? true;\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const eventNames = getWorkflowEventNames(root);\n const shouldRequireConcurrency = [\n ...requiredTriggerEvents,\n ].some((eventName) => eventNames.has(eventName));\n\n if (!shouldRequireConcurrency) {\n return;\n }\n\n const concurrencyPair = getMappingPair(root, \"concurrency\");\n\n if (concurrencyPair === null) {\n context.report({\n messageId: \"missingConcurrency\",\n node: root,\n });\n\n return;\n }\n\n const concurrencyValue = unwrapYamlValue(concurrencyPair.value);\n\n if (concurrencyValue === null) {\n context.report({\n messageId: \"invalidConcurrency\",\n node: concurrencyPair,\n });\n\n return;\n }\n\n if (concurrencyValue.type === \"YAMLScalar\") {\n const groupValue = getScalarStringValue(concurrencyValue);\n\n if (groupValue === null || groupValue.trim().length === 0) {\n context.report({\n messageId: \"invalidConcurrency\",\n node: concurrencyValue,\n });\n }\n\n return;\n }\n\n if (concurrencyValue.type !== \"YAMLMapping\") {\n context.report({\n messageId: \"invalidConcurrency\",\n node: concurrencyValue,\n });\n\n return;\n }\n\n const groupPair = getMappingPair(concurrencyValue, \"group\");\n const groupValue = getScalarStringValue(\n groupPair?.value ?? null\n );\n\n if (\n groupPair === null ||\n groupValue === null ||\n groupValue.trim() === \"\"\n ) {\n context.report({\n messageId: \"missingGroup\",\n node: groupPair?.key ?? concurrencyValue,\n });\n }\n\n if (!requireCancelInProgress) {\n return;\n }\n\n const cancelInProgressPair = getMappingPair(\n concurrencyValue,\n \"cancel-in-progress\"\n );\n\n if (cancelInProgressPair === null) {\n context.report({\n messageId: \"missingCancelInProgress\",\n node: concurrencyValue,\n });\n\n return;\n }\n\n if (isGithubExpressionScalar(cancelInProgressPair.value)) {\n return;\n }\n\n if (\n unwrapYamlValue(cancelInProgressPair.value)?.type !==\n \"YAMLScalar\"\n ) {\n context.report({\n messageId: \"cancelInProgressDisabled\",\n node:\n cancelInProgressPair.value ?? cancelInProgressPair,\n });\n\n return;\n }\n\n if (cancelInProgressPair.value?.type !== \"YAMLScalar\") {\n context.report({\n messageId: \"cancelInProgressDisabled\",\n node:\n cancelInProgressPair.value ?? cancelInProgressPair,\n });\n\n return;\n }\n\n if (cancelInProgressPair.value.value !== true) {\n context.report({\n messageId: \"cancelInProgressDisabled\",\n node: cancelInProgressPair.value,\n });\n }\n },\n };\n },\n meta: {\n defaultOptions: [{}],\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require workflow-level `concurrency` so redundant runs can be deduplicated predictably.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R004\",\n ruleNumber: 4,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-workflow-concurrency\",\n },\n messages: {\n cancelInProgressDisabled:\n \"Workflow `concurrency.cancel-in-progress` should be `true` or a GitHub expression so stale runs can be cancelled.\",\n invalidConcurrency:\n \"Workflow `concurrency` should be a string/expression or an object containing at least `group`.\",\n missingCancelInProgress:\n \"Workflow `concurrency` should set `cancel-in-progress` to cancel superseded runs.\",\n missingConcurrency:\n \"Add a top-level `concurrency` block so overlapping workflow runs do not pile up.\",\n missingGroup:\n \"Workflow `concurrency` should declare a non-empty `group` value.\",\n },\n schema: [\n {\n additionalProperties: false,\n description:\n \"Optional configuration for which events require workflow-level concurrency and whether cancel-in-progress is mandatory.\",\n properties: {\n onlyForEvents: {\n description:\n \"Event names that should trigger the workflow-level concurrency requirement.\",\n items: {\n minLength: 1,\n type: \"string\",\n },\n type: \"array\",\n uniqueItems: true,\n },\n requireCancelInProgress: {\n description:\n \"Require concurrency.cancel-in-progress so newer runs can cancel superseded work.\",\n type: \"boolean\",\n },\n },\n type: \"object\",\n },\n ],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require explicit types for `workflow_dispatch` inputs.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring explicit workflow_dispatch input types. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const onMapping = getMappingValueAsMapping(root, \"on\");\n\n if (onMapping === null) {\n return;\n }\n\n const workflowDispatchMapping = unwrapYamlValue(\n getMappingPair(onMapping, \"workflow_dispatch\")?.value ??\n null\n );\n\n if (workflowDispatchMapping?.type !== \"YAMLMapping\") {\n return;\n }\n\n const inputsMapping = getMappingValueAsMapping(\n workflowDispatchMapping,\n \"inputs\"\n );\n\n if (inputsMapping === null) {\n return;\n }\n\n for (const pair of inputsMapping.pairs) {\n const inputId = getScalarStringValue(pair.key);\n const inputMapping = unwrapYamlValue(pair.value);\n\n if (\n inputId === null ||\n inputMapping?.type !== \"YAMLMapping\"\n ) {\n continue;\n }\n\n const typePair = getMappingPair(inputMapping, \"type\");\n\n if (typePair === null) {\n context.report({\n data: {\n inputId,\n },\n messageId: \"missingType\",\n node: pair.key as unknown as Rule.Node,\n });\n\n continue;\n }\n\n const typeValue = getScalarStringValue(typePair.value);\n\n if (typeValue === null || typeValue.trim().length === 0) {\n context.report({\n data: {\n inputId,\n },\n messageId: \"invalidType\",\n node: (typePair.value ??\n typePair) as unknown as Rule.Node,\n });\n }\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require every `workflow_dispatch` input to declare an explicit `type` so manual runs expose clearer controls and preserve intended value semantics.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R022\",\n ruleNumber: 22,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-workflow-dispatch-input-type\",\n },\n messages: {\n invalidType:\n \"`workflow_dispatch` input '{{inputId}}' must set `type` to a non-empty string.\",\n missingType:\n \"`workflow_dispatch` input '{{inputId}}' should declare `type` explicitly.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require descriptions for manual and reusable workflow interfaces.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Report missing or invalid descriptions across interface mappings. */\nconst checkInterfaceDescriptions = (\n context: Readonly<Rule.RuleContext>,\n mapping: Readonly<AST.YAMLMapping>,\n kind: string\n): void => {\n for (const pair of mapping.pairs) {\n const name = getScalarStringValue(pair.key);\n const entryMapping = unwrapYamlValue(pair.value);\n\n if (name === null || entryMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const descriptionPair = getMappingPair(entryMapping, \"description\");\n\n if (descriptionPair === null) {\n context.report({\n data: {\n kind,\n name,\n },\n messageId: \"missingDescription\",\n node: pair.key as unknown as Rule.Node,\n });\n\n continue;\n }\n\n const descriptionValue = getScalarStringValue(descriptionPair.value);\n\n if (descriptionValue === null || descriptionValue.trim().length === 0) {\n context.report({\n data: {\n kind,\n name,\n },\n messageId: \"invalidDescription\",\n node: (descriptionPair.value ??\n descriptionPair) as unknown as Rule.Node,\n });\n }\n }\n};\n\n/** Rule implementation for requiring workflow interface descriptions. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const onMapping = getMappingValueAsMapping(root, \"on\");\n\n if (onMapping === null) {\n return;\n }\n\n const workflowDispatchMapping = unwrapYamlValue(\n getMappingPair(onMapping, \"workflow_dispatch\")?.value ??\n null\n );\n\n if (workflowDispatchMapping?.type === \"YAMLMapping\") {\n const dispatchInputsMapping = getMappingValueAsMapping(\n workflowDispatchMapping,\n \"inputs\"\n );\n\n if (dispatchInputsMapping !== null) {\n checkInterfaceDescriptions(\n context,\n dispatchInputsMapping,\n \"workflow_dispatch input\"\n );\n }\n }\n\n const workflowCallMapping = unwrapYamlValue(\n getMappingPair(onMapping, \"workflow_call\")?.value ?? null\n );\n\n if (workflowCallMapping?.type !== \"YAMLMapping\") {\n return;\n }\n\n const workflowCallInputsMapping = getMappingValueAsMapping(\n workflowCallMapping,\n \"inputs\"\n );\n\n if (workflowCallInputsMapping !== null) {\n checkInterfaceDescriptions(\n context,\n workflowCallInputsMapping,\n \"workflow_call input\"\n );\n }\n\n const workflowCallSecretsMapping = getMappingValueAsMapping(\n workflowCallMapping,\n \"secrets\"\n );\n\n if (workflowCallSecretsMapping !== null) {\n checkInterfaceDescriptions(\n context,\n workflowCallSecretsMapping,\n \"workflow_call secret\"\n );\n }\n\n const workflowCallOutputsMapping = getMappingValueAsMapping(\n workflowCallMapping,\n \"outputs\"\n );\n\n if (workflowCallOutputsMapping !== null) {\n checkInterfaceDescriptions(\n context,\n workflowCallOutputsMapping,\n \"workflow_call output\"\n );\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require descriptions for `workflow_dispatch` inputs and reusable workflow interfaces so manual forms and callable workflows stay self-documenting.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R024\",\n ruleNumber: 24,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-workflow-interface-description\",\n },\n messages: {\n invalidDescription:\n \"{{kind}} '{{name}}' must set `description` to a non-empty string.\",\n missingDescription:\n \"{{kind}} '{{name}}' should declare `description` explicitly.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require explicit GitHub token permissions at workflow or job scope.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getWorkflowJobs,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule options for `require-workflow-permissions`. */\ntype RequireWorkflowPermissionsOptions = [\n {\n readonly allowJobLevelPermissions?: boolean;\n }?,\n];\n\n/** Rule implementation for requiring explicit workflow or job token permissions. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const [options] = context.options as RequireWorkflowPermissionsOptions;\n const allowJobLevelPermissions =\n options?.allowJobLevelPermissions ?? true;\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n if (getMappingPair(root, \"permissions\") !== null) {\n return;\n }\n\n const jobs = getWorkflowJobs(root);\n\n if (!allowJobLevelPermissions) {\n context.report({\n messageId: \"missingWorkflowPermissions\",\n node: root,\n });\n\n return;\n }\n\n if (jobs.length === 0) {\n context.report({\n messageId: \"missingWorkflowPermissions\",\n node: root,\n });\n\n return;\n }\n\n for (const job of jobs) {\n if (getMappingPair(job.mapping, \"permissions\") !== null) {\n continue;\n }\n\n context.report({\n data: {\n jobId: job.id,\n },\n messageId: \"missingJobPermissions\",\n node: job.idNode,\n });\n }\n },\n };\n },\n meta: {\n defaultOptions: [{}],\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.security\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require explicit `permissions` to avoid relying on GitHub Actions' default token scope.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R001\",\n ruleNumber: 1,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-workflow-permissions\",\n },\n messages: {\n missingJobPermissions:\n \"Job '{{jobId}}' is missing explicit `permissions`. Define workflow-level `permissions` or add `jobs.{{jobId}}.permissions`.\",\n missingWorkflowPermissions:\n \"Define explicit top-level `permissions` for this workflow, or configure job-level `permissions` for every job.\",\n },\n schema: [\n {\n additionalProperties: false,\n description:\n \"Optional configuration for how strictly workflow permissions must be declared.\",\n properties: {\n allowJobLevelPermissions: {\n description:\n \"Allow each job to declare its own permissions when the workflow omits a top-level permissions block.\",\n type: \"boolean\",\n },\n },\n type: \"object\",\n },\n ],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require branch scoping for `workflow_run` triggers.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/**\n * Determine whether a workflow_run branch filter node is meaningfully\n * configured.\n */\nconst hasConfiguredBranchFilter = (\n node: null | Readonly<AST.YAMLPair> | undefined\n): boolean => {\n const valueNode = unwrapYamlValue(node?.value ?? null);\n\n if (valueNode === null) {\n return false;\n }\n\n if (valueNode.type === \"YAMLScalar\") {\n const value = getScalarStringValue(valueNode);\n\n return value !== null && value.trim().length > 0;\n }\n\n if (valueNode.type !== \"YAMLSequence\") {\n return false;\n }\n\n return valueNode.entries.some((entry) => {\n const value = getScalarStringValue(entry);\n\n return value !== null && value.trim().length > 0;\n });\n};\n\n/** Rule implementation for requiring `workflow_run` branch filters. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const onMapping = getMappingValueAsMapping(root, \"on\");\n\n if (onMapping === null) {\n return;\n }\n\n const workflowRunPair = getMappingPair(\n onMapping,\n \"workflow_run\"\n );\n const workflowRunMapping = unwrapYamlValue(\n workflowRunPair?.value ?? null\n );\n\n if (workflowRunPair === null) {\n return;\n }\n\n if (workflowRunMapping?.type !== \"YAMLMapping\") {\n context.report({\n messageId: \"missingBranchFilter\",\n node: (workflowRunPair.value ??\n workflowRunPair) as unknown as Rule.Node,\n });\n\n return;\n }\n\n const branchesPair = getMappingPair(\n workflowRunMapping,\n \"branches\"\n );\n const branchesIgnorePair = getMappingPair(\n workflowRunMapping,\n \"branches-ignore\"\n );\n\n if (\n hasConfiguredBranchFilter(branchesPair) ||\n hasConfiguredBranchFilter(branchesIgnorePair)\n ) {\n return;\n }\n\n context.report({\n messageId: \"missingBranchFilter\",\n node: workflowRunMapping as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.security\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require `on.workflow_run` triggers to scope upstream branches with `branches` or `branches-ignore` so follow-up workflows do not react to every branch indiscriminately.\",\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R028\",\n ruleNumber: 28,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-workflow-run-branches\",\n },\n messages: {\n missingBranchFilter:\n \"`on.workflow_run` should declare a non-empty `branches` or `branches-ignore` filter to scope which upstream branches can trigger this workflow.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require each workflow template YAML file to have a paired `.properties.json` metadata file.\n */\nimport type { Rule } from \"eslint\";\n\nimport { existsSync } from \"node:fs\";\n\nimport { isWorkflowTemplateYamlFile } from \"../_internal/lint-targets.js\";\nimport { getPairedTemplatePropertiesPath } from \"../_internal/workflow-template-properties.js\";\n\n/** Rule implementation for workflow-template YAML pair checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!isWorkflowTemplateYamlFile(context.filename)) {\n return;\n }\n\n const pairedPropertiesPath = getPairedTemplatePropertiesPath(\n context.filename\n );\n\n if (existsSync(pairedPropertiesPath)) {\n return;\n }\n\n context.report({\n data: {\n pairedPropertiesPath,\n },\n messageId: \"missingTemplatePropertiesPair\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"require each workflow template YAML file to have a matching `.properties.json` metadata file.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R054\",\n ruleNumber: 54,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-workflow-template-pair\",\n },\n messages: {\n missingTemplatePropertiesPair:\n \"Workflow template file is missing its paired metadata file '{{pairedPropertiesPath}}'.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require each workflow template properties file to have a paired template YAML file.\n */\nimport type { Rule } from \"eslint\";\n\nimport { existsSync } from \"node:fs\";\n\nimport { isWorkflowTemplatePropertiesFile } from \"../_internal/lint-targets.js\";\nimport { getPairedTemplateYamlPaths } from \"../_internal/workflow-template-properties.js\";\n\n/** Rule implementation for template metadata pair checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const [pairedYmlPath, pairedYamlPath] =\n getPairedTemplateYamlPaths(context.filename);\n\n if (existsSync(pairedYmlPath) || existsSync(pairedYamlPath)) {\n return;\n }\n\n context.report({\n data: {\n pairedYamlPath,\n pairedYmlPath,\n },\n messageId: \"missingTemplateYamlPair\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"require each workflow-template `.properties.json` file to have a matching template YAML file.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R055\",\n ruleNumber: 55,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-workflow-template-properties-pair\",\n },\n messages: {\n missingTemplateYamlPair:\n \"Workflow template metadata is missing its paired YAML file. Expected '{{pairedYmlPath}}' or '{{pairedYamlPath}}'.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Validate literal job and step timeout-minutes values.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getMappingValueAsSequence,\n getScalarNumberValue,\n getWorkflowRoot,\n isGithubExpressionScalar,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Timeout range accepted by a timeout validator. */\ntype TimeoutRange = {\n readonly max?: number;\n readonly min?: number;\n};\n\n/** Split timeout configuration for jobs and steps. */\ntype TimeoutScopeOptions = {\n readonly job?: number | TimeoutRange;\n readonly step?: number | TimeoutRange;\n};\n\n/** Rule options for `valid-timeout-minutes`. */\ntype ValidTimeoutMinutesOptions = [\n (number | TimeoutRange | TimeoutScopeOptions)?,\n];\n\n/** Default lower bound for literal timeout-minutes values. */\nconst MIN_TIMEOUT_MINUTES = 1;\n\n/** Default upper bound for literal timeout-minutes values. */\nconst MAX_TIMEOUT_MINUTES = 24 * 60;\n\n/** Default recommended upper bound when only a single number is configured. */\nconst DEFAULT_MAX_TIMEOUT_MINUTES = 6 * 60;\n\n/** Normalize timeout range input into concrete min/max bounds. */\nconst normalizeTimeoutRange = (\n value: Readonly<number | TimeoutRange | undefined>,\n fallback: Readonly<{ max: number; min: number }>\n): { max: number; min: number } => {\n if (typeof value === \"number\") {\n return {\n max: value,\n min: fallback.min,\n };\n }\n\n if (value === undefined) {\n return {\n max: fallback.max,\n min: fallback.min,\n };\n }\n\n return {\n max: value.max ?? fallback.max,\n min: value.min ?? fallback.min,\n };\n};\n\n/** Determine whether an options value represents a shared timeout range. */\nconst isTimeoutRange = (value: unknown): value is TimeoutRange =>\n typeof value === \"object\" &&\n value !== null &&\n (\"min\" in value || \"max\" in value);\n\n/** Determine whether an options value represents split job/step timeout config. */\nconst isTimeoutScopeOptions = (value: unknown): value is TimeoutScopeOptions =>\n typeof value === \"object\" &&\n value !== null &&\n (\"job\" in value || \"step\" in value);\n\n/** Rule implementation for validating timeout-minutes ranges. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const [options] = context.options as ValidTimeoutMinutesOptions;\n const defaultRange = {\n max: DEFAULT_MAX_TIMEOUT_MINUTES,\n min: MIN_TIMEOUT_MINUTES,\n };\n const workflowMaximumRange = {\n max: MAX_TIMEOUT_MINUTES,\n };\n\n const jobRange = normalizeTimeoutRange(\n typeof options === \"number\" || isTimeoutRange(options)\n ? options\n : options?.job,\n defaultRange\n );\n const stepRange = normalizeTimeoutRange(\n typeof options === \"number\" || isTimeoutRange(options)\n ? options\n : options?.step,\n defaultRange\n );\n\n if (isTimeoutScopeOptions(options)) {\n jobRange.max = normalizeTimeoutRange(options.job, defaultRange).max;\n jobRange.min = normalizeTimeoutRange(options.job, defaultRange).min;\n stepRange.max = normalizeTimeoutRange(\n options.step,\n defaultRange\n ).max;\n stepRange.min = normalizeTimeoutRange(\n options.step,\n defaultRange\n ).min;\n }\n\n const validateTimeoutPair = (\n timeoutPair: Readonly<AST.YAMLPair>,\n range: Readonly<{ max: number; min: number }>\n ): \"invalidRange\" | \"notInteger\" | null => {\n if (isGithubExpressionScalar(timeoutPair.value)) {\n return null;\n }\n\n const timeoutValue = getScalarNumberValue(timeoutPair.value);\n\n if (\n timeoutValue === null ||\n !Number.isInteger(timeoutValue) ||\n timeoutValue <= 0\n ) {\n return \"notInteger\";\n }\n\n if (\n timeoutValue < range.min ||\n timeoutValue > range.max ||\n timeoutValue > workflowMaximumRange.max\n ) {\n return \"invalidRange\";\n }\n\n return null;\n };\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const jobsMapping = getMappingValueAsMapping(root, \"jobs\");\n\n if (jobsMapping === null) {\n return;\n }\n\n for (const jobPair of jobsMapping.pairs) {\n const jobValue = unwrapYamlValue(jobPair.value);\n\n if (jobValue?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const jobTimeoutPair = getMappingPair(\n jobValue,\n \"timeout-minutes\"\n );\n\n if (jobTimeoutPair !== null) {\n const validationResult = validateTimeoutPair(\n jobTimeoutPair,\n jobRange\n );\n\n if (validationResult !== null) {\n context.report({\n data: {\n max: String(jobRange.max),\n min: String(jobRange.min),\n },\n messageId: validationResult,\n node: (jobTimeoutPair.value ??\n jobTimeoutPair) as unknown as Rule.Node,\n });\n }\n }\n\n const stepsSequence = getMappingValueAsSequence(\n jobValue,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n continue;\n }\n\n for (const stepEntry of stepsSequence.entries) {\n const stepValue = unwrapYamlValue(stepEntry);\n\n if (stepValue?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const stepTimeoutPair = getMappingPair(\n stepValue,\n \"timeout-minutes\"\n );\n\n if (stepTimeoutPair === null) {\n continue;\n }\n\n const validationResult = validateTimeoutPair(\n stepTimeoutPair,\n stepRange\n );\n\n if (validationResult !== null) {\n context.report({\n data: {\n max: String(stepRange.max),\n min: String(stepRange.min),\n },\n messageId: validationResult,\n node: (stepTimeoutPair.value ??\n stepTimeoutPair) as unknown as Rule.Node,\n });\n }\n }\n }\n },\n };\n },\n meta: {\n defaultOptions: [DEFAULT_MAX_TIMEOUT_MINUTES],\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow invalid literal `timeout-minutes` values for jobs and steps.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R017\",\n ruleNumber: 17,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/valid-timeout-minutes\",\n },\n messages: {\n invalidRange:\n \"`timeout-minutes` must stay within the configured range of {{min}}-{{max}}.\",\n notInteger:\n \"`timeout-minutes` must be a positive integer or a GitHub expression.\",\n },\n schema: [\n {\n anyOf: [\n {\n description:\n \"Maximum allowed timeout-minutes value for both jobs and steps.\",\n maximum: MAX_TIMEOUT_MINUTES,\n minimum: MIN_TIMEOUT_MINUTES,\n type: \"integer\",\n },\n {\n additionalProperties: false,\n description:\n \"Shared min/max range for literal job and step timeout-minutes values.\",\n properties: {\n max: {\n description:\n \"Maximum allowed timeout-minutes value.\",\n maximum: MAX_TIMEOUT_MINUTES,\n minimum: MIN_TIMEOUT_MINUTES,\n type: \"integer\",\n },\n min: {\n description:\n \"Minimum allowed timeout-minutes value.\",\n maximum: MAX_TIMEOUT_MINUTES,\n minimum: MIN_TIMEOUT_MINUTES,\n type: \"integer\",\n },\n },\n type: \"object\",\n },\n {\n additionalProperties: false,\n description:\n \"Separate timeout-minutes limits for jobs and steps.\",\n properties: {\n job: {\n anyOf: [\n {\n description:\n \"Maximum allowed timeout-minutes value for jobs.\",\n maximum: MAX_TIMEOUT_MINUTES,\n minimum: MIN_TIMEOUT_MINUTES,\n type: \"integer\",\n },\n {\n additionalProperties: false,\n description:\n \"Min/max range for literal job timeout-minutes values.\",\n properties: {\n max: {\n description:\n \"Maximum allowed job timeout-minutes value.\",\n maximum: MAX_TIMEOUT_MINUTES,\n minimum: MIN_TIMEOUT_MINUTES,\n type: \"integer\",\n },\n min: {\n description:\n \"Minimum allowed job timeout-minutes value.\",\n maximum: MAX_TIMEOUT_MINUTES,\n minimum: MIN_TIMEOUT_MINUTES,\n type: \"integer\",\n },\n },\n type: \"object\",\n },\n ],\n },\n step: {\n anyOf: [\n {\n description:\n \"Maximum allowed timeout-minutes value for steps.\",\n maximum: MAX_TIMEOUT_MINUTES,\n minimum: MIN_TIMEOUT_MINUTES,\n type: \"integer\",\n },\n {\n additionalProperties: false,\n description:\n \"Min/max range for literal step timeout-minutes values.\",\n properties: {\n max: {\n description:\n \"Maximum allowed step timeout-minutes value.\",\n maximum: MAX_TIMEOUT_MINUTES,\n minimum: MIN_TIMEOUT_MINUTES,\n type: \"integer\",\n },\n min: {\n description:\n \"Minimum allowed step timeout-minutes value.\",\n maximum: MAX_TIMEOUT_MINUTES,\n minimum: MIN_TIMEOUT_MINUTES,\n type: \"integer\",\n },\n },\n type: \"object\",\n },\n ],\n },\n },\n type: \"object\",\n },\n ],\n description:\n \"Configure literal timeout-minutes validation for jobs and steps.\",\n },\n ],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Current GitHub Actions workflow trigger events from the public docs.\n */\n\n/**\n * Valid workflow trigger events documented by GitHub.\n *\n * @see https://docs.github.com/en/actions/reference/events-that-trigger-workflows\n */\nexport const githubActionsTriggerEvents = [\n \"branch_protection_rule\",\n \"check_run\",\n \"check_suite\",\n \"create\",\n \"delete\",\n \"deployment\",\n \"deployment_status\",\n \"discussion\",\n \"discussion_comment\",\n \"fork\",\n \"gollum\",\n \"image_version\",\n \"issue_comment\",\n \"issues\",\n \"label\",\n \"merge_group\",\n \"milestone\",\n \"page_build\",\n \"public\",\n \"pull_request\",\n \"pull_request_review\",\n \"pull_request_review_comment\",\n \"pull_request_target\",\n \"push\",\n \"registry_package\",\n \"release\",\n \"repository_dispatch\",\n \"schedule\",\n \"status\",\n \"watch\",\n \"workflow_call\",\n \"workflow_dispatch\",\n \"workflow_run\",\n] as const;\n\n/** Constant-time lookup set for validating trigger-event names. */\nexport const githubActionsTriggerEventSet: ReadonlySet<string> = new Set(\n githubActionsTriggerEvents\n);\n", "/**\n * @packageDocumentation\n * Validate GitHub Actions workflow trigger event names.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport { githubActionsTriggerEventSet } from \"../_internal/github-actions-trigger-events.js\";\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for validating `on:` trigger event names. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const reportInvalidEvent = (\n node: Readonly<AST.YAMLNode>,\n eventName: string\n ): void => {\n context.report({\n data: {\n event: eventName,\n },\n messageId: \"invalidEvent\",\n node: node as unknown as Rule.Node,\n });\n };\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const onPair = getMappingPair(root, \"on\");\n const onValue = unwrapYamlValue(onPair?.value ?? null);\n\n if (onValue === null) {\n return;\n }\n\n if (onValue.type === \"YAMLScalar\") {\n const eventName = getScalarStringValue(onValue);\n\n if (\n eventName !== null &&\n !githubActionsTriggerEventSet.has(eventName)\n ) {\n reportInvalidEvent(onValue, eventName);\n }\n\n return;\n }\n\n if (onValue.type === \"YAMLSequence\") {\n for (const entry of onValue.entries) {\n const unwrappedEntry = unwrapYamlValue(entry);\n const eventName = getScalarStringValue(unwrappedEntry);\n\n if (\n unwrappedEntry !== null &&\n (eventName === null ||\n !githubActionsTriggerEventSet.has(eventName))\n ) {\n context.report({\n data: {\n event: eventName ?? \"<unknown>\",\n },\n messageId:\n eventName === null\n ? \"invalidEventEntry\"\n : \"invalidEvent\",\n node: unwrappedEntry as unknown as Rule.Node,\n });\n }\n }\n\n return;\n }\n\n if (onValue.type !== \"YAMLMapping\") {\n context.report({\n messageId: \"invalidEventEntry\",\n node: onValue as unknown as Rule.Node,\n });\n\n return;\n }\n\n for (const pair of onValue.pairs) {\n const eventName = getScalarStringValue(pair.key);\n\n if (eventName === null) {\n context.report({\n messageId: \"invalidEventEntry\",\n node: pair as unknown as Rule.Node,\n });\n\n continue;\n }\n\n if (!githubActionsTriggerEventSet.has(eventName)) {\n reportInvalidEvent(pair.key as AST.YAMLNode, eventName);\n }\n }\n },\n };\n },\n meta: {\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow invalid GitHub Actions trigger events under the workflow `on` key.\",\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R018\",\n ruleNumber: 18,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/valid-trigger-events\",\n },\n messages: {\n invalidEvent:\n \"`{{event}}` is not a documented GitHub Actions workflow trigger event.\",\n invalidEventEntry:\n \"Workflow `on` entries must use string event names.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Central rule registry for eslint-plugin-github-actions-2.\n */\nimport type { Rule } from \"eslint\";\n\nimport actionNameCasing from \"../rules/action-name-casing.js\";\nimport jobIdCasing from \"../rules/job-id-casing.js\";\nimport maxJobsPerAction from \"../rules/max-jobs-per-action.js\";\nimport noCaseInsensitiveInputIdCollision from \"../rules/no-case-insensitive-input-id-collision.js\";\nimport noCompositeInputEnvAccess from \"../rules/no-composite-input-env-access.js\";\nimport noDeprecatedNodeRuntime from \"../rules/no-deprecated-node-runtime.js\";\nimport noDuplicateCompositeStepId from \"../rules/no-duplicate-composite-step-id.js\";\nimport noEmptyTemplateFilePattern from \"../rules/no-empty-template-file-pattern.js\";\nimport noExternalJob from \"../rules/no-external-job.js\";\nimport noHardcodedDefaultBranchInTemplate from \"../rules/no-hardcoded-default-branch-in-template.js\";\nimport noIconFileExtensionInTemplateIconName from \"../rules/no-icon-file-extension-in-template-icon-name.js\";\nimport noInheritSecrets from \"../rules/no-inherit-secrets.js\";\nimport noInvalidConcurrencyContext from \"../rules/no-invalid-concurrency-context.js\";\nimport noInvalidKey from \"../rules/no-invalid-key.js\";\nimport noInvalidReusableWorkflowJobKey from \"../rules/no-invalid-reusable-workflow-job-key.js\";\nimport noInvalidTemplateFilePatternRegex from \"../rules/no-invalid-template-file-pattern-regex.js\";\nimport noInvalidWorkflowCallOutputValue from \"../rules/no-invalid-workflow-call-output-value.js\";\nimport noPathSeparatorsInTemplateIconName from \"../rules/no-path-separators-in-template-icon-name.js\";\nimport noPostIfWithoutPost from \"../rules/no-post-if-without-post.js\";\nimport noPrHeadCheckoutInPullRequestTarget from \"../rules/no-pr-head-checkout-in-pull-request-target.js\";\nimport noPreIfWithoutPre from \"../rules/no-pre-if-without-pre.js\";\nimport noRequiredInputWithDefault from \"../rules/no-required-input-with-default.js\";\nimport noSecretsInIf from \"../rules/no-secrets-in-if.js\";\nimport noSelfHostedRunnerOnForkPrEvents from \"../rules/no-self-hosted-runner-on-fork-pr-events.js\";\nimport noSubdirectoryTemplateFilePattern from \"../rules/no-subdirectory-template-file-pattern.js\";\nimport noTemplatePlaceholderInNonTemplateWorkflow from \"../rules/no-template-placeholder-in-non-template-workflow.js\";\nimport noTopLevelEnv from \"../rules/no-top-level-env.js\";\nimport noTopLevelPermissions from \"../rules/no-top-level-permissions.js\";\nimport noUniversalTemplateFilePattern from \"../rules/no-universal-template-file-pattern.js\";\nimport noUnknownInputReferenceInComposite from \"../rules/no-unknown-input-reference-in-composite.js\";\nimport noUnknownJobOutputReference from \"../rules/no-unknown-job-output-reference.js\";\nimport noUnknownStepReference from \"../rules/no-unknown-step-reference.js\";\nimport noUntrustedInputInRun from \"../rules/no-untrusted-input-in-run.js\";\nimport noUnusedInputInComposite from \"../rules/no-unused-input-in-composite.js\";\nimport noWriteAllPermissions from \"../rules/no-write-all-permissions.js\";\nimport pinActionShas from \"../rules/pin-action-shas.js\";\nimport preferActionYml from \"../rules/prefer-action-yml.js\";\nimport preferFailFast from \"../rules/prefer-fail-fast.js\";\nimport preferFileExtension from \"../rules/prefer-file-extension.js\";\nimport preferInputsContext from \"../rules/prefer-inputs-context.js\";\nimport preferStepUsesStyle from \"../rules/prefer-step-uses-style.js\";\nimport preferTemplateYmlExtension from \"../rules/prefer-template-yml-extension.js\";\nimport requireActionName from \"../rules/require-action-name.js\";\nimport requireActionRunName from \"../rules/require-action-run-name.js\";\nimport requireCheckoutBeforeLocalAction from \"../rules/require-checkout-before-local-action.js\";\nimport requireCompositeStepName from \"../rules/require-composite-step-name.js\";\nimport requireJobName from \"../rules/require-job-name.js\";\nimport requireJobStepName from \"../rules/require-job-step-name.js\";\nimport requireJobTimeoutMinutes from \"../rules/require-job-timeout-minutes.js\";\nimport requireMergeGroupTrigger from \"../rules/require-merge-group-trigger.js\";\nimport requirePullRequestTargetBranches from \"../rules/require-pull-request-target-branches.js\";\nimport requireRunStepShell from \"../rules/require-run-step-shell.js\";\nimport requireTemplateCategories from \"../rules/require-template-categories.js\";\nimport requireTemplateFilePatterns from \"../rules/require-template-file-patterns.js\";\nimport requireTemplateIconFileExists from \"../rules/require-template-icon-file-exists.js\";\nimport requireTemplateIconName from \"../rules/require-template-icon-name.js\";\nimport requireTemplateWorkflowName from \"../rules/require-template-workflow-name.js\";\nimport requireTriggerTypes from \"../rules/require-trigger-types.js\";\nimport requireWorkflowCallInputType from \"../rules/require-workflow-call-input-type.js\";\nimport requireWorkflowCallOutputValue from \"../rules/require-workflow-call-output-value.js\";\nimport requireWorkflowConcurrency from \"../rules/require-workflow-concurrency.js\";\nimport requireWorkflowDispatchInputType from \"../rules/require-workflow-dispatch-input-type.js\";\nimport requireWorkflowInterfaceDescription from \"../rules/require-workflow-interface-description.js\";\nimport requireWorkflowPermissions from \"../rules/require-workflow-permissions.js\";\nimport requireWorkflowRunBranches from \"../rules/require-workflow-run-branches.js\";\nimport requireWorkflowTemplatePair from \"../rules/require-workflow-template-pair.js\";\nimport requireWorkflowTemplatePropertiesPair from \"../rules/require-workflow-template-properties-pair.js\";\nimport validTimeoutMinutes from \"../rules/valid-timeout-minutes.js\";\nimport validTriggerEvents from \"../rules/valid-trigger-events.js\";\n\n/** Strongly typed plugin rule registry keyed by unqualified rule name. */\nconst githubActionsRulesDefinition: {\n readonly \"action-name-casing\": typeof actionNameCasing;\n readonly \"job-id-casing\": typeof jobIdCasing;\n readonly \"max-jobs-per-action\": typeof maxJobsPerAction;\n readonly \"no-case-insensitive-input-id-collision\": typeof noCaseInsensitiveInputIdCollision;\n readonly \"no-composite-input-env-access\": typeof noCompositeInputEnvAccess;\n readonly \"no-deprecated-node-runtime\": typeof noDeprecatedNodeRuntime;\n readonly \"no-duplicate-composite-step-id\": typeof noDuplicateCompositeStepId;\n readonly \"no-empty-template-file-pattern\": typeof noEmptyTemplateFilePattern;\n readonly \"no-external-job\": typeof noExternalJob;\n readonly \"no-hardcoded-default-branch-in-template\": typeof noHardcodedDefaultBranchInTemplate;\n readonly \"no-icon-file-extension-in-template-icon-name\": typeof noIconFileExtensionInTemplateIconName;\n readonly \"no-inherit-secrets\": typeof noInheritSecrets;\n readonly \"no-invalid-concurrency-context\": typeof noInvalidConcurrencyContext;\n readonly \"no-invalid-key\": typeof noInvalidKey;\n readonly \"no-invalid-reusable-workflow-job-key\": typeof noInvalidReusableWorkflowJobKey;\n readonly \"no-invalid-template-file-pattern-regex\": typeof noInvalidTemplateFilePatternRegex;\n readonly \"no-invalid-workflow-call-output-value\": typeof noInvalidWorkflowCallOutputValue;\n readonly \"no-path-separators-in-template-icon-name\": typeof noPathSeparatorsInTemplateIconName;\n readonly \"no-post-if-without-post\": typeof noPostIfWithoutPost;\n readonly \"no-pr-head-checkout-in-pull-request-target\": typeof noPrHeadCheckoutInPullRequestTarget;\n readonly \"no-pre-if-without-pre\": typeof noPreIfWithoutPre;\n readonly \"no-required-input-with-default\": typeof noRequiredInputWithDefault;\n readonly \"no-secrets-in-if\": typeof noSecretsInIf;\n readonly \"no-self-hosted-runner-on-fork-pr-events\": typeof noSelfHostedRunnerOnForkPrEvents;\n readonly \"no-subdirectory-template-file-pattern\": typeof noSubdirectoryTemplateFilePattern;\n readonly \"no-template-placeholder-in-non-template-workflow\": typeof noTemplatePlaceholderInNonTemplateWorkflow;\n readonly \"no-top-level-env\": typeof noTopLevelEnv;\n readonly \"no-top-level-permissions\": typeof noTopLevelPermissions;\n readonly \"no-universal-template-file-pattern\": typeof noUniversalTemplateFilePattern;\n readonly \"no-unknown-input-reference-in-composite\": typeof noUnknownInputReferenceInComposite;\n readonly \"no-unknown-job-output-reference\": typeof noUnknownJobOutputReference;\n readonly \"no-unknown-step-reference\": typeof noUnknownStepReference;\n readonly \"no-untrusted-input-in-run\": typeof noUntrustedInputInRun;\n readonly \"no-unused-input-in-composite\": typeof noUnusedInputInComposite;\n readonly \"no-write-all-permissions\": typeof noWriteAllPermissions;\n readonly \"pin-action-shas\": typeof pinActionShas;\n readonly \"prefer-action-yml\": typeof preferActionYml;\n readonly \"prefer-fail-fast\": typeof preferFailFast;\n readonly \"prefer-file-extension\": typeof preferFileExtension;\n readonly \"prefer-inputs-context\": typeof preferInputsContext;\n readonly \"prefer-step-uses-style\": typeof preferStepUsesStyle;\n readonly \"prefer-template-yml-extension\": typeof preferTemplateYmlExtension;\n readonly \"require-action-name\": typeof requireActionName;\n readonly \"require-action-run-name\": typeof requireActionRunName;\n readonly \"require-checkout-before-local-action\": typeof requireCheckoutBeforeLocalAction;\n readonly \"require-composite-step-name\": typeof requireCompositeStepName;\n readonly \"require-job-name\": typeof requireJobName;\n readonly \"require-job-step-name\": typeof requireJobStepName;\n readonly \"require-job-timeout-minutes\": typeof requireJobTimeoutMinutes;\n readonly \"require-merge-group-trigger\": typeof requireMergeGroupTrigger;\n readonly \"require-pull-request-target-branches\": typeof requirePullRequestTargetBranches;\n readonly \"require-run-step-shell\": typeof requireRunStepShell;\n readonly \"require-template-categories\": typeof requireTemplateCategories;\n readonly \"require-template-file-patterns\": typeof requireTemplateFilePatterns;\n readonly \"require-template-icon-file-exists\": typeof requireTemplateIconFileExists;\n readonly \"require-template-icon-name\": typeof requireTemplateIconName;\n readonly \"require-template-workflow-name\": typeof requireTemplateWorkflowName;\n readonly \"require-trigger-types\": typeof requireTriggerTypes;\n readonly \"require-workflow-call-input-type\": typeof requireWorkflowCallInputType;\n readonly \"require-workflow-call-output-value\": typeof requireWorkflowCallOutputValue;\n readonly \"require-workflow-concurrency\": typeof requireWorkflowConcurrency;\n readonly \"require-workflow-dispatch-input-type\": typeof requireWorkflowDispatchInputType;\n readonly \"require-workflow-interface-description\": typeof requireWorkflowInterfaceDescription;\n readonly \"require-workflow-permissions\": typeof requireWorkflowPermissions;\n readonly \"require-workflow-run-branches\": typeof requireWorkflowRunBranches;\n readonly \"require-workflow-template-pair\": typeof requireWorkflowTemplatePair;\n readonly \"require-workflow-template-properties-pair\": typeof requireWorkflowTemplatePropertiesPair;\n readonly \"valid-timeout-minutes\": typeof validTimeoutMinutes;\n readonly \"valid-trigger-events\": typeof validTriggerEvents;\n} = {\n \"action-name-casing\": actionNameCasing,\n \"job-id-casing\": jobIdCasing,\n \"max-jobs-per-action\": maxJobsPerAction,\n \"no-case-insensitive-input-id-collision\": noCaseInsensitiveInputIdCollision,\n \"no-composite-input-env-access\": noCompositeInputEnvAccess,\n \"no-deprecated-node-runtime\": noDeprecatedNodeRuntime,\n \"no-duplicate-composite-step-id\": noDuplicateCompositeStepId,\n \"no-empty-template-file-pattern\": noEmptyTemplateFilePattern,\n \"no-external-job\": noExternalJob,\n \"no-hardcoded-default-branch-in-template\":\n noHardcodedDefaultBranchInTemplate,\n \"no-icon-file-extension-in-template-icon-name\":\n noIconFileExtensionInTemplateIconName,\n \"no-inherit-secrets\": noInheritSecrets,\n \"no-invalid-concurrency-context\": noInvalidConcurrencyContext,\n \"no-invalid-key\": noInvalidKey,\n \"no-invalid-reusable-workflow-job-key\": noInvalidReusableWorkflowJobKey,\n \"no-invalid-template-file-pattern-regex\": noInvalidTemplateFilePatternRegex,\n \"no-invalid-workflow-call-output-value\": noInvalidWorkflowCallOutputValue,\n \"no-path-separators-in-template-icon-name\":\n noPathSeparatorsInTemplateIconName,\n \"no-post-if-without-post\": noPostIfWithoutPost,\n \"no-pr-head-checkout-in-pull-request-target\":\n noPrHeadCheckoutInPullRequestTarget,\n \"no-pre-if-without-pre\": noPreIfWithoutPre,\n \"no-required-input-with-default\": noRequiredInputWithDefault,\n \"no-secrets-in-if\": noSecretsInIf,\n \"no-self-hosted-runner-on-fork-pr-events\": noSelfHostedRunnerOnForkPrEvents,\n \"no-subdirectory-template-file-pattern\": noSubdirectoryTemplateFilePattern,\n \"no-template-placeholder-in-non-template-workflow\":\n noTemplatePlaceholderInNonTemplateWorkflow,\n \"no-top-level-env\": noTopLevelEnv,\n \"no-top-level-permissions\": noTopLevelPermissions,\n \"no-universal-template-file-pattern\": noUniversalTemplateFilePattern,\n \"no-unknown-input-reference-in-composite\":\n noUnknownInputReferenceInComposite,\n \"no-unknown-job-output-reference\": noUnknownJobOutputReference,\n \"no-unknown-step-reference\": noUnknownStepReference,\n \"no-untrusted-input-in-run\": noUntrustedInputInRun,\n \"no-unused-input-in-composite\": noUnusedInputInComposite,\n \"no-write-all-permissions\": noWriteAllPermissions,\n \"pin-action-shas\": pinActionShas,\n \"prefer-action-yml\": preferActionYml,\n \"prefer-fail-fast\": preferFailFast,\n \"prefer-file-extension\": preferFileExtension,\n \"prefer-inputs-context\": preferInputsContext,\n \"prefer-step-uses-style\": preferStepUsesStyle,\n \"prefer-template-yml-extension\": preferTemplateYmlExtension,\n \"require-action-name\": requireActionName,\n \"require-action-run-name\": requireActionRunName,\n \"require-checkout-before-local-action\": requireCheckoutBeforeLocalAction,\n \"require-composite-step-name\": requireCompositeStepName,\n \"require-job-name\": requireJobName,\n \"require-job-step-name\": requireJobStepName,\n \"require-job-timeout-minutes\": requireJobTimeoutMinutes,\n \"require-merge-group-trigger\": requireMergeGroupTrigger,\n \"require-pull-request-target-branches\": requirePullRequestTargetBranches,\n \"require-run-step-shell\": requireRunStepShell,\n \"require-template-categories\": requireTemplateCategories,\n \"require-template-file-patterns\": requireTemplateFilePatterns,\n \"require-template-icon-file-exists\": requireTemplateIconFileExists,\n \"require-template-icon-name\": requireTemplateIconName,\n \"require-template-workflow-name\": requireTemplateWorkflowName,\n \"require-trigger-types\": requireTriggerTypes,\n \"require-workflow-call-input-type\": requireWorkflowCallInputType,\n \"require-workflow-call-output-value\": requireWorkflowCallOutputValue,\n \"require-workflow-concurrency\": requireWorkflowConcurrency,\n \"require-workflow-dispatch-input-type\": requireWorkflowDispatchInputType,\n \"require-workflow-interface-description\":\n requireWorkflowInterfaceDescription,\n \"require-workflow-permissions\": requireWorkflowPermissions,\n \"require-workflow-run-branches\": requireWorkflowRunBranches,\n \"require-workflow-template-pair\": requireWorkflowTemplatePair,\n \"require-workflow-template-properties-pair\":\n requireWorkflowTemplatePropertiesPair,\n \"valid-timeout-minutes\": validTimeoutMinutes,\n \"valid-trigger-events\": validTriggerEvents,\n} satisfies Record<string, Rule.RuleModule>;\n\n/** Strongly typed plugin rule registry keyed by unqualified rule name. */\nexport const githubActionsRules: typeof githubActionsRulesDefinition =\n githubActionsRulesDefinition;\n"],
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAMA;;;;;iBAA4B;;;ACN5B;AAAA,EACI,SAAW;AAAA,EACX,MAAQ;AAAA,EACR,SAAW;AAAA,EACX,SAAW;AAAA,EACX,aAAe;AAAA,EACf,UAAY;AAAA,IACR;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACJ;AAAA,EACA,UAAY;AAAA,EACZ,MAAQ;AAAA,IACJ,KAAO;AAAA,IACP,OAAS;AAAA,EACb;AAAA,EACA,YAAc;AAAA,IACV,MAAQ;AAAA,IACR,KAAO;AAAA,EACX;AAAA,EACA,SAAW;AAAA,EACX,QAAU;AAAA,EACV,cAAgB;AAAA,IACZ;AAAA,MACI,MAAQ;AAAA,MACR,OAAS;AAAA,MACT,KAAO;AAAA,IACX;AAAA,EACJ;AAAA,EACA,aAAe;AAAA,EACf,MAAQ;AAAA,EACR,SAAW;AAAA,IACP,KAAK;AAAA,MACD,QAAU;AAAA,QACN,OAAS;AAAA,QACT,SAAW;AAAA,MACf;AAAA,MACA,SAAW;AAAA,QACP,OAAS;AAAA,QACT,SAAW;AAAA,MACf;AAAA,MACA,SAAW;AAAA,IACf;AAAA,IACA,kBAAkB;AAAA,EACtB;AAAA,EACA,MAAQ;AAAA,EACR,OAAS;AAAA,EACT,OAAS;AAAA,IACL;AAAA,IACA;AAAA,IACA;AAAA,EACJ;AAAA,E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AkC,UAAU;AAE7D,YAAQ,UAAU,IAAI,wBAClB;MACI,OAAO,CAAC,GAAG,SAAS,KAAK;MACzB,MAAM,SAAS;MACf,OAAO,cAAc,wBAAwB,UAAU,CAAC;OAE5D,gBAAgB;EAExB;AAEA,SAAO;AACX;AAGA,IAAM,uBACF,qCAAoC;AAGxC,IAAM,sBAAmD;EACrD,SAAS;EACT,MAAM;IACF,MAAM;IACN,WAAW;IACX,SAAS,kBAAkB,eAAW;;EAE1C,YAAY,CAAA;EACZ,OAAO;;AAOX,IAAA,iBAAe;",
|
|
6
|
-
"names": ["rule", "rule", "rule", "rule", "rule", "rule", "import_node_path", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "isReusableWorkflowJob", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "jobsOutputReferencePattern", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "import_node_path", "rule", "visitStringScalars", "rule", "rule", "rule", "rule", "rule", "isCheckoutActionReference", "isLocalActionReference", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "import_node_path", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "groupValue", "rule", "rule", "rule", "hasConfiguredBranchFilter", "rule", "import_node_fs", "rule", "import_node_fs", "rule", "rule", "rule", "rule", "presetRuleNamesByConfig"]
|
|
3
|
+
"sources": ["../src/plugin.ts", "../package.json", "../src/_internal/lint-targets.ts", "../src/_internal/workflow-yaml.ts", "../src/_internal/github-actions-config-references.ts", "../src/_internal/case-police-dictionary.ts", "../src/_internal/casing.ts", "../src/rules/action-name-casing.ts", "../src/rules/job-id-casing.ts", "../src/rules/max-jobs-per-action.ts", "../src/rules/no-case-insensitive-input-id-collision.ts", "../src/_internal/workflow-action-steps.ts", "../src/_internal/code-scanning-workflow.ts", "../src/rules/no-codeql-autobuild-for-javascript-typescript.ts", "../src/rules/no-codeql-javascript-typescript-split-language-matrix.ts", "../src/_internal/yaml-traversal.ts", "../src/rules/no-composite-input-env-access.ts", "../src/rules/no-deprecated-node-runtime.ts", "../src/rules/no-duplicate-composite-step-id.ts", "../src/_internal/workflow-template-properties.ts", "../src/_internal/yaml-fixes.ts", "../src/rules/no-empty-template-file-pattern.ts", "../src/rules/no-external-job.ts", "../src/rules/no-hardcoded-default-branch-in-template.ts", "../src/rules/no-icon-file-extension-in-template-icon-name.ts", "../src/rules/no-inherit-secrets.ts", "../src/_internal/github-expressions.ts", "../src/rules/no-invalid-concurrency-context.ts", "../src/rules/no-invalid-key.ts", "../src/rules/no-invalid-reusable-workflow-job-key.ts", "../src/rules/no-invalid-template-file-pattern-regex.ts", "../src/rules/no-invalid-workflow-call-output-value.ts", "../src/_internal/dependabot-yaml.ts", "../src/rules/no-overlapping-dependabot-directories.ts", "../src/rules/no-path-separators-in-template-icon-name.ts", "../src/rules/no-post-if-without-post.ts", "../src/rules/no-pr-head-checkout-in-pull-request-target.ts", "../src/rules/no-pre-if-without-pre.ts", "../src/rules/no-required-input-with-default.ts", "../src/rules/no-secrets-in-if.ts", "../src/rules/no-self-hosted-runner-on-fork-pr-events.ts", "../src/rules/no-subdirectory-template-file-pattern.ts", "../src/rules/no-template-placeholder-in-non-template-workflow.ts", "../src/rules/no-top-level-env.ts", "../src/rules/no-top-level-permissions.ts", "../src/rules/no-universal-template-file-pattern.ts", "../src/rules/no-unknown-dependabot-multi-ecosystem-group.ts", "../src/rules/no-unknown-input-reference-in-composite.ts", "../src/rules/no-unknown-job-output-reference.ts", "../src/rules/no-unknown-step-reference.ts", "../src/rules/no-untrusted-input-in-run.ts", "../src/rules/no-unused-dependabot-enable-beta-ecosystems.ts", "../src/rules/no-unused-input-in-composite.ts", "../src/rules/no-write-all-permissions.ts", "../src/rules/pin-action-shas.ts", "../src/rules/prefer-action-yml.ts", "../src/rules/prefer-fail-fast.ts", "../src/rules/prefer-file-extension.ts", "../src/rules/prefer-inputs-context.ts", "../src/rules/prefer-step-uses-style.ts", "../src/rules/prefer-template-yml-extension.ts", "../src/rules/require-action-name.ts", "../src/rules/require-action-run-name.ts", "../src/rules/require-checkout-before-local-action.ts", "../src/_internal/workflow-permissions.ts", "../src/rules/require-codeql-actions-read.ts", "../src/rules/require-codeql-branch-filters.ts", "../src/rules/require-codeql-category-when-language-matrix.ts", "../src/rules/require-codeql-pull-request-trigger.ts", "../src/rules/require-codeql-schedule.ts", "../src/rules/require-codeql-security-events-write.ts", "../src/rules/require-composite-step-name.ts", "../src/rules/require-dependabot-assignees.ts", "../src/_internal/dependabot-automation-workflow.ts", "../src/rules/require-dependabot-automation-permissions.ts", "../src/rules/require-dependabot-automation-pull-request-trigger.ts", "../src/rules/require-dependabot-bot-actor-guard.ts", "../src/rules/require-dependabot-commit-message-include-scope.ts", "../src/rules/require-dependabot-commit-message-prefix-development.ts", "../src/rules/require-dependabot-commit-message-prefix.ts", "../src/rules/require-dependabot-cooldown.ts", "../src/rules/require-dependabot-directory.ts", "../src/rules/require-dependabot-github-actions-directory-root.ts", "../src/rules/require-dependabot-labels.ts", "../src/rules/require-dependabot-open-pull-requests-limit.ts", "../src/rules/require-dependabot-package-ecosystem.ts", "../src/rules/require-dependabot-patterns-for-multi-ecosystem-group.ts", "../src/rules/require-dependabot-schedule-cronjob.ts", "../src/rules/require-dependabot-schedule-interval.ts", "../src/rules/require-dependabot-schedule-time.ts", "../src/rules/require-dependabot-schedule-timezone.ts", "../src/rules/require-dependabot-target-branch.ts", "../src/rules/require-dependabot-updates.ts", "../src/rules/require-dependabot-version.ts", "../src/rules/require-dependabot-versioning-strategy-for-npm.ts", "../src/_internal/dependency-review-workflow.ts", "../src/rules/require-dependency-review-action.ts", "../src/rules/require-dependency-review-fail-on-severity.ts", "../src/rules/require-dependency-review-permissions-contents-read.ts", "../src/rules/require-dependency-review-pull-request-trigger.ts", "../src/rules/require-fetch-metadata-github-token.ts", "../src/rules/require-job-name.ts", "../src/rules/require-job-step-name.ts", "../src/rules/require-job-timeout-minutes.ts", "../src/rules/require-merge-group-trigger.ts", "../src/rules/require-pull-request-target-branches.ts", "../src/rules/require-run-step-shell.ts", "../src/rules/require-sarif-upload-security-events-write.ts", "../src/rules/require-scorecard-results-format-sarif.ts", "../src/rules/require-scorecard-upload-sarif-step.ts", "../src/_internal/secret-scanning-workflow.ts", "../src/rules/require-secret-scan-contents-read.ts", "../src/rules/require-secret-scan-fetch-depth-zero.ts", "../src/rules/require-secret-scan-schedule.ts", "../src/rules/require-template-categories.ts", "../src/rules/require-template-file-patterns.ts", "../src/rules/require-template-icon-file-exists.ts", "../src/rules/require-template-icon-name.ts", "../src/rules/require-template-workflow-name.ts", "../src/rules/require-trigger-types.ts", "../src/rules/require-trufflehog-verified-results-mode.ts", "../src/rules/require-workflow-call-input-type.ts", "../src/rules/require-workflow-call-output-value.ts", "../src/rules/require-workflow-concurrency.ts", "../src/rules/require-workflow-dispatch-input-type.ts", "../src/rules/require-workflow-interface-description.ts", "../src/rules/require-workflow-permissions.ts", "../src/rules/require-workflow-run-branches.ts", "../src/rules/require-workflow-template-pair.ts", "../src/rules/require-workflow-template-properties-pair.ts", "../src/rules/valid-timeout-minutes.ts", "../src/_internal/github-actions-trigger-events.ts", "../src/rules/valid-trigger-events.ts", "../src/_internal/rules-registry.ts"],
|
|
4
|
+
"sourcesContent": ["/**\n * @packageDocumentation\n * Public plugin entrypoint for eslint-plugin-github-actions-2.\n */\nimport type { ESLint, Linter, Rule } from \"eslint\";\n\nimport * as yamlParser from \"yaml-eslint-parser\";\n\nimport type { GithubActionsRuleDocs } from \"./_internal/rule-docs.js\";\n\nimport packageJson from \"../package.json\" with { type: \"json\" };\nimport {\n githubActionsConfigMetadataByName,\n type GithubActionsConfigName,\n githubActionsConfigNames,\n type GithubActionsConfigReference,\n githubActionsConfigReferenceToName,\n} from \"./_internal/github-actions-config-references.js\";\nimport { githubActionsRules } from \"./_internal/rules-registry.js\";\n\n/** ESLint severity used by generated preset rule maps. */\nconst ERROR_SEVERITY = \"error\" as const;\n\n/** Runtime type for the plugin's generated config presets. */\nexport type GithubActionsConfigs = Record<\n GithubActionsConfigName,\n GithubActionsPresetConfig\n>;\n\n/** Flat config shape produced by this plugin. */\nexport type GithubActionsPresetConfig = Linter.Config & {\n rules: NonNullable<Linter.Config[\"rules\"]>;\n};\n\n/** Fully-qualified ESLint rule ids exposed by this plugin. */\nexport type GithubActionsRuleId = `github-actions/${GithubActionsRuleName}`;\n\n/** Unqualified rule names supported by eslint-plugin-github-actions-2. */\nexport type GithubActionsRuleName = keyof typeof githubActionsRules;\n\n/** Fully assembled plugin contract used by the runtime default export. */\ntype GithubActionsPluginContract = Omit<\n ESLint.Plugin,\n \"configs\" | \"meta\" | \"rules\"\n> & {\n configs: GithubActionsConfigs;\n meta: {\n name: string;\n namespace: string;\n version: string;\n };\n rules: NonNullable<ESLint.Plugin[\"rules\"]>;\n};\n\n/** Rule-map type used when expanding preset memberships. */\ntype RulesConfig = GithubActionsPresetConfig[\"rules\"];\n\n/** Resolve package version from package.json data. */\nfunction getPackageVersion(pkg: unknown): string {\n if (typeof pkg !== \"object\" || pkg === null) {\n return \"0.0.0\";\n }\n\n const version = Reflect.get(pkg, \"version\");\n\n return typeof version === \"string\" ? version : \"0.0.0\";\n}\n\n/** Determine whether a string is a valid config-reference token. */\nconst isGithubActionsConfigReference = (\n value: string\n): value is GithubActionsConfigReference =>\n Object.hasOwn(githubActionsConfigReferenceToName, value);\n\n/** Normalize stored rule docs config references to a validated string array. */\nconst getRuleConfigReferences = (\n ruleName: GithubActionsRuleName,\n rule: Readonly<Rule.RuleModule>\n): readonly GithubActionsConfigReference[] => {\n const docs = rule.meta?.docs as GithubActionsRuleDocs | undefined;\n const references = docs?.configs;\n const referenceList = Array.isArray(references) ? references : [references];\n\n if (referenceList.length === 0 || referenceList[0] === undefined) {\n throw new TypeError(\n `Rule '${ruleName}' is missing docs.configs preset metadata.`\n );\n }\n\n for (const reference of referenceList) {\n if (\n typeof reference !== \"string\" ||\n !isGithubActionsConfigReference(reference)\n ) {\n throw new TypeError(\n `Rule '${ruleName}' has an invalid config reference '${String(reference)}'.`\n );\n }\n }\n\n return referenceList;\n};\n\n/** Strongly typed ESLint rule view of the internal registry. */\nconst githubActionsEslintRules: NonNullable<ESLint.Plugin[\"rules\"]> &\n typeof githubActionsRules = githubActionsRules as NonNullable<\n ESLint.Plugin[\"rules\"]\n> &\n typeof githubActionsRules;\n\n/** Stable rule-entry list used by config derivation and docs tests. */\nconst githubActionsRuleEntries: readonly (readonly [\n GithubActionsRuleName,\n Rule.RuleModule,\n])[] = Object.entries(githubActionsRules) as readonly (readonly [\n GithubActionsRuleName,\n Rule.RuleModule,\n])[];\n\n/** Build a config-to-rule-name map from rule docs metadata. */\nconst createPresetRuleNamesByConfig = (): Record<\n GithubActionsConfigName,\n GithubActionsRuleName[]\n> => {\n const presetRuleNamesByConfig: Record<\n GithubActionsConfigName,\n GithubActionsRuleName[]\n > = {\n actionMetadata: [],\n all: [],\n codeScanning: [],\n dependabot: [],\n recommended: [],\n security: [],\n strict: [],\n workflowTemplateProperties: [],\n workflowTemplates: [],\n };\n\n for (const [ruleName, rule] of githubActionsRuleEntries) {\n for (const reference of getRuleConfigReferences(ruleName, rule)) {\n const configName = githubActionsConfigReferenceToName[reference];\n\n if (configName === undefined) {\n continue;\n }\n\n presetRuleNamesByConfig[configName].push(ruleName);\n }\n }\n\n return presetRuleNamesByConfig;\n};\n\n/** Effective rule membership for every exported config preset. */\nconst presetRuleNamesByConfig: Readonly<\n Record<GithubActionsConfigName, readonly GithubActionsRuleName[]>\n> = createPresetRuleNamesByConfig();\n\n/** Build an ESLint rules map that enables each provided rule at error level. */\nfunction errorRulesFor(\n ruleNames: readonly GithubActionsRuleName[]\n): RulesConfig {\n const rules: RulesConfig = {};\n\n for (const ruleName of ruleNames) {\n rules[`github-actions/${ruleName}`] = ERROR_SEVERITY;\n }\n\n return rules;\n}\n\n/** Apply YAML parser and plugin registration to a preset config fragment. */\nfunction withGithubActionsPlugin(\n config: Readonly<GithubActionsPresetConfig>,\n plugin: Readonly<ESLint.Plugin>\n): GithubActionsPresetConfig {\n const existingLanguageOptions = config.languageOptions ?? {};\n const existingParserOptions = existingLanguageOptions[\"parserOptions\"];\n\n return {\n ...config,\n languageOptions: {\n ...existingLanguageOptions,\n parser: existingLanguageOptions[\"parser\"] ?? yamlParser,\n parserOptions:\n existingParserOptions !== null &&\n typeof existingParserOptions === \"object\" &&\n !Array.isArray(existingParserOptions)\n ? { ...existingParserOptions }\n : {},\n },\n plugins: {\n ...config.plugins,\n \"github-actions\": plugin,\n },\n };\n}\n\n/** Minimal plugin view used while assembling exported presets. */\nconst pluginForConfigs: ESLint.Plugin = {\n rules: githubActionsEslintRules,\n};\n\n/** Create every exported flat-config preset from static metadata. */\nconst createGithubActionsConfigsDefinition = (): GithubActionsConfigs => {\n const configs = {} as GithubActionsConfigs;\n\n for (const configName of githubActionsConfigNames) {\n const metadata = githubActionsConfigMetadataByName[configName];\n\n configs[configName] = withGithubActionsPlugin(\n {\n files: [...metadata.files],\n name: metadata.presetName,\n rules: errorRulesFor(presetRuleNamesByConfig[configName]),\n },\n pluginForConfigs\n );\n }\n\n return configs;\n};\n\n/** Finalized typed view of all exported flat-config presets. */\nconst githubActionsConfigs: GithubActionsConfigs =\n createGithubActionsConfigsDefinition();\n\n/** Main plugin object exported for ESLint consumption. */\nconst githubActionsPlugin: GithubActionsPluginContract = {\n configs: githubActionsConfigs,\n meta: {\n name: \"eslint-plugin-github-actions-2\",\n namespace: \"github-actions\",\n version: getPackageVersion(packageJson),\n },\n processors: {},\n rules: githubActionsEslintRules,\n};\n\n/** Runtime type for the plugin object exported as default. */\nexport type GithubActionsPlugin = typeof githubActionsPlugin;\n\n/** Default plugin export consumed by ESLint flat config. */\nexport default githubActionsPlugin;\n", "{\n \"$schema\": \"https://www.schemastore.org/package.json\",\n \"name\": \"eslint-plugin-github-actions-2\",\n \"version\": \"1.0.4\",\n \"private\": false,\n \"description\": \"ESLint plugin for GitHub Actions workflow quality, reliability, and security rules.\",\n \"keywords\": [\n \"eslint\",\n \"eslint-plugin\",\n \"eslintplugin\",\n \"github\",\n \"github-actions\",\n \"workflow\",\n \"yaml\"\n ],\n \"homepage\": \"https://github.com/Nick2bad4u/eslint-plugin-github-actions-2\",\n \"bugs\": {\n \"url\": \"https://github.com/Nick2bad4u/eslint-plugin-github-actions-2/issues\",\n \"email\": \"20943337+Nick2bad4u@users.noreply.github.com\"\n },\n \"repository\": {\n \"type\": \"git\",\n \"url\": \"git+https://github.com/Nick2bad4u/eslint-plugin-github-actions-2.git\"\n },\n \"license\": \"MIT\",\n \"author\": \"Nick2bad4u <20943337+Nick2bad4u@users.noreply.github.com> (https://github.com/Nick2bad4u)\",\n \"contributors\": [\n {\n \"name\": \"Nick2bad4u\",\n \"email\": \"20943337+Nick2bad4u@users.noreply.github.com\",\n \"url\": \"https://github.com/Nick2bad4u\"\n }\n ],\n \"sideEffects\": false,\n \"type\": \"module\",\n \"exports\": {\n \".\": {\n \"import\": {\n \"types\": \"./dist/plugin.d.ts\",\n \"default\": \"./dist/plugin.js\"\n },\n \"require\": {\n \"types\": \"./dist/plugin.d.cts\",\n \"default\": \"./dist/plugin.cjs\"\n },\n \"default\": \"./dist/plugin.js\"\n },\n \"./package.json\": \"./package.json\"\n },\n \"main\": \"./dist/plugin.cjs\",\n \"types\": \"./dist/plugin.d.ts\",\n \"files\": [\n \"dist\",\n \"docs/rules/**\",\n \"CHANGELOG.md\"\n ],\n \"workspaces\": [\n \"docs/docusaurus\"\n ],\n \"scripts\": {\n \"build\": \"tsc -p tsconfig.build.json && npm run build:types:cjs && npm run build:cjs\",\n \"build:cjs\": \"esbuild dist/plugin.js --bundle --format=cjs --platform=node --packages=external --sourcemap --outfile=dist/plugin.cjs --footer:js=\\\"module.exports = module.exports.default;\\\"\",\n \"build:clean\": \"node -e \\\"require('node:fs').rmSync('dist',{recursive:true,force:true})\\\"\",\n \"build:eslint-inspector\": \"npx -y @eslint/config-inspector@1.4.2 build --outDir \\\"docs/docusaurus/static/eslint-inspector\\\" --base \\\"/eslint-plugin-github-actions-2/eslint-inspector/\\\"\",\n \"build:eslint-inspector:local\": \"npx @eslint/config-inspector\",\n \"build:stylelint-inspector\": \"npx -y stylelint-config-inspector@latest build --outDir \\\"docs/docusaurus/static/stylelint-inspector\\\" --base \\\"/eslint-plugin-github-actions-2/stylelint-inspector/\\\"\",\n \"build:stylelint-inspector:local\": \"npx stylelint-config-inspector@latest\",\n \"build:types:cjs\": \"node -e \\\"require('node:fs').copyFileSync('dist/plugin.d.ts','dist/plugin.d.cts')\\\"\",\n \"changelog:release-notes\": \"git-cliff --config cliff.toml --latest --strip header\",\n \"clean:cache\": \"rimraf dist coverage cache .cache .vite .turbo\",\n \"clean:cache:coverage\": \"rimraf coverage .coverage\",\n \"clean:cache:dist\": \"rimraf dist release\",\n \"clean:cache:eslint\": \"rimraf .cache/.eslintcache\",\n \"clean:cache:prettier\": \"rimraf .cache/.prettier-cache .prettier-cache .prettiercache\",\n \"clean:cache:stylelint\": \"rimraf .cache/stylelintcache stylelintcache .stylelintcache\",\n \"clean:cache:typescript\": \"rimraf .cache/**.tsbuildinfo .cache/builds\",\n \"clean:cache:vite\": \"rimraf .cache/vite .cache/vitest .cache/vitest-zero-coverage .cache/vite-zero-coverage\",\n \"clean:docs\": \"rimraf docs/docusaurus/.docusaurus/** docs/docusaurus/build/**\",\n \"clean:docusaurus\": \"npm run clean:docs && npm run --workspace docs/docusaurus clear\",\n \"docs:api\": \"npm run --workspace docs/docusaurus docs:api\",\n \"docs:api:local\": \"npm run --workspace docs/docusaurus docs:api:local\",\n \"docs:build\": \"npm run --workspace docs/docusaurus build\",\n \"docs:build:local\": \"npm run --workspace docs/docusaurus build:local\",\n \"docs:serve\": \"npm run --workspace docs/docusaurus serve\",\n \"docs:start\": \"npm run --workspace docs/docusaurus start\",\n \"docs:start:devtools\": \"npm run docs:api:local && npm run --workspace docs/docusaurus start:devtools\",\n \"docs:typecheck\": \"npm run --workspace docs/docusaurus typecheck\",\n \"lint\": \"cross-env NODE_OPTIONS=--max_old_space_size=16384 eslint --cache --cache-strategy content --cache-location .cache/.eslintcache\",\n \"lint:action\": \"npm run lint:actions\",\n \"lint:actions\": \"node scripts/lint-actionlint.mjs\",\n \"lint:all\": \"npm run lint && npm run lint:css && npm run lint:prettier && npm run lint:remark && npm run lint:package && npm run lint:secretlint && npm run lint:yaml && npm run lint:actions && npm run lint:circular\",\n \"lint:all:fix\": \"npm run lint:fix && npm run lint:css:fix && npm run lint:prettier:fix && npm run lint:remark && npm run lint:package && npm run lint:secretlint && npm run lint:yaml:fix && npm run lint:actions && npm run lint:circular\",\n \"lint:all:fix:quiet\": \"npm run lint:fix:quiet && npm run lint:css:fix && npm run lint:prettier:fix && npm run lint:remark && npm run lint:package && npm run lint:secretlint && npm run lint:yaml:fix && npm run lint:actions && npm run lint:circular\",\n \"lint:circular\": \"npm run madge:circular\",\n \"lint:compat\": \"npm run lint:compat:eslint9 --\",\n \"lint:compat:eslint9\": \"node scripts/lint-compat-eslint9.mjs\",\n \"lint:config:build\": \"npm run build:eslint-inspector\",\n \"lint:config:inspect\": \"npx eslint --inspect-config\",\n \"lint:css\": \"stylelint --cache --config stylelint.config.mjs --cache-strategy content --cache-location .cache/stylelintcache src/ docs/ --custom-formatter stylelint-formatter-pretty && echo \\\"Stylelint done!\\\"\",\n \"lint:css:fix\": \"stylelint --cache --config stylelint.config.mjs --cache-strategy content --cache-location .cache/stylelintcache src/ docs/ --custom-formatter stylelint-formatter-pretty --fix && echo \\\"Stylelint done!\\\"\",\n \"lint:fix\": \"cross-env NODE_OPTIONS=--max_old_space_size=16384 eslint --cache --cache-strategy content --cache-location .cache/.eslintcache --fix\",\n \"lint:fix:quiet\": \"cross-env ESLINT_PROGRESS=off NODE_OPTIONS=--max_old_space_size=16384 eslint --cache --cache-strategy content --cache-location .cache/.eslintcache --fix && echo \\\"Eslint fix done!\\\"\",\n \"lint:grype\": \"grype . -c .grype.yaml --name eslint-plugin-github-actions-2\",\n \"lint:package\": \"npm run lint:package-sort && npm run lint:packagelintrc && echo \\\"Package.json lint done!\\\"\",\n \"lint:package-check\": \"publint && attw --pack .\",\n \"lint:package-sort\": \"sort-package-json \\\"./package.json\\\" \\\"./docs/docusaurus/package.json\\\"\",\n \"lint:package-sort-check\": \"sort-package-json --check \\\"./package.json\\\" \\\"./docs/docusaurus/package.json\\\"\",\n \"lint:packagelintrc\": \"npmPkgJsonLint . --config .npmpackagejsonlintrc.json\",\n \"lint:prettier\": \"prettier . --log-level warn --cache --cache-location=.cache/.prettier-cache --cache-strategy=content --check\",\n \"lint:prettier:fix\": \"prettier . --log-level warn --cache --cache-location=.cache/.prettier-cache --cache-strategy=content --write\",\n \"lint:quiet\": \"cross-env ESLINT_PROGRESS=nofile NODE_OPTIONS=--max_old_space_size=16384 eslint --cache --cache-strategy content --cache-location .cache/.eslintcache && echo \\\"Eslint done!\\\"\",\n \"lint:remark\": \"remark --rc-path .remarkrc.mjs --silently-ignore --ignore-path .remarkignore --frail \\\"*.{md,mdx}\\\" \\\"docs/**/*.{md,mdx}\\\" --quiet\",\n \"lint:remark:fix\": \"prettier --log-level warn --ignore-path prettierignore.remark --cache --cache-location=.cache/.prettier-cache --cache-strategy=content --no-error-on-unmatched-pattern --write \\\"*.{md,mdx}\\\" \\\"docs/**/*.{md,mdx}\\\" && npm run remark:fix\",\n \"lint:secretlint\": \"secretlint --secretlintrc .secretlintrc.json --secretlintignore .secretlintignore \\\"./*\\\" \\\".vscode/**\\\" \\\"assets/**\\\" \\\"src/**\\\" \\\"electron/**\\\" \\\"shared/**\\\" \\\"config/**\\\" \\\"scripts/**\\\" \\\"playwright/**\\\" \\\"storybook/**\\\" \\\".storybook\\\" \\\"tests/**\\\" \\\"benchmarks/**\\\" \\\".devin/**\\\" \\\"public/**\\\" \\\".github/**\\\" \\\"docs/Architecture/**\\\" \\\"docs/*\\\" \\\"docs/assets/**\\\" \\\"docs/Guides/**\\\" \\\"docs/Testing/**\\\" \\\"docs/TSDoc/**\\\" \\\"docs/docusaurus/src/**\\\" \\\"docs/docusaurus/static/**\\\" \\\"docs/docusaurus/blog/**\\\" \\\"docs/docusaurus/docs/**\\\" \\\"docs/docusaurus/docs/*\\\"\",\n \"lint:yaml\": \"cross-env NODE_OPTIONS=--max_old_space_size=16384 eslint --cache --cache-strategy content --cache-location .cache/.eslintcache \\\"**/*.{yml,yaml}\\\" && echo \\\"YAML lint done!\\\"\",\n \"lint:yaml:fix\": \"cross-env NODE_OPTIONS=--max_old_space_size=16384 eslint --cache --cache-strategy content --cache-location .cache/.eslintcache --fix \\\"**/*.{yml,yaml}\\\" && echo \\\"YAML lint (fix) done!\\\"\",\n \"madge:circular\": \"madge --circular --no-spinner --ts-config tsconfig.json --extensions ts,tsx,js,jsx,mjs,cjs,cts,mts ./src --exclude \\\"(^|[\\\\/])(test|dist|node_modules|cache|.cache|coverage|build|eslint-inspector|temp|.docusaurus)($|[\\\\/])|\\\\.css$\\\"\",\n \"prepublishOnly\": \"npm run release:verify\",\n \"release:check\": \"npm run release:verify\",\n \"release:verify\": \"npm run build && npm run lint && npm run typecheck && npm run test && npm run docs:build && npm pack --dry-run\",\n \"remark:fix\": \"remark --rc-path .remarkrc.mjs --silently-ignore --ignore-path .remarkignore --frail --quiet --output -- \\\"*.{md,mdx}\\\" \\\"docs/**/*.{md,mdx}\\\"\",\n \"sync:peer-eslint-range\": \"node scripts/sync-peer-eslint-range.mjs\",\n \"sync:readme-rules-table\": \"node scripts/sync-readme-rules-table.mjs\",\n \"sync:readme-rules-table:write\": \"node scripts/sync-readme-rules-table.mjs --write\",\n \"pretest\": \"npm run build\",\n \"test\": \"vitest run\",\n \"test:ci\": \"cross-env CI=true vitest run --reporter=default\",\n \"test:coverage\": \"vitest run --coverage --reporter=default\",\n \"test:quiet\": \"vitest run --reporter=default --silent\",\n \"test:serial\": \"cross-env MAX_THREADS=1 vitest run\",\n \"test:verbose\": \"vitest run --reporter=verbose\",\n \"test:watch\": \"vitest\",\n \"typecheck\": \"tsc -p tsconfig.json --noEmit && tsc -p tsconfig.build.json --noEmit && tsc -p tsconfig.eslint.json --noEmit && tsc -p tsconfig.js.json --noEmit && npm run --workspace docs/docusaurus typecheck\",\n \"update-deps\": \"npx ncu -i --install never && npm run sync:peer-eslint-range && npm install --force\",\n \"verify:readme-rules-table\": \"npm run build && npm run sync:readme-rules-table\"\n },\n \"dependencies\": {\n \"yaml-eslint-parser\": \"^2.0.0\"\n },\n \"devDependencies\": {\n \"@arethetypeswrong/cli\": \"^0.18.2\",\n \"@csstools/stylelint-formatter-github\": \"^2.0.0\",\n \"@docusaurus/eslint-plugin\": \"^3.9.2\",\n \"@double-great/remark-lint-alt-text\": \"^1.1.1\",\n \"@double-great/stylelint-a11y\": \"^3.4.9\",\n \"@eslint-community/eslint-plugin-eslint-comments\": \"^4.7.1\",\n \"@eslint-react/eslint-plugin\": \"^4.2.3\",\n \"@eslint/compat\": \"^2.0.4\",\n \"@eslint/config-helpers\": \"^0.5.4\",\n \"@eslint/config-inspector\": \"^1.5.0\",\n \"@eslint/css\": \"^1.1.0\",\n \"@eslint/js\": \"^10.0.1\",\n \"@eslint/json\": \"^1.2.0\",\n \"@eslint/markdown\": \"^8.0.1\",\n \"@html-eslint/eslint-plugin\": \"^0.58.1\",\n \"@html-eslint/parser\": \"^0.58.1\",\n \"@microsoft/eslint-plugin-sdl\": \"^1.1.0\",\n \"@microsoft/tsdoc-config\": \"^0.18.1\",\n \"@secretlint/secretlint-rule-anthropic\": \"^11.5.0\",\n \"@secretlint/secretlint-rule-aws\": \"^11.5.0\",\n \"@secretlint/secretlint-rule-database-connection-string\": \"^11.5.0\",\n \"@secretlint/secretlint-rule-gcp\": \"^11.5.0\",\n \"@secretlint/secretlint-rule-github\": \"^11.5.0\",\n \"@secretlint/secretlint-rule-no-dotenv\": \"^11.5.0\",\n \"@secretlint/secretlint-rule-no-homedir\": \"^11.5.0\",\n \"@secretlint/secretlint-rule-npm\": \"^11.5.0\",\n \"@secretlint/secretlint-rule-openai\": \"^11.5.0\",\n \"@secretlint/secretlint-rule-pattern\": \"^11.5.0\",\n \"@secretlint/secretlint-rule-preset-recommend\": \"^11.4.1\",\n \"@secretlint/secretlint-rule-privatekey\": \"^11.5.0\",\n \"@secretlint/secretlint-rule-secp256k1-privatekey\": \"^11.5.0\",\n \"@secretlint/types\": \"^11.5.0\",\n \"@softonus/prettier-plugin-duplicate-remover\": \"^1.1.2\",\n \"@stryker-ignorer/console-all\": \"^0.3.2\",\n \"@stryker-mutator/core\": \"^9.6.0\",\n \"@stryker-mutator/typescript-checker\": \"^9.6.0\",\n \"@stryker-mutator/vitest-runner\": \"^9.6.0\",\n \"@stylelint-types/stylelint-order\": \"^7.0.1\",\n \"@stylelint-types/stylelint-stylistic\": \"^5.0.0\",\n \"@stylistic/eslint-plugin\": \"^5.10.0\",\n \"@stylistic/stylelint-plugin\": \"^5.1.0\",\n \"@types/eslint-plugin-jsx-a11y\": \"^6.10.1\",\n \"@types/eslint-plugin-security\": \"^3.0.1\",\n \"@types/htmlhint\": \"^1.1.5\",\n \"@types/madge\": \"^5.0.3\",\n \"@types/node\": \"^25.5.2\",\n \"@types/postcss-clamp\": \"^4.1.3\",\n \"@types/postcss-flexbugs-fixes\": \"^5.0.3\",\n \"@types/postcss-html\": \"^1.5.3\",\n \"@types/postcss-import\": \"^14.0.3\",\n \"@types/postcss-inline-svg\": \"^5.0.4\",\n \"@types/postcss-normalize\": \"^9.0.4\",\n \"@types/postcss-reporter\": \"^7.0.5\",\n \"@types/sloc\": \"^0.2.3\",\n \"@typescript-eslint/eslint-plugin\": \"^8.58.0\",\n \"@typescript-eslint/parser\": \"^8.58.0\",\n \"@typescript-eslint/rule-tester\": \"^8.58.0\",\n \"@vitest/coverage-v8\": \"^4.1.2\",\n \"@vitest/eslint-plugin\": \"^1.6.14\",\n \"@vitest/ui\": \"^4.1.2\",\n \"actionlint\": \"^2.0.6\",\n \"all-contributors-cli\": \"^6.26.1\",\n \"cognitive-complexity-ts\": \"^0.8.1\",\n \"commitlint\": \"^20.5.0\",\n \"commitlint-config-gitmoji\": \"^2.3.1\",\n \"cross-env\": \"^10.1.0\",\n \"depcheck\": \"^1.4.7\",\n \"detect-secrets\": \"^1.0.6\",\n \"eslint\": \"^10.2.0\",\n \"eslint-config-flat-gitignore\": \"^2.3.0\",\n \"eslint-config-prettier\": \"^10.1.8\",\n \"eslint-formatter-unix\": \"^9.0.1\",\n \"eslint-import-resolver-typescript\": \"^4.4.4\",\n \"eslint-plugin-array-func\": \"^5.1.1\",\n \"eslint-plugin-canonical\": \"^5.1.3\",\n \"eslint-plugin-case-police\": \"^2.2.0\",\n \"eslint-plugin-comment-length\": \"^2.3.0\",\n \"eslint-plugin-css-modules\": \"^2.12.0\",\n \"eslint-plugin-de-morgan\": \"^2.1.1\",\n \"eslint-plugin-depend\": \"^1.5.0\",\n \"eslint-plugin-eslint-plugin\": \"^7.3.2\",\n \"eslint-plugin-etc\": \"^2.0.3\",\n \"eslint-plugin-etc-misc\": \"^1.0.5\",\n \"eslint-plugin-file-progress-2\": \"^3.4.4\",\n \"eslint-plugin-html\": \"^8.1.4\",\n \"eslint-plugin-import-x\": \"^4.16.2\",\n \"eslint-plugin-jsdoc\": \"^62.9.0\",\n \"eslint-plugin-jsonc\": \"^3.1.2\",\n \"eslint-plugin-jsx-a11y\": \"^6.10.2\",\n \"eslint-plugin-listeners\": \"^1.5.1\",\n \"eslint-plugin-math\": \"^0.13.1\",\n \"eslint-plugin-module-interop\": \"^0.3.1\",\n \"eslint-plugin-n\": \"^17.24.0\",\n \"eslint-plugin-nitpick\": \"^0.12.0\",\n \"eslint-plugin-no-barrel-files\": \"^1.2.2\",\n \"eslint-plugin-no-function-declare-after-return\": \"^1.1.0\",\n \"eslint-plugin-no-lookahead-lookbehind-regexp\": \"^0.4.0\",\n \"eslint-plugin-no-only-tests\": \"^3.3.0\",\n \"eslint-plugin-no-secrets\": \"^2.3.3\",\n \"eslint-plugin-no-unsanitized\": \"^4.1.5\",\n \"eslint-plugin-no-use-extend-native\": \"^0.7.2\",\n \"eslint-plugin-node-dependencies\": \"^2.2.0\",\n \"eslint-plugin-package-json\": \"^0.91.1\",\n \"eslint-plugin-perfectionist\": \"^5.8.0\",\n \"eslint-plugin-prefer-arrow\": \"^1.2.3\",\n \"eslint-plugin-prettier\": \"^5.5.5\",\n \"eslint-plugin-promise\": \"^7.2.1\",\n \"eslint-plugin-redos\": \"^4.5.0\",\n \"eslint-plugin-regexp\": \"^3.1.0\",\n \"eslint-plugin-require-jsdoc\": \"^1.0.4\",\n \"eslint-plugin-security\": \"^4.0.0\",\n \"eslint-plugin-sonarjs\": \"^4.0.2\",\n \"eslint-plugin-testing-library\": \"^7.16.2\",\n \"eslint-plugin-toml\": \"^1.3.1\",\n \"eslint-plugin-tsdoc\": \"^0.5.2\",\n \"eslint-plugin-tsdoc-require-2\": \"^1.0.7\",\n \"eslint-plugin-undefined-css-classes\": \"^0.1.5\",\n \"eslint-plugin-unicorn\": \"^64.0.0\",\n \"eslint-plugin-unused-imports\": \"^4.4.1\",\n \"eslint-plugin-write-good-comments\": \"^0.2.0\",\n \"eslint-plugin-yml\": \"^3.3.1\",\n \"fast-check\": \"^4.6.0\",\n \"git-cliff\": \"^2.12.0\",\n \"gitleaks-secret-scanner\": \"^2.1.1\",\n \"globals\": \"^17.4.0\",\n \"htmlhint\": \"^1.9.2\",\n \"jscpd\": \"^4.0.8\",\n \"jsonc-eslint-parser\": \"^3.1.0\",\n \"knip\": \"^6.3.0\",\n \"leasot\": \"^14.4.0\",\n \"madge\": \"^8.0.0\",\n \"markdown-link-check\": \"^3.14.2\",\n \"npm-check-updates\": \"^20.0.0\",\n \"npm-package-json-lint\": \"^10.0.0\",\n \"picocolors\": \"^1.1.1\",\n \"postcss\": \"^8.5.8\",\n \"postcss-assets\": \"^6.0.0\",\n \"postcss-clamp\": \"^4.1.0\",\n \"postcss-combine-duplicated-selectors\": \"^10.0.3\",\n \"postcss-flexbugs-fixes\": \"^5.0.2\",\n \"postcss-html\": \"^1.8.1\",\n \"postcss-import\": \"^16.1.1\",\n \"postcss-inline-svg\": \"^6.0.0\",\n \"postcss-logical\": \"^9.0.0\",\n \"postcss-normalize\": \"^13.0.1\",\n \"postcss-reporter\": \"^7.1.0\",\n \"postcss-round-subpixels\": \"^2.0.0\",\n \"postcss-scss\": \"^4.0.9\",\n \"postcss-sort-media-queries\": \"^6.3.3\",\n \"postcss-styled-jsx\": \"^1.0.1\",\n \"postcss-styled-syntax\": \"^0.7.1\",\n \"postcss-viewport-height-correction\": \"^1.1.1\",\n \"prettier\": \"^3.8.1\",\n \"prettier-plugin-ini\": \"^1.3.0\",\n \"prettier-plugin-interpolated-html-tags\": \"^2.0.1\",\n \"prettier-plugin-jsdoc\": \"^1.8.0\",\n \"prettier-plugin-jsdoc-type\": \"^0.2.0\",\n \"prettier-plugin-merge\": \"^0.10.1\",\n \"prettier-plugin-multiline-arrays\": \"^4.1.5\",\n \"prettier-plugin-packagejson\": \"^3.0.2\",\n \"prettier-plugin-properties\": \"^0.3.1\",\n \"prettier-plugin-sort-json\": \"^4.2.0\",\n \"prettier-plugin-toml\": \"^2.0.6\",\n \"publint\": \"^0.3.18\",\n \"recheck-jar\": \"^4.5.0\",\n \"rehype-katex\": \"^7.0.1\",\n \"remark\": \"^15.0.1\",\n \"remark-cli\": \"^12.0.1\",\n \"remark-directive\": \"^4.0.0\",\n \"remark-frontmatter\": \"^5.0.0\",\n \"remark-gfm\": \"^4.0.1\",\n \"remark-ignore\": \"^3.0.0\",\n \"remark-inline-links\": \"^7.0.0\",\n \"remark-lint\": \"^10.0.1\",\n \"remark-lint-blockquote-indentation\": \"^4.0.1\",\n \"remark-lint-check-toc\": \"^1.0.0\",\n \"remark-lint-checkbox-character-style\": \"^5.0.1\",\n \"remark-lint-checkbox-content-indent\": \"^5.0.1\",\n \"remark-lint-code-block-split-list\": \"^1.0.0\",\n \"remark-lint-code-block-style\": \"^4.0.1\",\n \"remark-lint-correct-media-syntax\": \"^1.0.1\",\n \"remark-lint-definition-case\": \"^4.0.1\",\n \"remark-lint-definition-sort\": \"^1.0.1\",\n \"remark-lint-definition-spacing\": \"^4.0.1\",\n \"remark-lint-directive-attribute-sort\": \"^1.0.1\",\n \"remark-lint-directive-collapsed-attribute\": \"^1.0.1\",\n \"remark-lint-directive-quote-style\": \"^1.0.1\",\n \"remark-lint-directive-shortcut-attribute\": \"^1.0.1\",\n \"remark-lint-directive-unique-attribute-name\": \"^1.0.1\",\n \"remark-lint-emphasis-marker\": \"^4.0.1\",\n \"remark-lint-fenced-code-flag\": \"^4.2.0\",\n \"remark-lint-fenced-code-flag-case\": \"^3.0.0\",\n \"remark-lint-fenced-code-marker\": \"^4.0.1\",\n \"remark-lint-file-extension\": \"^3.0.1\",\n \"remark-lint-final-definition\": \"^4.0.2\",\n \"remark-lint-final-newline\": \"^3.0.1\",\n \"remark-lint-first-heading-level\": \"^4.0.1\",\n \"remark-lint-frontmatter-schema\": \"^3.15.4\",\n \"remark-lint-hard-break-spaces\": \"^4.1.1\",\n \"remark-lint-heading-capitalization\": \"^1.3.0\",\n \"remark-lint-heading-increment\": \"^4.0.1\",\n \"remark-lint-heading-style\": \"^4.0.1\",\n \"remark-lint-heading-whitespace\": \"^1.0.0\",\n \"remark-lint-linebreak-style\": \"^4.0.1\",\n \"remark-lint-link-title-style\": \"^4.0.1\",\n \"remark-lint-list-item-bullet-indent\": \"^5.0.1\",\n \"remark-lint-list-item-content-indent\": \"^4.0.1\",\n \"remark-lint-list-item-indent\": \"^4.0.1\",\n \"remark-lint-list-item-spacing\": \"^5.0.1\",\n \"remark-lint-maximum-heading-length\": \"^4.1.1\",\n \"remark-lint-maximum-line-length\": \"^4.1.1\",\n \"remark-lint-mdx-jsx-attribute-sort\": \"^1.0.1\",\n \"remark-lint-mdx-jsx-no-void-children\": \"^1.0.1\",\n \"remark-lint-mdx-jsx-quote-style\": \"^1.0.1\",\n \"remark-lint-mdx-jsx-self-close\": \"^1.0.1\",\n \"remark-lint-mdx-jsx-shorthand-attribute\": \"^1.0.1\",\n \"remark-lint-mdx-jsx-unique-attribute-name\": \"^1.0.1\",\n \"remark-lint-media-style\": \"^1.0.1\",\n \"remark-lint-no-blockquote-without-marker\": \"^6.0.1\",\n \"remark-lint-no-consecutive-blank-lines\": \"^5.0.1\",\n \"remark-lint-no-dead-urls\": \"^2.0.1\",\n \"remark-lint-no-duplicate-defined-urls\": \"^3.0.1\",\n \"remark-lint-no-duplicate-definitions\": \"^4.0.1\",\n \"remark-lint-no-duplicate-headings\": \"^4.0.1\",\n \"remark-lint-no-duplicate-headings-in-section\": \"^4.0.1\",\n \"remark-lint-no-emphasis-as-heading\": \"^4.0.1\",\n \"remark-lint-no-empty-sections\": \"^4.0.0\",\n \"remark-lint-no-empty-url\": \"^4.0.1\",\n \"remark-lint-no-file-name-articles\": \"^3.0.1\",\n \"remark-lint-no-file-name-consecutive-dashes\": \"^3.0.1\",\n \"remark-lint-no-file-name-irregular-characters\": \"^3.0.1\",\n \"remark-lint-no-file-name-mixed-case\": \"^3.0.1\",\n \"remark-lint-no-file-name-outer-dashes\": \"^3.0.1\",\n \"remark-lint-no-heading-content-indent\": \"^5.0.1\",\n \"remark-lint-no-heading-indent\": \"^5.0.1\",\n \"remark-lint-no-heading-like-paragraph\": \"^4.0.1\",\n \"remark-lint-no-heading-punctuation\": \"^4.0.1\",\n \"remark-lint-no-hidden-table-cell\": \"^1.0.1\",\n \"remark-lint-no-html\": \"^4.0.1\",\n \"remark-lint-no-literal-urls\": \"^4.0.1\",\n \"remark-lint-no-missing-blank-lines\": \"^4.0.1\",\n \"remark-lint-no-multiple-toplevel-headings\": \"^4.0.1\",\n \"remark-lint-no-paragraph-content-indent\": \"^5.0.1\",\n \"remark-lint-no-reference-like-url\": \"^4.0.1\",\n \"remark-lint-no-shell-dollars\": \"^4.0.1\",\n \"remark-lint-no-shortcut-reference-image\": \"^4.0.1\",\n \"remark-lint-no-shortcut-reference-link\": \"^4.0.1\",\n \"remark-lint-no-table-indentation\": \"^5.0.1\",\n \"remark-lint-no-tabs\": \"^4.0.1\",\n \"remark-lint-no-undefined-references\": \"^5.0.2\",\n \"remark-lint-no-unneeded-full-reference-image\": \"^4.0.1\",\n \"remark-lint-no-unneeded-full-reference-link\": \"^4.0.1\",\n \"remark-lint-no-unused-definitions\": \"^4.0.2\",\n \"remark-lint-ordered-list-marker-style\": \"^4.0.1\",\n \"remark-lint-ordered-list-marker-value\": \"^4.0.1\",\n \"remark-lint-rule-style\": \"^4.0.1\",\n \"remark-lint-strikethrough-marker\": \"^3.0.1\",\n \"remark-lint-strong-marker\": \"^4.0.1\",\n \"remark-lint-table-cell-padding\": \"^5.1.1\",\n \"remark-lint-table-pipe-alignment\": \"^4.1.1\",\n \"remark-lint-table-pipes\": \"^5.0.1\",\n \"remark-lint-unordered-list-marker-style\": \"^4.0.1\",\n \"remark-lint-write-good\": \"^1.2.0\",\n \"remark-math\": \"^6.0.0\",\n \"remark-preset-lint-consistent\": \"^6.0.1\",\n \"remark-preset-lint-markdown-style-guide\": \"^6.0.1\",\n \"remark-preset-lint-recommended\": \"^7.0.1\",\n \"remark-preset-prettier\": \"^2.0.2\",\n \"remark-toc\": \"^9.0.0\",\n \"remark-validate-links\": \"^13.1.0\",\n \"remark-wiki-link\": \"^2.0.1\",\n \"rimraf\": \"^6.1.3\",\n \"secretlint\": \"^11.4.1\",\n \"sloc\": \"^0.3.2\",\n \"sort-package-json\": \"^3.6.1\",\n \"stylelint\": \"^17.6.0\",\n \"stylelint-actions-formatters\": \"^16.3.1\",\n \"stylelint-checkstyle-formatter\": \"^0.1.2\",\n \"stylelint-codeframe-formatter\": \"^1.2.0\",\n \"stylelint-config-alphabetical-order\": \"^2.0.0\",\n \"stylelint-config-idiomatic-order\": \"^10.0.0\",\n \"stylelint-config-inspector\": \"^2.0.3\",\n \"stylelint-config-recess-order\": \"^7.7.0\",\n \"stylelint-config-recommended\": \"^18.0.0\",\n \"stylelint-config-sass-guidelines\": \"^13.0.0\",\n \"stylelint-config-standard\": \"^40.0.0\",\n \"stylelint-config-standard-scss\": \"^17.0.0\",\n \"stylelint-config-tailwindcss\": \"^1.0.1\",\n \"stylelint-declaration-block-no-ignored-properties\": \"^3.0.0\",\n \"stylelint-declaration-strict-value\": \"^1.11.1\",\n \"stylelint-define-config\": \"^17.5.0\",\n \"stylelint-find-new-rules\": \"^6.0.0\",\n \"stylelint-formatter-gitlab-code-quality-report\": \"^1.1.0\",\n \"stylelint-formatter-pretty\": \"^4.0.1\",\n \"stylelint-gamut\": \"^2.0.0\",\n \"stylelint-group-selectors\": \"^1.0.10\",\n \"stylelint-high-performance-animation\": \"^2.0.0\",\n \"stylelint-media-use-custom-media\": \"^4.1.0\",\n \"stylelint-no-browser-hacks\": \"^2.0.0\",\n \"stylelint-no-indistinguishable-colors\": \"^2.3.1\",\n \"stylelint-no-restricted-syntax\": \"^2.2.1\",\n \"stylelint-no-unresolved-module\": \"^2.5.2\",\n \"stylelint-no-unsupported-browser-features\": \"^8.1.1\",\n \"stylelint-order\": \"^8.1.1\",\n \"stylelint-plugin-defensive-css\": \"^2.8.1\",\n \"stylelint-plugin-logical-css\": \"^2.1.0\",\n \"stylelint-plugin-use-baseline\": \"^1.4.1\",\n \"stylelint-prettier\": \"^5.0.3\",\n \"stylelint-react-native\": \"^2.7.0\",\n \"stylelint-scales\": \"^5.0.0\",\n \"stylelint-selector-bem-pattern\": \"^4.0.1\",\n \"stylelint-use-nesting\": \"^6.0.2\",\n \"stylelint-value-no-unknown-custom-properties\": \"^6.1.1\",\n \"toml-eslint-parser\": \"^1.0.3\",\n \"ts-unused-exports\": \"^11.0.1\",\n \"typedoc\": \"^0.28.18\",\n \"typescript\": \"^6.0.2\",\n \"typescript-eslint\": \"^8.58.0\",\n \"typesync\": \"^0.14.3\",\n \"vfile\": \"^6.0.3\",\n \"vite\": \"^8.0.3\",\n \"vite-tsconfig-paths\": \"^6.1.1\",\n \"vitest\": \"^4.1.2\",\n \"yamllint-js\": \"^0.2.4\"\n },\n \"peerDependencies\": {\n \"eslint\": \"^9.0.0 || ^10.2.0\"\n },\n \"packageManager\": \"npm@11.12.1\",\n \"engines\": {\n \"node\": \">=22.0.0\"\n },\n \"devEngines\": {\n \"runtime\": {\n \"name\": \"node\",\n \"version\": \">=22.0.0\",\n \"onFail\": \"error\"\n },\n \"packageManager\": {\n \"name\": \"npm\",\n \"version\": \">=11.0.0\",\n \"onFail\": \"error\"\n }\n },\n \"publishConfig\": {\n \"provenance\": true,\n \"registry\": \"https://registry.npmjs.org/\"\n },\n \"readme\": \"README.md\"\n}\n", "/**\n * @packageDocumentation\n * Shared filename target helpers for action metadata and workflow templates.\n */\nimport { basename, extname } from \"node:path\";\n\n/** Action metadata file globs. */\nexport const ACTION_METADATA_FILE_GLOBS: readonly string[] = [\n \"**/action.{yml,yaml}\",\n];\n\n/** Dependabot configuration file globs. */\nexport const DEPENDABOT_FILE_GLOBS: readonly string[] = [\n \".github/dependabot.{yml,yaml}\",\n];\n\n/** Dependency review workflow file globs. */\nexport const DEPENDENCY_REVIEW_WORKFLOW_FILE_GLOBS: readonly string[] = [\n \".github/workflows/dependency-review*.{yml,yaml}\",\n];\n\n/** Standard GitHub Actions workflow file globs. */\nexport const WORKFLOW_FILE_GLOBS: readonly string[] = [\n \".github/workflows/*.{yml,yaml}\",\n];\n\n/** Workflow template metadata (`.properties.json`) file globs. */\nexport const WORKFLOW_TEMPLATE_PROPERTIES_FILE_GLOBS: readonly string[] = [\n \"**/workflow-templates/*.properties.json\",\n];\n\n/** Workflow template YAML file globs. */\nexport const WORKFLOW_TEMPLATE_YAML_FILE_GLOBS: readonly string[] = [\n \"**/workflow-templates/*.{yml,yaml}\",\n];\n\n/** Combined workflow template globs used by dedicated template presets. */\nexport const WORKFLOW_TEMPLATE_FILE_GLOBS: readonly string[] = [\n ...WORKFLOW_TEMPLATE_YAML_FILE_GLOBS,\n ...WORKFLOW_TEMPLATE_PROPERTIES_FILE_GLOBS,\n];\n\n/** Normalize file paths for stable cross-platform path checks. */\nconst normalizePathForMatching = (filePath: string): string =>\n filePath.replaceAll(\"\\\\\", \"/\").toLowerCase();\n\n/** Determine whether a filename is an action metadata file. */\nexport const isActionMetadataFile = (filePath: string): boolean => {\n const normalizedFilePath = normalizePathForMatching(filePath);\n\n return (\n normalizedFilePath.endsWith(\"/action.yml\") ||\n normalizedFilePath.endsWith(\"/action.yaml\")\n );\n};\n\n/** Determine whether a filename is the repository Dependabot config file. */\nexport const isDependabotFile = (filePath: string): boolean => {\n const normalizedFilePath = normalizePathForMatching(filePath);\n\n return (\n normalizedFilePath.endsWith(\"/.github/dependabot.yml\") ||\n normalizedFilePath.endsWith(\"/.github/dependabot.yaml\") ||\n normalizedFilePath === \".github/dependabot.yml\" ||\n normalizedFilePath === \".github/dependabot.yaml\"\n );\n};\n\n/** Determine whether a filename is a dependency review workflow file. */\nexport const isDependencyReviewWorkflowFile = (filePath: string): boolean => {\n const normalizedFilePath = normalizePathForMatching(filePath);\n\n return (\n (normalizedFilePath.includes(\"/.github/workflows/\") ||\n normalizedFilePath.startsWith(\".github/workflows/\")) &&\n (normalizedFilePath.endsWith(\"dependency-review.yml\") ||\n normalizedFilePath.endsWith(\"dependency-review.yaml\") ||\n normalizedFilePath.includes(\"/dependency-review-\") ||\n normalizedFilePath.includes(\"/dependency-review.\"))\n );\n};\n\n/**\n * Determine whether a filename is a standard workflow file under\n * `.github/workflows/`.\n */\nexport const isWorkflowFile = (filePath: string): boolean => {\n const normalizedFilePath = normalizePathForMatching(filePath);\n\n return (\n (normalizedFilePath.includes(\"/.github/workflows/\") ||\n normalizedFilePath.startsWith(\".github/workflows/\")) &&\n (normalizedFilePath.endsWith(\".yml\") ||\n normalizedFilePath.endsWith(\".yaml\"))\n );\n};\n\n/** Determine whether a filename is a workflow template metadata file. */\nexport const isWorkflowTemplatePropertiesFile = (filePath: string): boolean =>\n normalizePathForMatching(filePath).includes(\"/workflow-templates/\") &&\n normalizePathForMatching(filePath).endsWith(\".properties.json\");\n\n/** Determine whether a filename is a workflow template YAML file. */\nexport const isWorkflowTemplateYamlFile = (filePath: string): boolean => {\n const normalizedFilePath = normalizePathForMatching(filePath);\n\n return (\n normalizedFilePath.includes(\"/workflow-templates/\") &&\n (normalizedFilePath.endsWith(\".yml\") ||\n normalizedFilePath.endsWith(\".yaml\"))\n );\n};\n\n/** Determine whether a filename belongs to any workflow template surface. */\nexport const isWorkflowTemplateFile = (filePath: string): boolean =>\n isWorkflowTemplatePropertiesFile(filePath) ||\n isWorkflowTemplateYamlFile(filePath);\n\n/** Determine whether the path uses `.yaml` (rather than `.yml`). */\nexport const usesYamlExtension = (filePath: string): boolean =>\n extname(filePath).toLowerCase() === \".yaml\";\n\n/** Return the template basename without extension suffixes. */\nexport const getTemplateStem = (filePath: string): string => {\n const fileName = basename(filePath);\n\n if (fileName.endsWith(\".properties.json\")) {\n return fileName.slice(0, -\".properties.json\".length);\n }\n\n if (fileName.endsWith(\".yaml\")) {\n return fileName.slice(0, -\".yaml\".length);\n }\n\n if (fileName.endsWith(\".yml\")) {\n return fileName.slice(0, -\".yml\".length);\n }\n\n return fileName;\n};\n", "/**\n * @packageDocumentation\n * Shared YAML AST helpers for GitHub Actions workflow rules.\n */\n/* eslint-disable @typescript-eslint/prefer-readonly-parameter-types -- YAML AST nodes come from parser-owned mutable types shared across helper boundaries. */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\n/** Default workflow globs used by the exported flat configs. */\nexport const WORKFLOW_FILE_GLOBS: readonly string[] = [\n \".github/workflows/*.{yml,yaml}\",\n];\n\n/** Workflow job mapping paired with its stable identifier key. */\nexport type WorkflowJobEntry = {\n readonly id: string;\n readonly idNode: WorkflowYamlValueNode;\n readonly mapping: AST.YAMLMapping;\n readonly pair: AST.YAMLPair;\n};\n\n/** YAML value node type used by workflow helper APIs. */\ntype WorkflowYamlValueNode = AST.YAMLContent | AST.YAMLWithMeta;\n\n/** Narrow a YAML node to `YAMLWithMeta`. */\nexport const isYamlWithMeta = (\n node: AST.YAMLContent | AST.YAMLNode | AST.YAMLWithMeta | null | undefined\n): node is AST.YAMLWithMeta => node?.type === \"YAMLWithMeta\";\n\n/** Unwrap `YAMLWithMeta` wrappers until the underlying YAML value is reached. */\nexport const unwrapYamlValue = (\n node: null | undefined | WorkflowYamlValueNode\n): AST.YAMLContent | null => {\n if (node === null || node === undefined) {\n return null;\n }\n\n if (isYamlWithMeta(node)) {\n return unwrapYamlValue(node.value);\n }\n\n return node;\n};\n\n/** Narrow a YAML node to a mapping. */\nexport const isYamlMapping = (\n node: null | undefined | WorkflowYamlValueNode\n): node is AST.YAMLMapping => unwrapYamlValue(node)?.type === \"YAMLMapping\";\n\n/** Narrow a YAML node to a sequence. */\nexport const isYamlSequence = (\n node: null | undefined | WorkflowYamlValueNode\n): node is AST.YAMLSequence => unwrapYamlValue(node)?.type === \"YAMLSequence\";\n\n/** Narrow a YAML node to a scalar. */\nexport const isYamlScalar = (\n node: null | undefined | WorkflowYamlValueNode\n): node is AST.YAMLScalar => unwrapYamlValue(node)?.type === \"YAMLScalar\";\n\n/** Resolve the first document's root mapping when linting a workflow file. */\nexport const getWorkflowRoot = (\n context: Rule.RuleContext\n): AST.YAMLMapping | null => {\n const program = context.sourceCode.ast as unknown as AST.YAMLProgram;\n const [document] = program.body;\n const rootNode = unwrapYamlValue(document?.content ?? null);\n\n return rootNode?.type === \"YAMLMapping\" ? rootNode : null;\n};\n\n/** Read a scalar node as a string when possible. */\nexport const getScalarStringValue = (\n node: null | undefined | WorkflowYamlValueNode\n): null | string => {\n const unwrappedNode = unwrapYamlValue(node);\n\n if (unwrappedNode?.type !== \"YAMLScalar\") {\n return null;\n }\n\n if (typeof unwrappedNode.value === \"string\") {\n return unwrappedNode.value;\n }\n\n return \"strValue\" in unwrappedNode &&\n typeof unwrappedNode.strValue === \"string\"\n ? unwrappedNode.strValue\n : null;\n};\n\n/** Read a scalar node as a number when possible. */\nexport const getScalarNumberValue = (\n node: null | undefined | WorkflowYamlValueNode\n): null | number => {\n const unwrappedNode = unwrapYamlValue(node);\n\n if (unwrappedNode?.type !== \"YAMLScalar\") {\n return null;\n }\n\n return typeof unwrappedNode.value === \"number\" ? unwrappedNode.value : null;\n};\n\n/** Determine whether a scalar is a GitHub expression string like `${{ ... }}`. */\nexport const isGithubExpressionScalar = (\n node: null | undefined | WorkflowYamlValueNode\n): boolean => {\n const scalarValue = getScalarStringValue(node);\n\n return (\n scalarValue !== null &&\n scalarValue.trimStart().startsWith(\"${{\") &&\n scalarValue.trimEnd().endsWith(\"}}\")\n );\n};\n\n/** Find a mapping pair by its exact scalar key. */\nexport const getMappingPair = (\n mapping: AST.YAMLMapping,\n key: string\n): AST.YAMLPair | null => {\n for (const pair of mapping.pairs) {\n if (getScalarStringValue(pair.key) === key) {\n return pair;\n }\n }\n\n return null;\n};\n\n/** Resolve a mapping child by key, ensuring the value is a mapping. */\nexport const getMappingValueAsMapping = (\n mapping: AST.YAMLMapping,\n key: string\n): AST.YAMLMapping | null => {\n const pair = getMappingPair(mapping, key);\n const valueNode = unwrapYamlValue(pair?.value ?? null);\n\n return valueNode?.type === \"YAMLMapping\" ? valueNode : null;\n};\n\n/** Resolve a mapping child by key, ensuring the value is a sequence. */\nexport const getMappingValueAsSequence = (\n mapping: AST.YAMLMapping,\n key: string\n): AST.YAMLSequence | null => {\n const pair = getMappingPair(mapping, key);\n const valueNode = unwrapYamlValue(pair?.value ?? null);\n\n return valueNode?.type === \"YAMLSequence\" ? valueNode : null;\n};\n\n/** Enumerate workflow jobs under `jobs`. */\nexport const getWorkflowJobs = (\n root: AST.YAMLMapping\n): readonly WorkflowJobEntry[] => {\n const jobsMapping = getMappingValueAsMapping(root, \"jobs\");\n\n if (jobsMapping === null) {\n return [];\n }\n\n const jobs: WorkflowJobEntry[] = [];\n\n for (const pair of jobsMapping.pairs) {\n const jobId = getScalarStringValue(pair.key);\n const jobMapping = unwrapYamlValue(pair.value);\n\n if (jobId === null || jobMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n if (pair.key === null || pair.key === undefined) {\n continue;\n }\n\n jobs.push({\n id: jobId,\n idNode: pair.key,\n mapping: jobMapping,\n pair,\n });\n }\n\n return jobs;\n};\n\n/** Collect the workflow event names declared under `on`. */\nexport const getWorkflowEventNames = (\n root: AST.YAMLMapping\n): ReadonlySet<string> => {\n const onPair = getMappingPair(root, \"on\");\n const onValue = unwrapYamlValue(onPair?.value ?? null);\n const eventNames = new Set<string>();\n\n if (onValue === null) {\n return eventNames;\n }\n\n if (onValue.type === \"YAMLScalar\") {\n const eventName = getScalarStringValue(onValue);\n\n if (eventName !== null) {\n eventNames.add(eventName);\n }\n\n return eventNames;\n }\n\n if (onValue.type === \"YAMLSequence\") {\n for (const entry of onValue.entries) {\n const eventName = getScalarStringValue(entry);\n\n if (eventName !== null) {\n eventNames.add(eventName);\n }\n }\n\n return eventNames;\n }\n\n if (onValue.type === \"YAMLMapping\") {\n for (const pair of onValue.pairs) {\n const eventName = getScalarStringValue(pair.key);\n\n if (eventName !== null) {\n eventNames.add(eventName);\n }\n }\n }\n\n return eventNames;\n};\n\n/* eslint-enable @typescript-eslint/prefer-readonly-parameter-types -- Re-enable readonly-parameter checks after YAML AST helper declarations. */\n", "/**\n * @packageDocumentation\n * Canonical preset names and docs references used by eslint-plugin-github-actions-2.\n */\nimport {\n ACTION_METADATA_FILE_GLOBS,\n DEPENDABOT_FILE_GLOBS,\n WORKFLOW_TEMPLATE_FILE_GLOBS,\n WORKFLOW_TEMPLATE_PROPERTIES_FILE_GLOBS,\n} from \"./lint-targets.js\";\nimport { WORKFLOW_FILE_GLOBS } from \"./workflow-yaml.js\";\n\n/** Ordered preset names exposed through `plugin.configs`. */\nexport const githubActionsConfigNames = [\n \"actionMetadata\",\n \"codeScanning\",\n \"dependabot\",\n \"workflowTemplateProperties\",\n \"workflowTemplates\",\n \"recommended\",\n \"security\",\n \"strict\",\n \"all\",\n] as const;\n\n/** Supported flat-config preset names exported by the plugin. */\nexport type GithubActionsConfigName = (typeof githubActionsConfigNames)[number];\n\n/** String references used in rule docs metadata and generated docs tables. */\nexport const githubActionsConfigReferenceToName: Readonly<\n Record<string, GithubActionsConfigName>\n> = {\n \"github-actions.configs.actionMetadata\": \"actionMetadata\",\n \"github-actions.configs.all\": \"all\",\n \"github-actions.configs.codeScanning\": \"codeScanning\",\n \"github-actions.configs.dependabot\": \"dependabot\",\n \"github-actions.configs.recommended\": \"recommended\",\n \"github-actions.configs.security\": \"security\",\n \"github-actions.configs.strict\": \"strict\",\n \"github-actions.configs.workflowTemplateProperties\":\n \"workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\": \"workflowTemplates\",\n} as const satisfies Record<string, GithubActionsConfigName>;\n\n/** Valid config reference strings accepted in rule metadata. */\nexport type GithubActionsConfigReference =\n keyof typeof githubActionsConfigReferenceToName;\n\n/** Display metadata for each preset used in README and docs surfaces. */\nexport const githubActionsConfigMetadataByName: Readonly<\n Record<\n GithubActionsConfigName,\n {\n description: string;\n files: readonly string[];\n icon: string;\n presetName: string;\n }\n >\n> = {\n actionMetadata: {\n description:\n \"Linting defaults for GitHub Action metadata files (`action.yml` / `action.yaml`).\",\n files: ACTION_METADATA_FILE_GLOBS,\n icon: \"\uD83E\uDDE9\",\n presetName: \"github-actions:action-metadata\",\n },\n all: {\n description:\n \"Enables every available rule published by this plugin across workflows, action metadata, workflow templates, and Dependabot configuration.\",\n files: [\n ...WORKFLOW_FILE_GLOBS,\n ...ACTION_METADATA_FILE_GLOBS,\n ...DEPENDABOT_FILE_GLOBS,\n ...WORKFLOW_TEMPLATE_FILE_GLOBS,\n ],\n icon: \"\uD83D\uDFE3\",\n presetName: \"github-actions:all\",\n },\n codeScanning: {\n description:\n \"Workflow security defaults for CodeQL, SARIF uploads, dependency review, and related code-scanning integrations.\",\n files: WORKFLOW_FILE_GLOBS,\n icon: \"\uD83D\uDD0E\",\n presetName: \"github-actions:code-scanning\",\n },\n dependabot: {\n description:\n \"Linting defaults for repository Dependabot configuration files (`.github/dependabot.yml`).\",\n files: DEPENDABOT_FILE_GLOBS,\n icon: \"\uD83E\uDD16\",\n presetName: \"github-actions:dependabot\",\n },\n recommended: {\n description:\n \"Balanced defaults for most repositories authoring GitHub Actions workflows.\",\n files: WORKFLOW_FILE_GLOBS,\n icon: \"\uD83D\uDFE1\",\n presetName: \"github-actions:recommended\",\n },\n security: {\n description:\n \"Security-focused workflow hardening checks for action usage and token scope.\",\n files: WORKFLOW_FILE_GLOBS,\n icon: \"\uD83D\uDEE1\uFE0F\",\n presetName: \"github-actions:security\",\n },\n strict: {\n description:\n \"Opinionated operational guardrails for mature workflow estates.\",\n files: WORKFLOW_FILE_GLOBS,\n icon: \"\uD83D\uDD34\",\n presetName: \"github-actions:strict\",\n },\n workflowTemplateProperties: {\n description:\n \"Linting defaults for workflow-template metadata files (`*.properties.json`).\",\n files: WORKFLOW_TEMPLATE_PROPERTIES_FILE_GLOBS,\n icon: \"\uD83D\uDDC2\uFE0F\",\n presetName: \"github-actions:workflow-template-properties\",\n },\n workflowTemplates: {\n description:\n \"Workflow template package linting for both template YAML and metadata files.\",\n files: WORKFLOW_TEMPLATE_FILE_GLOBS,\n icon: \"\uD83E\uDDF1\",\n presetName: \"github-actions:workflow-templates\",\n },\n} as const;\n", "/**\n * @packageDocumentation\n * Canonical brand/acronym dictionary synced from case-police.\n * Source: https://github.com/antfu/case-police\n */\n\n/**\n * Canonical casing entries merged from case-police dictionaries.\n */\nexport const casePoliceDictionary: Readonly<Record<string, string>> = {\n \"1password\": \"1Password\",\n \"3dtiles\": \"3DTiles\",\n abi: \"ABI\",\n actionscript: \"ActionScript\",\n adblock: \"AdBlock\",\n aiaas: \"AIaaS\",\n airbnb: \"Airbnb\",\n ajax: \"AJAX\",\n alipay: \"Alipay\",\n alphago: \"AlphaGo\",\n amap: \"AMap\",\n amd: \"AMD\",\n angularjs: \"AngularJS\",\n antd: \"AntD\",\n \"ant design\": \"Ant Design\",\n antdesign: \"AntDesign\",\n \"ant design vue\": \"Ant Design Vue\",\n antdesignvue: \"AntDesignVue\",\n antv: \"AntV\",\n api: \"API\",\n apifox: \"Apifox\",\n \"apple pay\": \"Apple Pay\",\n applescript: \"AppleScript\",\n appletalk: \"AppleTalk\",\n \"app store\": \"App Store\",\n arangodb: \"ArangoDB\",\n arcgis: \"ArcGIS\",\n arcmap: \"ArcMap\",\n arcobjects: \"ArcObjects\",\n ast: \"AST\",\n baas: \"BaaS\",\n beego: \"Beego\",\n bitbucket: \"Bitbucket\",\n bittorrent: \"BitTorrent\",\n bluesky: \"Bluesky\",\n bom: \"BOM\",\n bsd: \"BSD\",\n busybox: \"BusyBox\",\n bytedance: \"ByteDance\",\n caas: \"CaaS\",\n cdn: \"CDN\",\n centos: \"CentOS\",\n cesiumjs: \"CesiumJS\",\n chatgpt: \"ChatGPT\",\n circleci: \"CircleCI\",\n citygml: \"CityGML\",\n cityjson: \"CityJSON\",\n cjs: \"CJS\",\n ckeditor: \"CKEditor\",\n clashx: \"ClashX\",\n cli: \"CLI\",\n clickhouse: \"ClickHouse\",\n cloudflare: \"Cloudflare\",\n cloudfront: \"CloudFront\",\n cmake: \"CMake\",\n cncf: \"CNCF\",\n cockroachdb: \"CockroachDB\",\n cocoapods: \"CocoaPods\",\n codepen: \"CodePen\",\n codesandbox: \"CodeSandbox\",\n coffeescript: \"CoffeeScript\",\n commonjs: \"CommonJS\",\n \"composition api\": \"Composition API\",\n compositionapi: \"CompositionAPI\",\n coredns: \"CoreDNS\",\n cors: \"CORS\",\n cpu: \"CPU\",\n crud: \"CRUD\",\n csrf: \"CSRF\",\n css: \"CSS\",\n \"css modules\": \"CSS Modules\",\n csv: \"CSV\",\n daas: \"DaaS\",\n dapr: \"Dapr\",\n datadog: \"Datadog\",\n datagrip: \"DataGrip\",\n db2: \"DB2\",\n dbase: \"dBase\",\n ddos: \"DDoS\",\n definitelytyped: \"DefinitelyTyped\",\n denodeploy: \"DenoDeploy\",\n devops: \"DevOps\",\n devtools: \"DevTools\",\n \"digital ocean\": \"DigitalOcean\",\n digitalocean: \"DigitalOcean\",\n dingtalk: \"DingTalk\",\n directx: \"DirectX\",\n django: \"Django\",\n dns: \"DNS\",\n dom: \"DOM\",\n dos: \"DOS\",\n duckduckgo: \"DuckDuckGo\",\n dynamodb: \"DynamoDB\",\n echarts: \"ECharts\",\n ecmascript: \"ECMAScript\",\n edgedb: \"EdgeDB\",\n eggjs: \"Egg.js\",\n elasticsearch: \"Elasticsearch\",\n \"element plus\": \"Element Plus\",\n elementui: \"ElementUI\",\n es6: \"ES6\",\n esbuild: \"esbuild\",\n esim: \"eSIM\",\n eslint: \"ESLint\",\n esm: \"ESM\",\n esxi: \"ESXi\",\n etcd: \"etcd\",\n faas: \"FaaS\",\n facetime: \"FaceTime\",\n fastapi: \"FastAPI\",\n fbi: \"FBI\",\n ffmpeg: \"FFmpeg\",\n filezilla: \"FileZilla\",\n firefox: \"Firefox\",\n freecodecamp: \"freeCodeCamp\",\n freemarker: \"FreeMarker\",\n ftp: \"FTP\",\n ftps: \"FTPS\",\n gcc: \"GCC\",\n gcp: \"GCP\",\n gdnative: \"GDNative\",\n gdscript: \"GDScript\",\n geforce: \"GeForce\",\n geojson: \"GeoJSON\",\n geopackage: \"GeoPackage\",\n geopandas: \"GeoPandas\",\n geoserver: \"GeoServer\",\n gitbook: \"GitBook\",\n gitea: \"Gitea\",\n gitee: \"Gitee\",\n github: \"GitHub\",\n gitkraken: \"GitKraken\",\n gitlab: \"GitLab\",\n gitops: \"GitOps\",\n gitpod: \"Gitpod\",\n glsl: \"GLSL\",\n gltf: \"glTF\",\n gnome: \"GNOME\",\n gnu: \"GNU\",\n gnupg: \"GnuPG\",\n goland: \"GoLand\",\n \"google pay\": \"Google Pay\",\n gorm: \"GORM\",\n gpl: \"GPL\",\n gps: \"GPS\",\n gpu: \"GPU\",\n graphql: \"GraphQL\",\n \"graph rag\": \"Graph RAG\",\n graphrag: \"GraphRAG\",\n gre: \"GRE\",\n greensock: \"GreenSock\",\n grpc: \"gRPC\",\n gui: \"GUI\",\n hackernews: \"Hacker News\",\n hacpai: \"HacPai\",\n hbase: \"HBase\",\n hbuilderx: \"HBuilderX\",\n hdmi: \"HDMI\",\n hmr: \"HMR\",\n hp: \"HP\",\n html: \"HTML\",\n http: \"HTTP\",\n https: \"HTTPS\",\n iaas: \"IaaS\",\n iac: \"IaC\",\n ibm: \"IBM\",\n ibook: \"iBook\",\n icloud: \"iCloud\",\n idrac: \"iDRAC\",\n iife: \"IIFE\",\n ilo: \"iLO\",\n imessage: \"iMessage\",\n imovie: \"iMovie\",\n imtoken: \"imToken\",\n influxdb: \"InfluxDB\",\n intellij: \"IntelliJ\",\n \"intellij idea\": \"IntelliJ IDEA\",\n ioc: \"IoC\",\n ios: \"iOS\",\n iot: \"IoT\",\n ipados: \"iPadOS\",\n ipc: \"IPC\",\n ipfs: \"IPFS\",\n iphoto: \"iPhoto\",\n ipmi: \"IPMI\",\n ipsec: \"IPsec\",\n iscsi: \"iSCSI\",\n iterm: \"iTerm\",\n itunes: \"iTunes\",\n iwork: \"iWork\",\n javascript: \"JavaScript\",\n jdbc: \"JDBC\",\n jdk: \"JDK\",\n jetbrains: \"JetBrains\",\n jit: \"JIT\",\n jpeg: \"JPEG\",\n jpg: \"JPG\",\n jquery: \"jQuery\",\n jre: \"JRE\",\n jsdelivr: \"jsDelivr\",\n jsdoc: \"JSDoc\",\n jsf: \"JSF\",\n json: \"JSON\",\n jsonp: \"JSONP\",\n jsp: \"JSP\",\n jupyterlab: \"JupyterLab\",\n jwt: \"JWT\",\n katex: \"KaTeX\",\n kcp: \"KCP\",\n kde: \"KDE\",\n kfc: \"KFC\",\n kpi: \"KPI\",\n kubernetes: \"Kubernetes\",\n latex: \"LaTeX\",\n leetcode: \"LeetCode\",\n less: \"Less\",\n lfu: \"LFU\",\n libreoffice: \"LibreOffice\",\n lineageos: \"LineageOS\",\n \"line pay\": \"LINE Pay\",\n linkedin: \"LinkedIn\",\n llvm: \"LLVM\",\n lru: \"LRU\",\n lts: \"LTS\",\n macos: \"macOS\",\n mariadb: \"MariaDB\",\n markdown: \"Markdown\",\n markdownlint: \"MarkdownLint\",\n mathjax: \"MathJax\",\n mathml: \"MathML\",\n mathtype: \"MathType\",\n matlab: \"MATLAB\",\n mcdonald: \"McDonald\",\n mdn: \"MDN\",\n mdx: \"MDX\",\n mediawiki: \"MediaWiki\",\n memcached: \"Memcached\",\n messagepack: \"MessagePack\",\n metamask: \"MetaMask\",\n mkdocs: \"MkDocs\",\n mlaas: \"MLaaS\",\n mlops: \"MLOps\",\n mobx: \"MobX\",\n mongodb: \"MongoDB\",\n mongoose: \"Mongoose\",\n mpaas: \"mPaaS\",\n \"ms-dos\": \"MS-DOS\",\n mvc: \"MVC\",\n mvp: \"MVP\",\n mvvm: \"MVVM\",\n mybatis: \"MyBatis\",\n mysql: \"MySQL\",\n \"naive ui\": \"Naive UI\",\n naiveui: \"NaiveUI\",\n neo4j: \"Neo4j\",\n nestjs: \"NestJS\",\n netbeans: \"NetBeans\",\n netbios: \"NetBIOS\",\n nextjs: \"Next.js\",\n nft: \"NFT\",\n nixos: \"NixOS\",\n nocodb: \"NocoDB\",\n \"node.js\": \"Node.js\",\n nosql: \"NoSQL\",\n \"notepad ++\": \"Notepad++\",\n npm: \"npm\",\n numpy: \"NumPy\",\n nuxtjs: \"NuxtJS\",\n nvidia: \"NVIDIA\",\n oauth: \"OAuth\",\n obs: \"OBS\",\n ocaml: \"OCaml\",\n odbc: \"ODBC\",\n onedrive: \"OneDrive\",\n onenote: \"OneNote\",\n ont: \"ONT\",\n openai: \"OpenAI\",\n openapi: \"OpenAPI\",\n opencv: \"OpenCV\",\n openfaas: \"OpenFaaS\",\n openflow: \"OpenFlow\",\n opengauss: \"openGauss\",\n opengl: \"OpenGL\",\n \"opengl es\": \"OpenGL ES\",\n openjdk: \"OpenJDK\",\n openlayers: \"OpenLayers\",\n openpgp: \"OpenPGP\",\n opensea: \"OpenSea\",\n openssl: \"OpenSSL\",\n openstack: \"OpenStack\",\n openstreetmap: \"OpenStreetMap\",\n opensuse: \"openSUSE\",\n openvino: \"OpenVINO\",\n openwrt: \"OpenWrt\",\n opnsense: \"OPNsense\",\n orm: \"ORM\",\n oss: \"OSS\",\n paas: \"PaaS\",\n pagerduty: \"PagerDuty\",\n pagp: \"PAgP\",\n paypal: \"PayPal\",\n pdf: \"PDF\",\n pdo: \"PDO\",\n photoshop: \"Photoshop\",\n php: \"PHP\",\n phpstorm: \"PhpStorm\",\n pihole: \"Pi-hole\",\n planetscale: \"PlanetScale\",\n posix: \"POSIX\",\n postcss: \"PostCSS\",\n postgis: \"PostGIS\",\n postgresql: \"PostgreSQL\",\n potplayer: \"PotPlayer\",\n powerpoint: \"PowerPoint\",\n powershell: \"PowerShell\",\n premid: \"PreMiD\",\n primevue: \"PrimeVue\",\n producthunt: \"Product Hunt\",\n protobuf: \"Protobuf\",\n pwa: \"PWA\",\n pycharm: \"PyCharm\",\n pytorch: \"PyTorch\",\n qemu: \"QEMU\",\n qgis: \"QGIS\",\n qtscript: \"QtScript\",\n quic: \"QUIC\",\n raii: \"RAII\",\n \"react native\": \"React Native\",\n redhat: \"RedHat\",\n redisearch: \"RediSearch\",\n redisjson: \"RedisJSON\",\n rescript: \"ReScript\",\n restful: \"RESTful\",\n rethinkdb: \"RethinkDB\",\n rfc: \"RFC\",\n rom: \"ROM\",\n rpc: \"RPC\",\n rss: \"RSS\",\n rss3: \"RSS3\",\n rsshub: \"RSSHub\",\n rust: \"Rust\",\n rxdb: \"RxDB\",\n rxjs: \"RxJS\",\n saas: \"SaaS\",\n \"samsung pay\": \"Samsung Pay\",\n sass: \"Sass\",\n scss: \"SCSS\",\n sdk: \"SDK\",\n segmentfault: \"SegmentFault\",\n seo: \"SEO\",\n sip: \"SIP\",\n smtp: \"SMTP\",\n \"socket.io\": \"Socket.IO\",\n solarwinds: \"SolarWinds\",\n spatiallite: \"SpatialLite\",\n \"spir-v\": \"SPIR-V\",\n springboot: \"SpringBoot\",\n springcloud: \"SpringCloud\",\n springmvc: \"SpringMVC\",\n sql: \"SQL\",\n sqlite: \"SQLite\",\n sqlserver: \"SQLServer\",\n sre: \"SRE\",\n ssg: \"SSG\",\n ssh: \"SSH\",\n sso: \"SSO\",\n ssr: \"SSR\",\n stackblitz: \"StackBlitz\",\n stackit: \"STACKIT\",\n stackoverflow: \"Stack Overflow\",\n storybook: \"Storybook\",\n stp: \"STP\",\n stylus: \"Stylus\",\n \"sublime text\": \"Sublime Text\",\n surrealdb: \"SurrealDB\",\n sveltekit: \"SvelteKit\",\n svg: \"SVG\",\n svn: \"SVN\",\n \"tailwind css\": \"Tailwind CSS\",\n tailwindcss: \"TailwindCSS\",\n tcp: \"TCP\",\n teamviewer: \"TeamViewer\",\n tensorflow: \"TensorFlow\",\n testflight: \"TestFlight\",\n tex: \"TeX\",\n threejs: \"ThreeJS\",\n tianocore: \"TianoCore\",\n tidb: \"TiDB\",\n tiflash: \"TiFlash\",\n tiktok: \"TikTok\",\n tikv: \"TiKV\",\n tls: \"TLS\",\n toml: \"TOML\",\n \"travis ci\": \"Travis CI\",\n trpc: \"tRPC\",\n tsc: \"TSC\",\n tsconfig: \"TSConfig\",\n tsdoc: \"TSDoc\",\n tsdx: \"TSdx\",\n turbopack: \"Turbopack\",\n turborepo: \"Turborepo\",\n typeorm: \"TypeORM\",\n typescript: \"TypeScript\",\n udp: \"UDP\",\n umd: \"UMD\",\n uniapp: \"uniapp\",\n unifi: \"UniFi\",\n unix: \"UNIX\",\n unjs: \"UnJS\",\n unocss: \"UnoCSS\",\n upnp: \"UPnP\",\n uri: \"URI\",\n url: \"URL\",\n usb: \"USB\",\n v2ex: \"V2EX\",\n vercel: \"Vercel\",\n videolan: \"VideoLAN\",\n vim: \"Vim\",\n virtualbox: \"VirtualBox\",\n \"visual studio\": \"Visual Studio\",\n \"visual studio code\": \"Visual Studio Code\",\n vitepress: \"VitePress\",\n vividcortex: \"VividCortex\",\n vlan: \"VLAN\",\n vlc: \"VLC\",\n vmware: \"VMware\",\n vnc: \"VNC\",\n voip: \"VoIP\",\n vpn: \"VPN\",\n vps: \"VPS\",\n \"vs code\": \"VS Code\",\n vscode: \"VS Code\",\n \"vs codium\": \"VSCodium\",\n vscodium: \"VSCodium\",\n \"vue cli\": \"Vue CLI\",\n vuefes: \"Vue Fes\",\n vuepress: \"VuePress\",\n vueuse: \"VueUse\",\n vulkan: \"Vulkan\",\n w3c: \"W3C\",\n wasm: \"Wasm\",\n watchos: \"watchOS\",\n webar: \"WebAR\",\n \"web assembly\": \"WebAssembly\",\n webassembly: \"WebAssembly\",\n webgl: \"WebGL\",\n webgpu: \"WebGPU\",\n webkit: \"WebKit\",\n webpack: \"webpack\",\n webrtc: \"WebRTC\",\n websocket: \"WebSocket\",\n webstorm: \"WebStorm\",\n webvr: \"WebVR\",\n webxr: \"WebXR\",\n wechat: \"WeChat\",\n \"wechat pay\": \"WeChat Pay\",\n wgsl: \"WGSL\",\n whatsapp: \"WhatsApp\",\n wifi: \"Wi-Fi\",\n \"windi css\": \"Windi CSS\",\n windicss: \"WindiCSS\",\n wireguard: \"WireGuard\",\n wlan: \"WLAN\",\n wordpress: \"WordPress\",\n wsa: \"WSA\",\n wsl: \"WSL\",\n xaas: \"XaaS\",\n xhtml: \"XHTML\",\n xmind: \"XMind\",\n xml: \"XML\",\n xss: \"XSS\",\n xstate: \"XState\",\n yaml: \"YAML\",\n yapi: \"YApi\",\n youtube: \"YouTube\",\n};\n", "/**\n * @packageDocumentation\n * Shared casing helpers for naming-oriented GitHub Actions rules.\n */\n\nimport { casePoliceDictionary } from \"./case-police-dictionary.js\";\n\n/** Supported naming conventions used by workflow naming rules. */\nexport const githubActionsCasingKinds = [\n \"camelCase\",\n \"kebab-case\",\n \"PascalCase\",\n \"snake_case\",\n \"Title Case\",\n \"Train-Case\",\n \"SCREAMING_SNAKE_CASE\",\n] as const;\n\n/** String literal union of supported naming conventions. */\nexport type GithubActionsCasingKind = (typeof githubActionsCasingKinds)[number];\n\n/** Casing variants that exclude title-cased words with spaces. */\nexport const githubActionsNonTitleCasingKinds = [\n \"camelCase\",\n \"kebab-case\",\n \"PascalCase\",\n \"snake_case\",\n \"Train-Case\",\n \"SCREAMING_SNAKE_CASE\",\n] as const;\n\n/** String literal union of supported non-title casing conventions. */\nexport type GithubActionsNonTitleCasingKind =\n (typeof githubActionsNonTitleCasingKinds)[number];\n\n/** Determine whether a character is an ASCII letter or digit. */\nconst isAlphaNumericCharacter = (character: string): boolean => {\n const codePoint = character.codePointAt(0) ?? -1;\n\n return (\n (codePoint >= 48 && codePoint <= 57) ||\n (codePoint >= 65 && codePoint <= 90) ||\n (codePoint >= 97 && codePoint <= 122)\n );\n};\n\n/** Determine whether a character is an ASCII uppercase letter. */\nconst isUppercaseCharacter = (character: string): boolean => {\n const codePoint = character.codePointAt(0) ?? -1;\n\n return codePoint >= 65 && codePoint <= 90;\n};\n\n/** Determine whether a character is an ASCII lowercase letter. */\nconst isLowercaseCharacter = (character: string): boolean => {\n const codePoint = character.codePointAt(0) ?? -1;\n\n return codePoint >= 97 && codePoint <= 122;\n};\n\n/** Normalize a free-form identifier or label into lowercase word tokens. */\nconst splitIntoWords = (value: string): readonly string[] => {\n const words: string[] = [];\n let currentWord = \"\";\n\n for (let index = 0; index < value.length; index += 1) {\n const character = value[index];\n\n if (character === undefined) {\n continue;\n }\n\n if (!isAlphaNumericCharacter(character)) {\n if (currentWord.length > 0) {\n words.push(currentWord.toLowerCase());\n currentWord = \"\";\n }\n\n continue;\n }\n\n const previousCharacter = index > 0 ? value[index - 1] : undefined;\n const nextCharacter =\n index + 1 < value.length ? value[index + 1] : undefined;\n const startsNewWord =\n currentWord.length > 0 &&\n previousCharacter !== undefined &&\n ((isLowercaseCharacter(previousCharacter) &&\n isUppercaseCharacter(character)) ||\n (isUppercaseCharacter(previousCharacter) &&\n isUppercaseCharacter(character) &&\n nextCharacter !== undefined &&\n isLowercaseCharacter(nextCharacter)));\n\n if (startsNewWord) {\n words.push(currentWord.toLowerCase());\n currentWord = character;\n\n continue;\n }\n\n currentWord += character;\n }\n\n if (currentWord.length > 0) {\n words.push(currentWord.toLowerCase());\n }\n\n return words;\n};\n\n/** Uppercase the first character of a normalized word token. */\nconst capitalizeWord = (word: string): string =>\n word.length === 0\n ? word\n : `${word[0]?.toUpperCase() ?? \"\"}${word.slice(1)}`;\n\n/** Case-police dictionary match shape keyed by collapsed word tokens. */\ntype CasePoliceDictionaryMatch = {\n readonly canonical: string;\n readonly tokenCount: number;\n};\n\n/** Index case-police entries by collapsed key and track longest token span. */\nconst buildCasePoliceDictionaryIndex = (): {\n readonly matchesByCollapsedKey: ReadonlyMap<\n string,\n readonly CasePoliceDictionaryMatch[]\n >;\n readonly maxTokenSpan: number;\n} => {\n const matchesByCollapsedKey = new Map<\n string,\n CasePoliceDictionaryMatch[]\n >();\n let maxTokenSpan = 1;\n\n for (const [dictionaryKey, canonical] of Object.entries(\n casePoliceDictionary\n )) {\n const keyWords = splitIntoWords(dictionaryKey);\n\n if (keyWords.length === 0) {\n continue;\n }\n\n const tokenCount = keyWords.length;\n const collapsedKey = keyWords.join(\"\");\n const existingMatches = matchesByCollapsedKey.get(collapsedKey) ?? [];\n const isDuplicateMatch = existingMatches.some(\n (existingMatch) =>\n existingMatch.canonical === canonical &&\n existingMatch.tokenCount === tokenCount\n );\n\n if (!isDuplicateMatch) {\n existingMatches.push({\n canonical,\n tokenCount,\n });\n matchesByCollapsedKey.set(collapsedKey, existingMatches);\n }\n\n if (tokenCount > maxTokenSpan) {\n maxTokenSpan = tokenCount;\n }\n }\n\n return {\n matchesByCollapsedKey,\n maxTokenSpan,\n };\n};\n\n/** Precomputed case-police dictionary index used by Title/Train conversions. */\nconst casePoliceDictionaryIndex = buildCasePoliceDictionaryIndex();\n\n/**\n * Resolve normalized words into title-style segments using the case-police\n * dictionary. Falls back to naive capitalization for unknown tokens.\n */\nconst resolveCasePoliceTitleSegments = (\n words: readonly string[]\n): readonly string[] => {\n const segments: string[] = [];\n\n for (let index = 0; index < words.length; ) {\n const remainingWordCount = words.length - index;\n const maxSpan = Math.min(\n casePoliceDictionaryIndex.maxTokenSpan,\n remainingWordCount\n );\n\n let matched = false;\n\n for (let span = maxSpan; span >= 1; span -= 1) {\n const collapsedCandidate = words\n .slice(index, index + span)\n .join(\"\");\n const candidateMatches =\n casePoliceDictionaryIndex.matchesByCollapsedKey.get(\n collapsedCandidate\n );\n\n if (candidateMatches === undefined) {\n continue;\n }\n\n const exactTokenCountMatch = candidateMatches.find(\n (candidateMatch) => candidateMatch.tokenCount === span\n );\n const selectedMatch = exactTokenCountMatch ?? candidateMatches[0];\n\n if (selectedMatch === undefined) {\n continue;\n }\n\n segments.push(selectedMatch.canonical);\n index += span;\n matched = true;\n\n break;\n }\n\n if (matched) {\n continue;\n }\n\n const currentWord = words[index];\n\n if (currentWord === undefined) {\n index += 1;\n\n continue;\n }\n\n segments.push(capitalizeWord(currentWord));\n index += 1;\n }\n\n return segments;\n};\n\n/** Convert a value into the exact requested casing convention. */\nexport const convertToGithubActionsCasing = (\n value: string,\n casingKind: GithubActionsCasingKind\n): string => {\n const words = splitIntoWords(value);\n const titleSegments = resolveCasePoliceTitleSegments(words);\n\n if (words.length === 0) {\n return value;\n }\n\n switch (casingKind) {\n case \"camelCase\": {\n const [firstWord = \"\", ...remainingWords] = words;\n\n return `${firstWord}${remainingWords.map((word) => capitalizeWord(word)).join(\"\")}`;\n }\n\n case \"kebab-case\": {\n return words.join(\"-\");\n }\n\n case \"PascalCase\": {\n return words.map((word) => capitalizeWord(word)).join(\"\");\n }\n\n case \"SCREAMING_SNAKE_CASE\": {\n return words.map((word) => word.toUpperCase()).join(\"_\");\n }\n\n case \"snake_case\": {\n return words.join(\"_\");\n }\n\n case \"Title Case\": {\n return titleSegments.join(\" \");\n }\n\n case \"Train-Case\": {\n return titleSegments\n .flatMap((segment) => segment.split(/\\s+/u))\n .filter((segment) => segment.length > 0)\n .join(\"-\");\n }\n\n default: {\n return value;\n }\n }\n};\n\n/** Determine whether a value already satisfies a requested casing convention. */\nexport const matchesGithubActionsCasing = (\n value: string,\n casingKind: GithubActionsCasingKind\n): boolean => convertToGithubActionsCasing(value, casingKind) === value;\n", "/**\n * @packageDocumentation\n * Enforce a consistent naming convention for workflow names.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n convertToGithubActionsCasing,\n type GithubActionsCasingKind,\n githubActionsCasingKinds,\n matchesGithubActionsCasing,\n} from \"../_internal/casing.js\";\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Object-style configuration for `action-name-casing`. */\ntype ActionNameCasingObjectOption = Partial<\n Record<GithubActionsCasingKind, boolean>\n> & {\n readonly ignores?: readonly string[];\n};\n\n/** Rule options for `action-name-casing`. */\ntype ActionNameCasingOptions = [\n (ActionNameCasingObjectOption | GithubActionsCasingKind)?,\n];\n\n/** Default casing enforced for workflow names. */\nconst DEFAULT_ACTION_NAME_CASING: GithubActionsCasingKind = \"Title Case\";\n\n/**\n * Normalize action-name-casing options into allowed casings and ignore\n * patterns.\n */\nconst normalizeActionNameCasingOptions = (\n option: Readonly<\n ActionNameCasingObjectOption | GithubActionsCasingKind | undefined\n >\n): {\n allowedCasings: readonly GithubActionsCasingKind[];\n ignoredNames: readonly string[];\n} => {\n if (option === undefined || typeof option === \"string\") {\n return {\n allowedCasings: [option ?? DEFAULT_ACTION_NAME_CASING],\n ignoredNames: [],\n };\n }\n\n const allowedCasings = githubActionsCasingKinds.filter(\n (casingKind) => option[casingKind] === true\n );\n\n return {\n allowedCasings:\n allowedCasings.length > 0\n ? allowedCasings\n : [DEFAULT_ACTION_NAME_CASING],\n ignoredNames: [...(option.ignores ?? [])],\n };\n};\n\n/** Rule implementation for enforcing workflow-name casing. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const [option] = context.options as ActionNameCasingOptions;\n const { allowedCasings, ignoredNames } =\n normalizeActionNameCasingOptions(option ?? undefined);\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const namePair = getMappingPair(root, \"name\");\n const nameNode = unwrapYamlValue(namePair?.value ?? null);\n const nameValue = getScalarStringValue(nameNode);\n\n if (\n namePair === null ||\n nameNode?.type !== \"YAMLScalar\" ||\n nameValue === null ||\n nameValue.trim().length === 0 ||\n ignoredNames.includes(nameValue)\n ) {\n return;\n }\n\n const matchesAllowedCasing = allowedCasings.some((casingKind) =>\n matchesGithubActionsCasing(nameValue, casingKind)\n );\n\n if (!matchesAllowedCasing) {\n const [firstAllowedCasing] = allowedCasings;\n\n context.report({\n data: {\n caseTypes: allowedCasings.join(\", \"),\n name: nameValue,\n },\n fix:\n firstAllowedCasing !== undefined &&\n allowedCasings.length === 1\n ? (fixer) =>\n fixer.replaceTextRange(\n nameNode.range,\n convertToGithubActionsCasing(\n nameValue,\n firstAllowedCasing\n )\n )\n : undefined,\n messageId: \"nameDoesNotMatchCasing\",\n node: nameNode as AST.YAMLNode as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n defaultOptions: [DEFAULT_ACTION_NAME_CASING],\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"enforce a consistent casing convention for workflow `name` values.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R009\",\n ruleNumber: 9,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/action-name-casing\",\n },\n fixable: \"code\",\n messages: {\n nameDoesNotMatchCasing:\n \"Workflow name '{{name}}' is not in the configured casing: {{caseTypes}}.\",\n },\n schema: [\n {\n anyOf: [\n {\n description:\n \"Single allowed casing convention for the workflow `name` value.\",\n enum: githubActionsCasingKinds,\n type: \"string\",\n },\n {\n additionalProperties: false,\n description:\n \"Allowed casing conventions and ignore patterns for the workflow `name` value.\",\n properties: {\n camelCase: {\n description: \"Allow camelCase workflow names.\",\n type: \"boolean\",\n },\n ignores: {\n description:\n \"Literal workflow names that should be ignored by this rule.\",\n items: {\n type: \"string\",\n },\n type: \"array\",\n uniqueItems: true,\n },\n \"kebab-case\": {\n description: \"Allow kebab-case workflow names.\",\n type: \"boolean\",\n },\n PascalCase: {\n description: \"Allow PascalCase workflow names.\",\n type: \"boolean\",\n },\n SCREAMING_SNAKE_CASE: {\n description:\n \"Allow SCREAMING_SNAKE_CASE workflow names.\",\n type: \"boolean\",\n },\n snake_case: {\n description: \"Allow snake_case workflow names.\",\n type: \"boolean\",\n },\n \"Title Case\": {\n description: \"Allow Title Case workflow names.\",\n type: \"boolean\",\n },\n \"Train-Case\": {\n description: \"Allow Train-Case workflow names.\",\n type: \"boolean\",\n },\n },\n type: \"object\",\n },\n ],\n description:\n \"Configure one or more allowed casing conventions for workflow `name` values.\",\n },\n ],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Enforce a consistent naming convention for workflow job identifiers.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n type GithubActionsNonTitleCasingKind,\n githubActionsNonTitleCasingKinds,\n matchesGithubActionsCasing,\n} from \"../_internal/casing.js\";\nimport {\n getWorkflowJobs,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Object-style configuration for `job-id-casing`. */\ntype JobIdCasingObjectOption = Partial<\n Record<GithubActionsNonTitleCasingKind, boolean>\n> & {\n readonly ignores?: readonly string[];\n};\n\n/** Rule options for `job-id-casing`. */\ntype JobIdCasingOptions = [\n (GithubActionsNonTitleCasingKind | JobIdCasingObjectOption)?,\n];\n\n/** Default casing enforced for workflow job ids. */\nconst DEFAULT_JOB_ID_CASING: GithubActionsNonTitleCasingKind = \"kebab-case\";\n\n/** Normalize job-id-casing options into allowed casings and ignore patterns. */\nconst normalizeJobIdCasingOptions = (\n option: Readonly<\n GithubActionsNonTitleCasingKind | JobIdCasingObjectOption | undefined\n >\n): {\n allowedCasings: readonly GithubActionsNonTitleCasingKind[];\n ignoredJobIds: readonly string[];\n} => {\n if (option === undefined || typeof option === \"string\") {\n return {\n allowedCasings: [option ?? DEFAULT_JOB_ID_CASING],\n ignoredJobIds: [],\n };\n }\n\n const allowedCasings = githubActionsNonTitleCasingKinds.filter(\n (casingKind) => option[casingKind] === true\n );\n\n return {\n allowedCasings:\n allowedCasings.length > 0\n ? allowedCasings\n : [DEFAULT_JOB_ID_CASING],\n ignoredJobIds: [...(option.ignores ?? [])],\n };\n};\n\n/** Rule implementation for enforcing job-id casing. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const [option] = context.options as JobIdCasingOptions;\n const { allowedCasings, ignoredJobIds } = normalizeJobIdCasingOptions(\n option ?? undefined\n );\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n if (ignoredJobIds.includes(job.id)) {\n continue;\n }\n\n const matchesAllowedCasing = allowedCasings.some(\n (casingKind) =>\n matchesGithubActionsCasing(job.id, casingKind)\n );\n\n if (!matchesAllowedCasing) {\n context.report({\n data: {\n caseTypes: allowedCasings.join(\", \"),\n jobId: job.id,\n },\n messageId: \"jobIdDoesNotMatchCasing\",\n node: job.idNode as unknown as Rule.Node,\n });\n }\n }\n },\n };\n },\n meta: {\n defaultOptions: [DEFAULT_JOB_ID_CASING],\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"enforce a consistent casing convention for workflow job identifiers.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R010\",\n ruleNumber: 10,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/job-id-casing\",\n },\n messages: {\n jobIdDoesNotMatchCasing:\n \"Job id '{{jobId}}' is not in the configured casing: {{caseTypes}}.\",\n },\n schema: [\n {\n anyOf: [\n {\n description:\n \"Single allowed casing convention for workflow job ids.\",\n enum: githubActionsNonTitleCasingKinds,\n type: \"string\",\n },\n {\n additionalProperties: false,\n description:\n \"Allowed casing conventions and ignore patterns for workflow job ids.\",\n properties: {\n camelCase: {\n description: \"Allow camelCase job ids.\",\n type: \"boolean\",\n },\n ignores: {\n description:\n \"Literal job ids that should be ignored by this rule.\",\n items: {\n type: \"string\",\n },\n type: \"array\",\n uniqueItems: true,\n },\n \"kebab-case\": {\n description: \"Allow kebab-case job ids.\",\n type: \"boolean\",\n },\n PascalCase: {\n description: \"Allow PascalCase job ids.\",\n type: \"boolean\",\n },\n SCREAMING_SNAKE_CASE: {\n description:\n \"Allow SCREAMING_SNAKE_CASE job ids.\",\n type: \"boolean\",\n },\n snake_case: {\n description: \"Allow snake_case job ids.\",\n type: \"boolean\",\n },\n \"Train-Case\": {\n description: \"Allow Train-Case job ids.\",\n type: \"boolean\",\n },\n },\n type: \"object\",\n },\n ],\n description:\n \"Configure one or more allowed casing conventions for workflow job ids.\",\n },\n ],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Enforce an upper bound on the number of jobs declared in one workflow file.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingValueAsMapping,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule options for `max-jobs-per-action`. */\ntype MaxJobsPerActionOptions = [number?];\n\n/** Default maximum number of jobs allowed in a single workflow file. */\nconst DEFAULT_MAX_JOBS = 3;\n\n/** Rule implementation for limiting workflow job counts. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const [configuredMaxJobs = DEFAULT_MAX_JOBS] =\n context.options as MaxJobsPerActionOptions;\n const maxJobs =\n configuredMaxJobs >= 1 ? configuredMaxJobs : DEFAULT_MAX_JOBS;\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const jobsMapping = getMappingValueAsMapping(root, \"jobs\");\n\n if (jobsMapping === null) {\n return;\n }\n\n const jobCount = jobsMapping.pairs.length;\n\n if (jobCount > maxJobs) {\n context.report({\n data: {\n count: String(jobCount),\n limit: String(maxJobs),\n },\n messageId: \"tooManyJobs\",\n node: jobsMapping as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n defaultOptions: [DEFAULT_MAX_JOBS],\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"enforce a maximum number of jobs per workflow file so large pipelines stay modular and reviewable.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R011\",\n ruleNumber: 11,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/max-jobs-per-action\",\n },\n messages: {\n tooManyJobs:\n \"This workflow defines {{count}} jobs, which exceeds the configured maximum of {{limit}}.\",\n },\n schema: [\n {\n description:\n \"Maximum number of jobs allowed in a single GitHub Actions workflow file.\",\n minimum: 1,\n type: \"integer\",\n },\n ],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow case-insensitive collisions between action input ids.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isActionMetadataFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for case-insensitive input id collision detection. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isActionMetadataFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n const inputsMapping =\n root === null\n ? null\n : getMappingValueAsMapping(root, \"inputs\");\n\n if (inputsMapping === null) {\n return;\n }\n\n const inputByCanonicalId = new Map<string, string>();\n\n for (const pair of inputsMapping.pairs) {\n const inputId = getScalarStringValue(pair.key);\n\n if (inputId === null) {\n continue;\n }\n\n const canonicalId = inputId.toLowerCase();\n const firstSeenInputId =\n inputByCanonicalId.get(canonicalId);\n\n if (firstSeenInputId === undefined) {\n inputByCanonicalId.set(canonicalId, inputId);\n\n continue;\n }\n\n if (firstSeenInputId === inputId) {\n continue;\n }\n\n context.report({\n data: {\n firstInputId: firstSeenInputId,\n inputId,\n },\n messageId: \"collidingInputId\",\n node: pair.key as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.actionMetadata\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow case-insensitive collisions between action input ids.\",\n dialects: [\"GitHub Action metadata\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R048\",\n ruleNumber: 48,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-case-insensitive-input-id-collision\",\n },\n messages: {\n collidingInputId:\n \"Input '{{inputId}}' collides with '{{firstInputId}}' when normalized case-insensitively.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Shared helpers for workflow steps that use actions or run shell scripts.\n */\n/* eslint-disable @typescript-eslint/prefer-readonly-parameter-types -- YAML AST nodes come from parser-owned mutable types shared across helper boundaries. */\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowJobs,\n unwrapYamlValue,\n type WorkflowJobEntry,\n} from \"./workflow-yaml.js\";\n\n/** Workflow step using an external action via `uses`. */\nexport type WorkflowActionStep = {\n readonly job: WorkflowJobEntry;\n readonly stepMapping: AST.YAMLMapping;\n readonly usesPair: AST.YAMLPair;\n readonly usesReference: string;\n};\n\n/** Workflow step running a shell script via `run`. */\nexport type WorkflowRunStep = {\n readonly job: WorkflowJobEntry;\n readonly runPair: AST.YAMLPair;\n readonly runScript: string;\n readonly stepMapping: AST.YAMLMapping;\n};\n\n/**\n * Collect workflow steps using actions whose `uses` reference matches a\n * predicate.\n */\nexport const getWorkflowActionSteps = (\n root: AST.YAMLMapping,\n matchesReference: (usesReference: string) => boolean\n): readonly WorkflowActionStep[] => {\n const steps: WorkflowActionStep[] = [];\n\n for (const job of getWorkflowJobs(root)) {\n const stepsSequence = getMappingValueAsSequence(job.mapping, \"steps\");\n\n if (stepsSequence === null) {\n continue;\n }\n\n for (const entry of stepsSequence.entries) {\n const stepMapping = unwrapYamlValue(entry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const usesPair = getMappingPair(stepMapping, \"uses\");\n const usesReference = getScalarStringValue(usesPair?.value ?? null);\n\n if (usesPair === null || usesReference === null) {\n continue;\n }\n\n if (!matchesReference(usesReference)) {\n continue;\n }\n\n steps.push({\n job,\n stepMapping,\n usesPair,\n usesReference,\n });\n }\n }\n\n return steps;\n};\n\n/**\n * Determine whether any workflow step uses an action whose reference matches a\n * predicate.\n */\nexport const hasWorkflowActionStep = (\n root: AST.YAMLMapping,\n matchesReference: (usesReference: string) => boolean\n): boolean => getWorkflowActionSteps(root, matchesReference).length > 0;\n\n/** Collect workflow run steps whose run script matches a predicate. */\nexport const getWorkflowRunSteps = (\n root: AST.YAMLMapping,\n matchesRunScript: (runScript: string) => boolean\n): readonly WorkflowRunStep[] => {\n const steps: WorkflowRunStep[] = [];\n\n for (const job of getWorkflowJobs(root)) {\n const stepsSequence = getMappingValueAsSequence(job.mapping, \"steps\");\n\n if (stepsSequence === null) {\n continue;\n }\n\n for (const entry of stepsSequence.entries) {\n const stepMapping = unwrapYamlValue(entry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const runPair = getMappingPair(stepMapping, \"run\");\n const runScript = getScalarStringValue(runPair?.value ?? null);\n\n if (runPair === null || runScript === null) {\n continue;\n }\n\n if (!matchesRunScript(runScript)) {\n continue;\n }\n\n steps.push({\n job,\n runPair,\n runScript,\n stepMapping,\n });\n }\n }\n\n return steps;\n};\n\n/** Determine whether any workflow run step matches a script predicate. */\nexport const hasWorkflowRunStep = (\n root: AST.YAMLMapping,\n matchesRunScript: (runScript: string) => boolean\n): boolean => getWorkflowRunSteps(root, matchesRunScript).length > 0;\n\n/* eslint-enable @typescript-eslint/prefer-readonly-parameter-types -- Re-enable readonly-parameter checks outside parser AST helper signatures. */\n", "/**\n * @packageDocumentation\n * Helpers for CodeQL, SARIF, and code-scanning related workflows.\n */\n/* eslint-disable @typescript-eslint/prefer-readonly-parameter-types -- YAML AST nodes come from parser-owned mutable types shared across helper boundaries. */\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport type { WorkflowActionStep } from \"./workflow-action-steps.js\";\n\nimport { getWorkflowActionSteps } from \"./workflow-action-steps.js\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getMappingValueAsSequence,\n getScalarStringValue,\n} from \"./workflow-yaml.js\";\n\nconst codeqlLanguageAliases = new Set([\n \"javascript\",\n \"javascript-typescript\",\n \"typescript\",\n]);\n\nconst matrixLanguageExpression = `\\${{ matrix.language }}`;\n\n/** Determine whether a `uses` reference points to a specific CodeQL action step. */\nconst isCodeqlActionReference = (\n usesReference: string,\n actionName: string\n): boolean =>\n usesReference.trim().startsWith(`github/codeql-action/${actionName}@`);\n\n/** Determine whether a `uses` reference points to the CodeQL init action. */\nexport const isCodeqlInitReference = (usesReference: string): boolean =>\n isCodeqlActionReference(usesReference, \"init\");\n\n/** Determine whether a `uses` reference points to the CodeQL analyze action. */\nexport const isCodeqlAnalyzeReference = (usesReference: string): boolean =>\n isCodeqlActionReference(usesReference, \"analyze\");\n\n/** Determine whether a `uses` reference points to the CodeQL autobuild action. */\nexport const isCodeqlAutobuildReference = (usesReference: string): boolean =>\n isCodeqlActionReference(usesReference, \"autobuild\");\n\n/**\n * Determine whether a `uses` reference points to the CodeQL SARIF upload\n * action.\n */\nexport const isSarifUploadReference = (usesReference: string): boolean =>\n isCodeqlActionReference(usesReference, \"upload-sarif\");\n\n/** Determine whether a `uses` reference points to the Scorecard action. */\nexport const isScorecardActionReference = (usesReference: string): boolean =>\n usesReference.trim().startsWith(\"ossf/scorecard-action@\");\n\n/** Collect all CodeQL init steps in a workflow. */\nexport const getCodeqlInitSteps = (\n root: AST.YAMLMapping\n): readonly WorkflowActionStep[] =>\n getWorkflowActionSteps(root, isCodeqlInitReference);\n\n/** Collect all CodeQL analyze steps in a workflow. */\nexport const getCodeqlAnalyzeSteps = (\n root: AST.YAMLMapping\n): readonly WorkflowActionStep[] =>\n getWorkflowActionSteps(root, isCodeqlAnalyzeReference);\n\n/** Collect all CodeQL autobuild steps in a workflow. */\nexport const getCodeqlAutobuildSteps = (\n root: AST.YAMLMapping\n): readonly WorkflowActionStep[] =>\n getWorkflowActionSteps(root, isCodeqlAutobuildReference);\n\n/** Collect all CodeQL SARIF upload steps in a workflow. */\nexport const getSarifUploadSteps = (\n root: AST.YAMLMapping\n): readonly WorkflowActionStep[] =>\n getWorkflowActionSteps(root, isSarifUploadReference);\n\n/** Collect all Scorecard action steps in a workflow. */\nexport const getScorecardSteps = (\n root: AST.YAMLMapping\n): readonly WorkflowActionStep[] =>\n getWorkflowActionSteps(root, isScorecardActionReference);\n\n/**\n * Resolve literal language values used by a CodeQL init step when statically\n * knowable.\n */\nexport const getCodeqlLanguageValues = (\n step: WorkflowActionStep\n): readonly string[] => {\n const languagesMappingValue = getScalarStringValue(\n getMappingPair(\n getMappingValueAsMapping(step.stepMapping, \"with\") ??\n step.stepMapping,\n \"languages\"\n )?.value ?? null\n )?.trim();\n\n if (\n languagesMappingValue === undefined ||\n languagesMappingValue.length === 0\n ) {\n return [];\n }\n\n if (languagesMappingValue === matrixLanguageExpression) {\n const strategyMapping = getMappingValueAsMapping(\n step.job.mapping,\n \"strategy\"\n );\n const matrixMapping =\n strategyMapping === null\n ? null\n : getMappingValueAsMapping(strategyMapping, \"matrix\");\n\n if (matrixMapping === null) {\n return [];\n }\n\n const languageSequence = getMappingValueAsSequence(\n matrixMapping,\n \"language\"\n );\n\n if (languageSequence !== null) {\n return languageSequence.entries\n .map((entry) => getScalarStringValue(entry)?.trim() ?? null)\n .filter(\n (value): value is string =>\n value !== null && value.length > 0\n );\n }\n\n const singleLanguage = getScalarStringValue(\n getMappingPair(matrixMapping, \"language\")?.value ?? null\n )?.trim();\n\n return singleLanguage === undefined || singleLanguage.length === 0\n ? []\n : [singleLanguage];\n }\n\n return languagesMappingValue\n .split(\",\")\n .map((value) => value.trim())\n .filter((value) => value.length > 0);\n};\n\n/** Determine whether all statically resolved CodeQL languages are JS/TS aliases. */\nexport const codeqlLanguagesAreOnlyJavaScriptTypeScript = (\n languages: readonly string[]\n): boolean =>\n languages.length > 0 &&\n languages.every((language) => codeqlLanguageAliases.has(language));\n\n/* eslint-enable @typescript-eslint/prefer-readonly-parameter-types -- Re-enable readonly-parameter checks outside parser AST helper signatures. */\n", "/**\n * @packageDocumentation\n * Disallow CodeQL autobuild when a workflow only scans JavaScript/TypeScript.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n codeqlLanguagesAreOnlyJavaScriptTypeScript,\n getCodeqlAutobuildSteps,\n getCodeqlInitSteps,\n getCodeqlLanguageValues,\n} from \"../_internal/code-scanning-workflow.ts\";\nimport { getWorkflowRoot } from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for disallowing CodeQL autobuild on JS/TS-only workflows. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const autobuildStep of getCodeqlAutobuildSteps(root)) {\n const initSteps = getCodeqlInitSteps(root).filter(\n (step) => step.job.id === autobuildStep.job.id\n );\n\n if (initSteps.length === 0) {\n continue;\n }\n\n const languageValues = initSteps.flatMap((step) =>\n getCodeqlLanguageValues(step)\n );\n\n if (\n !codeqlLanguagesAreOnlyJavaScriptTypeScript(\n languageValues\n )\n ) {\n continue;\n }\n\n context.report({\n messageId: \"unnecessaryCodeqlAutobuild\",\n node: (autobuildStep.usesPair.value ??\n autobuildStep.usesPair) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.codeScanning\",\n ],\n description:\n \"disallow `github/codeql-action/autobuild` when CodeQL is only scanning JavaScript/TypeScript.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R097\",\n ruleNumber: 97,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-codeql-autobuild-for-javascript-typescript\",\n },\n messages: {\n unnecessaryCodeqlAutobuild:\n \"CodeQL autobuild is unnecessary for JavaScript/TypeScript-only analysis and should be removed.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow splitting JavaScript and TypeScript into separate CodeQL matrix entries.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getCodeqlInitSteps,\n getCodeqlLanguageValues,\n} from \"../_internal/code-scanning-workflow.ts\";\nimport { getWorkflowRoot } from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for disallowing split JS/TS CodeQL language matrices. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const step of getCodeqlInitSteps(root)) {\n const languageValues = new Set(\n getCodeqlLanguageValues(step)\n );\n\n if (\n languageValues.has(\"javascript\") &&\n languageValues.has(\"typescript\")\n ) {\n context.report({\n messageId: \"splitJavaScriptTypeScriptMatrix\",\n node: (step.usesPair.value ??\n step.usesPair) as unknown as Rule.Node,\n });\n }\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.codeScanning\",\n ],\n description:\n \"disallow CodeQL language matrices that split JavaScript and TypeScript instead of using `javascript-typescript`.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R096\",\n ruleNumber: 96,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-codeql-javascript-typescript-split-language-matrix\",\n },\n messages: {\n splitJavaScriptTypeScriptMatrix:\n \"CodeQL should use a single `javascript-typescript` language entry instead of splitting `javascript` and `typescript` into separate matrix values.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Generic YAML AST traversal utilities shared by lint rules.\n */\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport { getScalarStringValue, unwrapYamlValue } from \"./workflow-yaml.js\";\n/* eslint-disable @typescript-eslint/prefer-readonly-parameter-types -- Traversal operates on parser-provided mutable AST node types. */\n\n/** Visit every string scalar contained in a YAML subtree. */\nexport const visitYamlStringScalars = (\n node: AST.YAMLContent | AST.YAMLWithMeta | null | undefined,\n visitor: (node: Readonly<AST.YAMLScalar>, value: string) => void\n): void => {\n const unwrappedNode = unwrapYamlValue(node ?? null);\n\n if (unwrappedNode === null) {\n return;\n }\n\n if (unwrappedNode.type === \"YAMLScalar\") {\n const scalarValue = getScalarStringValue(unwrappedNode);\n\n if (scalarValue !== null) {\n visitor(unwrappedNode, scalarValue);\n }\n\n return;\n }\n\n if (unwrappedNode.type === \"YAMLSequence\") {\n for (const entry of unwrappedNode.entries) {\n visitYamlStringScalars(entry, visitor);\n }\n\n return;\n }\n\n if (unwrappedNode.type !== \"YAMLMapping\") {\n return;\n }\n\n for (const pair of unwrappedNode.pairs) {\n visitYamlStringScalars(pair.value ?? null, visitor);\n }\n};\n\n/** Collect every string scalar value from a YAML subtree. */\nexport const collectYamlStringScalars = (\n node: AST.YAMLContent | AST.YAMLWithMeta | null | undefined\n): readonly string[] => {\n const values: string[] = [];\n\n visitYamlStringScalars(node, (_node, value) => {\n values.push(value);\n });\n\n return values;\n};\n\n/* eslint-enable @typescript-eslint/prefer-readonly-parameter-types -- Re-enable readonly-parameter checks outside YAML traversal internals. */\n", "/**\n * @packageDocumentation\n * Disallow INPUT_* environment variable access inside composite action runs.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isActionMetadataFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\nimport { visitYamlStringScalars } from \"../_internal/yaml-traversal.js\";\n\n/** Composite-action INPUT_* environment variable reference detector. */\nconst inputEnvironmentPattern = /\\bINPUT_[\\dA-Z_]+\\b/g;\n\n/** Rule implementation for composite input access style checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isActionMetadataFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n const runsMapping =\n root === null\n ? null\n : getMappingValueAsMapping(root, \"runs\");\n\n if (runsMapping === null) {\n return;\n }\n\n const usingRuntime = getScalarStringValue(\n runsMapping.pairs.find(\n (pair) => getScalarStringValue(pair.key) === \"using\"\n )?.value\n );\n\n if (usingRuntime !== \"composite\") {\n return;\n }\n\n visitYamlStringScalars(runsMapping, (node, value) => {\n const firstMatch = value.match(\n inputEnvironmentPattern\n )?.[0];\n\n if (firstMatch === undefined) {\n return;\n }\n\n context.report({\n data: {\n inputEnvironmentReference: firstMatch,\n },\n messageId: \"compositeInputEnvAccess\",\n node: node as unknown as Rule.Node,\n });\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.actionMetadata\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow `INPUT_*` environment-variable access in composite actions and require `inputs.*` context references.\",\n dialects: [\"GitHub Action metadata\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R049\",\n ruleNumber: 49,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-composite-input-env-access\",\n },\n messages: {\n compositeInputEnvAccess:\n \"Composite actions should reference inputs via `inputs.*`, not environment variable '{{inputEnvironmentReference}}'.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow deprecated Node.js action runtimes.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isActionMetadataFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Deprecated Node runtime values for `runs.using`. */\nconst deprecatedNodeRuntimes = new Set([\"node12\", \"node16\"]);\n\n/** Rule implementation for deprecated Node runtime checks in action metadata. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isActionMetadataFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const runsMapping = getMappingValueAsMapping(root, \"runs\");\n\n if (runsMapping === null) {\n return;\n }\n\n const usingPair = runsMapping.pairs.find(\n (pair) => getScalarStringValue(pair.key) === \"using\"\n );\n const usingRuntime = getScalarStringValue(usingPair?.value);\n\n if (\n usingRuntime === null ||\n !deprecatedNodeRuntimes.has(usingRuntime)\n ) {\n return;\n }\n\n context.report({\n data: {\n runtime: usingRuntime,\n },\n messageId: \"deprecatedNodeRuntime\",\n node: (usingPair?.value ??\n usingPair) as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.actionMetadata\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow deprecated Node.js runtimes in action metadata `runs.using`.\",\n dialects: [\"GitHub Action metadata\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R044\",\n ruleNumber: 44,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-deprecated-node-runtime\",\n },\n messages: {\n deprecatedNodeRuntime:\n \"Action metadata uses deprecated runtime `{{runtime}}` for `runs.using`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow duplicate step IDs in composite actions.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isActionMetadataFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for duplicate composite step ID checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isActionMetadataFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n const runsMapping =\n root === null\n ? null\n : getMappingValueAsMapping(root, \"runs\");\n\n if (runsMapping === null) {\n return;\n }\n\n const usingRuntime = getScalarStringValue(\n getMappingPair(runsMapping, \"using\")?.value\n );\n\n if (usingRuntime !== \"composite\") {\n return;\n }\n\n const stepsSequence = getMappingValueAsSequence(\n runsMapping,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n return;\n }\n\n const firstSeenByStepId = new Set<string>();\n\n for (const stepEntry of stepsSequence.entries) {\n const stepMapping = unwrapYamlValue(stepEntry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const stepIdPair = getMappingPair(stepMapping, \"id\");\n const stepId = getScalarStringValue(stepIdPair?.value);\n\n if (stepId === null) {\n continue;\n }\n\n if (!firstSeenByStepId.has(stepId)) {\n firstSeenByStepId.add(stepId);\n\n continue;\n }\n\n context.report({\n data: {\n stepId,\n },\n messageId: \"duplicateCompositeStepId\",\n node: (stepIdPair?.value ??\n stepIdPair) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.actionMetadata\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow duplicate step IDs in `runs.steps` for composite actions.\",\n dialects: [\"GitHub Action metadata\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R051\",\n ruleNumber: 51,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-duplicate-composite-step-id\",\n },\n messages: {\n duplicateCompositeStepId:\n \"Composite step id '{{stepId}}' is declared more than once.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Helpers for reading workflow-template metadata from `.properties.json` files.\n */\n/* eslint-disable @typescript-eslint/prefer-readonly-parameter-types -- YAML parser AST nodes are third-party mutable structures; readonly wrappers reduce interoperability across helper APIs. */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport { dirname, join } from \"node:path\";\n\nimport {\n getMappingPair,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"./workflow-yaml.js\";\n\n/** Read and return the template metadata root mapping if present. */\nexport const getWorkflowTemplatePropertiesRoot = (\n context: Rule.RuleContext\n): AST.YAMLMapping | null => getWorkflowRoot(context);\n\n/** Read a scalar string property from workflow-template metadata. */\nexport const getWorkflowTemplateStringProperty = (\n root: AST.YAMLMapping,\n key: string\n): null | string => getScalarStringValue(getMappingPair(root, key)?.value);\n\n/** Resolve `filePatterns` entries with both node and scalar string value. */\nexport const getWorkflowTemplateFilePatternEntries = (\n root: AST.YAMLMapping\n): readonly Readonly<{ node: AST.YAMLNode; value: string }>[] => {\n const filePatternsSequence = getMappingValueAsSequence(\n root,\n \"filePatterns\"\n );\n\n if (filePatternsSequence === null) {\n return [];\n }\n\n const entries: Readonly<{ node: AST.YAMLNode; value: string }>[] = [];\n\n for (const entry of filePatternsSequence.entries) {\n const entryValue = getScalarStringValue(entry);\n\n if (entryValue === null || entry === null || entry === undefined) {\n continue;\n }\n\n entries.push({\n node: entry,\n value: entryValue,\n });\n }\n\n return entries;\n};\n/* eslint-enable @typescript-eslint/prefer-readonly-parameter-types -- Re-enable readonly-parameter checks outside parser AST helper signatures. */\n\n/** Build the matching `.properties.json` path for a template YAML path. */\nexport const getPairedTemplatePropertiesPath = (filePath: string): string => {\n const stem = filePath.endsWith(\".yaml\")\n ? filePath.slice(0, -\".yaml\".length)\n : filePath.slice(0, -\".yml\".length);\n\n return `${stem}.properties.json`;\n};\n\n/** Build both valid template YAML paths for a `.properties.json` path. */\nexport const getPairedTemplateYamlPaths = (\n filePath: string\n): readonly [string, string] => {\n const fileDirectory = dirname(filePath);\n const fileName = filePath.slice(fileDirectory.length + 1);\n const stem = fileName.slice(0, -\".properties.json\".length);\n\n return [\n join(fileDirectory, `${stem}.yml`),\n join(fileDirectory, `${stem}.yaml`),\n ];\n};\n", "/**\n * @packageDocumentation\n * Shared range helpers for safe YAML/JSON text fixes.\n */\n\n/** Determine whether a character is horizontal whitespace. */\nconst isHorizontalWhitespace = (character: string | undefined): boolean =>\n character === \" \" || character === \"\\t\";\n\n/** Determine whether a character is any whitespace. */\nconst isWhitespace = (character: string | undefined): boolean =>\n character === \" \" ||\n character === \"\\t\" ||\n character === \"\\n\" ||\n character === \"\\r\";\n\n/** Return the start index of the line containing the provided offset. */\nconst getLineStartIndex = (sourceText: string, offset: number): number => {\n const previousLineBreakIndex = sourceText.lastIndexOf(\n \"\\n\",\n Math.max(0, offset - 1)\n );\n\n return previousLineBreakIndex === -1 ? 0 : previousLineBreakIndex + 1;\n};\n\n/** Return the end index of the line containing the provided offset. */\nconst getLineEndIndex = (sourceText: string, offset: number): number => {\n const nextLineBreakIndex = sourceText.indexOf(\"\\n\", offset);\n\n return nextLineBreakIndex === -1 ? sourceText.length : nextLineBreakIndex;\n};\n\n/** Read the indentation prefix of the line containing the provided offset. */\nexport const getLineIndentation = (\n sourceText: string,\n offset: number\n): string => {\n const lineStart = getLineStartIndex(sourceText, offset);\n let index = lineStart;\n\n while (\n index < sourceText.length &&\n isHorizontalWhitespace(sourceText[index])\n ) {\n index += 1;\n }\n\n return sourceText.slice(lineStart, index);\n};\n\n/** Return the insertion point immediately after the line containing the offset. */\nexport const getIndexAfterLine = (\n sourceText: string,\n offset: number\n): number => {\n const lineEnd = getLineEndIndex(sourceText, offset);\n\n return lineEnd === sourceText.length ? sourceText.length : lineEnd + 1;\n};\n\n/** Expand a node range to cover its entire containing line. */\nexport const getEnclosingLineRemovalRange = (\n sourceText: string,\n range: readonly [number, number]\n): [number, number] => {\n const previousLineBreakIndex = sourceText.lastIndexOf(\n \"\\n\",\n Math.max(0, range[0] - 1)\n );\n const start =\n previousLineBreakIndex === -1 ? 0 : previousLineBreakIndex + 1;\n const nextLineBreakIndex = sourceText.indexOf(\"\\n\", range[1]);\n const end =\n nextLineBreakIndex === -1 ? sourceText.length : nextLineBreakIndex + 1;\n\n return [start, end];\n};\n\n/** Safely remove a flow-style sequence entry and its adjacent delimiter. */\nexport const getFlowSequenceEntryRemovalRange = (\n sourceText: string,\n range: readonly [number, number]\n): [number, number] => {\n let start = range[0];\n let end = range[1];\n\n while (start > 0 && isHorizontalWhitespace(sourceText[start - 1])) {\n start -= 1;\n }\n\n while (end < sourceText.length && isHorizontalWhitespace(sourceText[end])) {\n end += 1;\n }\n\n let nextIndex = end;\n\n while (\n nextIndex < sourceText.length &&\n isWhitespace(sourceText[nextIndex])\n ) {\n nextIndex += 1;\n }\n\n if (sourceText[nextIndex] === \",\") {\n end = nextIndex + 1;\n\n while (\n end < sourceText.length &&\n isHorizontalWhitespace(sourceText[end])\n ) {\n end += 1;\n }\n\n return [start, end];\n }\n\n let previousIndex = start - 1;\n\n while (previousIndex >= 0 && isWhitespace(sourceText[previousIndex])) {\n previousIndex -= 1;\n }\n\n if (sourceText[previousIndex] === \",\") {\n return [previousIndex, end];\n }\n\n return [start, end];\n};\n", "/**\n * @packageDocumentation\n * Disallow empty or whitespace-only `filePatterns` entries.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowTemplatePropertiesFile } from \"../_internal/lint-targets.js\";\nimport {\n getWorkflowTemplateFilePatternEntries,\n getWorkflowTemplatePropertiesRoot,\n} from \"../_internal/workflow-template-properties.js\";\nimport { getFlowSequenceEntryRemovalRange } from \"../_internal/yaml-fixes.js\";\n\n/** Rule implementation for empty template file pattern checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowTemplatePropertiesRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const {\n node,\n value,\n } of getWorkflowTemplateFilePatternEntries(root)) {\n if (value.trim().length > 0) {\n continue;\n }\n\n context.report({\n fix: (fixer) =>\n fixer.removeRange(\n getFlowSequenceEntryRemovalRange(\n context.sourceCode.text,\n node.range\n )\n ),\n messageId: \"emptyTemplateFilePattern\",\n node: node as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow empty or whitespace-only entries in workflow-template `filePatterns`.\",\n dialects: [\"GitHub Actions workflow template metadata\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R060\",\n ruleNumber: 60,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-empty-template-file-pattern\",\n },\n fixable: \"code\",\n messages: {\n emptyTemplateFilePattern:\n \"Template `filePatterns` entries must be non-empty regex strings.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow defining jobs as reusable workflow invocations via `uses`.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getWorkflowJobs,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for disallowing reusable-workflow jobs. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n const usesPair = getMappingPair(job.mapping, \"uses\");\n\n if (usesPair === null) {\n continue;\n }\n\n context.report({\n data: {\n jobId: job.id,\n },\n messageId: \"externalJob\",\n node: (usesPair.value ??\n usesPair) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow reusable-workflow jobs declared with `jobs.<id>.uses` when you want every job defined inline in the workflow file.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R012\",\n ruleNumber: 12,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-external-job\",\n },\n messages: {\n externalJob:\n \"Job '{{jobId}}' uses a reusable workflow via `uses`. Define the job inline instead.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow hardcoded default branch names in workflow templates.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowTemplateYamlFile } from \"../_internal/lint-targets.js\";\nimport { getWorkflowRoot } from \"../_internal/workflow-yaml.js\";\nimport { visitYamlStringScalars } from \"../_internal/yaml-traversal.js\";\n\n/** Branch literals that should be replaced with `$default-branch` in templates. */\nconst hardcodedDefaultBranchNames = new Set([\"main\", \"master\"]);\n\n/** Rule implementation for hardcoded default branch checks in templates. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isWorkflowTemplateYamlFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n visitYamlStringScalars(root, (node, value) => {\n if (!hardcodedDefaultBranchNames.has(value.trim())) {\n return;\n }\n\n context.report({\n data: {\n branchName: value,\n },\n messageId: \"hardcodedDefaultBranch\",\n node: node as unknown as Rule.Node,\n });\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow hardcoded `main`/`master` branch literals in workflow template YAML files.\",\n dialects: [\"GitHub Actions workflow template\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R068\",\n ruleNumber: 68,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-hardcoded-default-branch-in-template\",\n },\n messages: {\n hardcodedDefaultBranch:\n \"Template contains hardcoded default branch '{{branchName}}'; prefer `$default-branch` placeholder.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow including `.svg` extension in workflow-template `iconName`.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowTemplatePropertiesFile } from \"../_internal/lint-targets.js\";\nimport { getWorkflowTemplatePropertiesRoot } from \"../_internal/workflow-template-properties.js\";\nimport {\n getMappingPair,\n getScalarStringValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for `iconName` extension checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowTemplatePropertiesRoot(context);\n\n if (root === null) {\n return;\n }\n\n const iconNamePair = getMappingPair(root, \"iconName\");\n const iconNameNode = iconNamePair?.value ?? null;\n const iconName = getScalarStringValue(iconNameNode);\n\n if (iconName === null) {\n return;\n }\n\n if (!iconName.toLowerCase().endsWith(\".svg\")) {\n return;\n }\n\n context.report({\n data: {\n iconName,\n },\n fix: (fixer) =>\n iconNameNode === null\n ? null\n : fixer.replaceTextRange(\n iconNameNode.range,\n JSON.stringify(\n iconName.slice(0, -\".svg\".length)\n )\n ),\n messageId: \"iconNameIncludesExtension\",\n node: (iconNameNode ?? node) as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow `.svg` extensions in workflow-template `iconName` values.\",\n dialects: [\"GitHub Actions workflow template metadata\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R063\",\n ruleNumber: 63,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-icon-file-extension-in-template-icon-name\",\n },\n fixable: \"code\",\n messages: {\n iconNameIncludesExtension:\n \"Template `iconName` '{{iconName}}' should omit the `.svg` extension.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow broad reusable-workflow secret inheritance.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Determine whether a job references a reusable workflow. */\nconst isReusableWorkflowJob = (\n jobMapping: Readonly<AST.YAMLMapping>\n): boolean => getMappingPair(jobMapping, \"uses\") !== null;\n\n/** Determine whether a secrets pair uses the broad `inherit` shortcut. */\nconst isInheritSecretsValue = (\n secretsPair: Readonly<NonNullable<ReturnType<typeof getMappingPair>>>\n): boolean => getScalarStringValue(secretsPair.value)?.trim() === \"inherit\";\n\n/** Rule implementation for disallowing reusable-workflow `secrets: inherit`. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n if (!isReusableWorkflowJob(job.mapping)) {\n continue;\n }\n\n const secretsPair = getMappingPair(job.mapping, \"secrets\");\n\n if (\n secretsPair === null ||\n !isInheritSecretsValue(secretsPair)\n ) {\n continue;\n }\n\n context.report({\n data: {\n jobId: job.id,\n },\n messageId: \"inheritedSecrets\",\n node: secretsPair.value as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.security\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow `secrets: inherit` on reusable-workflow jobs so callers pass only the named secrets each workflow actually needs.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R026\",\n ruleNumber: 26,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-inherit-secrets\",\n },\n messages: {\n inheritedSecrets:\n \"Job '{{jobId}}' uses `secrets: inherit`. Pass only the specific named secrets the called workflow requires.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Shared helpers for extracting GitHub Actions `${{ ... }}` expressions.\n */\n\n/** Determine whether a character can begin a GitHub expression identifier. */\nconst isIdentifierStart = (character: string | undefined): boolean => {\n if (character === undefined) {\n return false;\n }\n\n return /[A-Z_a-z]/u.test(character);\n};\n\n/** Determine whether a character can continue a GitHub expression identifier. */\nconst isIdentifierContinue = (character: string | undefined): boolean => {\n if (character === undefined) {\n return false;\n }\n\n return /[\\w-]/u.test(character);\n};\n\n/** Known root context names available in GitHub Actions expressions. */\nconst knownContextRoots: ReadonlySet<string> = new Set([\n \"env\",\n \"github\",\n \"inputs\",\n \"job\",\n \"jobs\",\n \"matrix\",\n \"needs\",\n \"runner\",\n \"secrets\",\n \"steps\",\n \"strategy\",\n \"vars\",\n]);\n\n/** Extract every embedded GitHub expression body from a scalar value. */\nexport const getGithubExpressionBodies = (value: string): readonly string[] => {\n const expressions: string[] = [];\n let searchStart = 0;\n\n while (searchStart < value.length) {\n const startOffset = value.indexOf(\"${{\", searchStart);\n\n if (startOffset === -1) {\n break;\n }\n\n const endOffset = value.indexOf(\"}}\", startOffset + 3);\n\n if (endOffset === -1) {\n break;\n }\n\n const expression = value.slice(startOffset + 3, endOffset).trim();\n\n if (expression.length > 0) {\n expressions.push(expression);\n }\n\n searchStart = endOffset + 2;\n }\n\n return expressions;\n};\n\n/** Collect referenced root contexts from embedded GitHub expressions. */\nexport const getReferencedContextRoots = (value: string): readonly string[] => {\n const roots = new Set<string>();\n\n for (const expression of getGithubExpressionBodies(value)) {\n let index = 0;\n\n while (index < expression.length) {\n const character = expression[index];\n const previousCharacter = expression[index - 1];\n\n if (\n !isIdentifierStart(character) ||\n isIdentifierContinue(previousCharacter)\n ) {\n index += 1;\n\n continue;\n }\n\n let endOffset = index + 1;\n\n while (isIdentifierContinue(expression[endOffset])) {\n endOffset += 1;\n }\n\n const token = expression.slice(index, endOffset);\n const nextChar = expression[endOffset];\n\n if (nextChar !== \".\" && nextChar !== \"[\") {\n index = endOffset;\n\n continue;\n }\n\n const normalizedToken = token.toLowerCase();\n\n if (knownContextRoots.has(normalizedToken)) {\n roots.add(normalizedToken);\n }\n\n index = endOffset;\n }\n }\n\n return [...roots];\n};\n", "/**\n * @packageDocumentation\n * Disallow unavailable contexts inside workflow and job concurrency expressions.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getGithubExpressionBodies,\n getReferencedContextRoots,\n} from \"../_internal/github-expressions.js\";\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Allowed contexts for top-level workflow `concurrency`. */\nconst allowedWorkflowConcurrencyContexts: ReadonlySet<string> = new Set([\n \"github\",\n \"inputs\",\n \"vars\",\n]);\n\n/** Allowed contexts for `jobs.<job_id>.concurrency`. */\nconst allowedJobConcurrencyContexts: ReadonlySet<string> = new Set([\n \"github\",\n \"inputs\",\n \"matrix\",\n \"needs\",\n \"strategy\",\n \"vars\",\n]);\n\n/** Determine whether a scalar contains any GitHub expressions. */\nconst containsGithubExpression = (value: string): boolean =>\n getGithubExpressionBodies(value).length > 0;\n\n/** Collect disallowed context roots for the provided scalar value. */\nconst getDisallowedContexts = (\n value: string,\n allowedContexts: ReadonlySet<string>\n): readonly string[] =>\n getReferencedContextRoots(value).filter(\n (contextRoot) => !allowedContexts.has(contextRoot)\n );\n\n/** Check a single concurrency scalar for unsupported context usage. */\nconst reportInvalidContexts = (\n context: Readonly<Rule.RuleContext>,\n options: Readonly<{\n readonly allowedContexts: ReadonlySet<string>;\n readonly field: string;\n readonly jobId: string | undefined;\n readonly messageId:\n | \"invalidJobConcurrencyContext\"\n | \"invalidWorkflowConcurrencyContext\";\n readonly node: unknown;\n readonly value: string;\n }>\n): void => {\n if (!containsGithubExpression(options.value)) {\n return;\n }\n\n const disallowedContexts = getDisallowedContexts(\n options.value,\n options.allowedContexts\n );\n\n if (disallowedContexts.length === 0) {\n return;\n }\n\n context.report({\n data: {\n contexts: disallowedContexts.join(\", \"),\n field: options.field,\n jobId: options.jobId,\n },\n messageId: options.messageId,\n node: options.node as Rule.Node,\n });\n};\n\n/** Inspect a workflow-level or job-level concurrency declaration. */\nconst inspectConcurrencyValue = (\n context: Readonly<Rule.RuleContext>,\n options: Readonly<{\n readonly allowedContexts: ReadonlySet<string>;\n readonly concurrencyNode: Parameters<typeof unwrapYamlValue>[0];\n readonly jobId: string | undefined;\n readonly messageId:\n | \"invalidJobConcurrencyContext\"\n | \"invalidWorkflowConcurrencyContext\";\n }>\n): void => {\n const concurrencyValue = unwrapYamlValue(options.concurrencyNode);\n\n if (concurrencyValue === null) {\n return;\n }\n\n if (concurrencyValue.type === \"YAMLScalar\") {\n const scalarValue = getScalarStringValue(concurrencyValue);\n\n if (scalarValue === null || scalarValue.trim().length === 0) {\n return;\n }\n\n reportInvalidContexts(context, {\n allowedContexts: options.allowedContexts,\n field: \"concurrency\",\n jobId: options.jobId,\n messageId: options.messageId,\n node: concurrencyValue,\n value: scalarValue,\n });\n\n return;\n }\n\n if (concurrencyValue.type !== \"YAMLMapping\") {\n return;\n }\n\n for (const fieldName of [\"group\", \"cancel-in-progress\"] as const) {\n const fieldPair = getMappingPair(concurrencyValue, fieldName);\n\n if (fieldPair === null) {\n continue;\n }\n\n const fieldValueNode = unwrapYamlValue(fieldPair.value);\n const fieldValue = getScalarStringValue(fieldValueNode);\n\n if (fieldValue === null || fieldValue.trim().length === 0) {\n continue;\n }\n\n reportInvalidContexts(context, {\n allowedContexts: options.allowedContexts,\n field: `concurrency.${fieldName}`,\n jobId: options.jobId,\n messageId: options.messageId,\n node: fieldValueNode ?? fieldPair,\n value: fieldValue,\n });\n }\n};\n\n/** Rule implementation for validating concurrency context usage. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const workflowConcurrencyPair = getMappingPair(\n root,\n \"concurrency\"\n );\n\n if (workflowConcurrencyPair !== null) {\n inspectConcurrencyValue(context, {\n allowedContexts: allowedWorkflowConcurrencyContexts,\n concurrencyNode: workflowConcurrencyPair.value,\n jobId: undefined,\n messageId: \"invalidWorkflowConcurrencyContext\",\n });\n }\n\n for (const job of getWorkflowJobs(root)) {\n const jobConcurrencyPair = getMappingPair(\n job.mapping,\n \"concurrency\"\n );\n\n if (jobConcurrencyPair === null) {\n continue;\n }\n\n inspectConcurrencyValue(context, {\n allowedContexts: allowedJobConcurrencyContexts,\n concurrencyNode: jobConcurrencyPair.value,\n jobId: job.id,\n messageId: \"invalidJobConcurrencyContext\",\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow unavailable contexts in workflow-level and job-level `concurrency` expressions.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R042\",\n ruleNumber: 42,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-invalid-concurrency-context\",\n },\n messages: {\n invalidJobConcurrencyContext:\n \"Job '{{jobId}}' `{{field}}` references unsupported context access ({{contexts}}). Job-level concurrency may only reference `github`, `needs`, `strategy`, `matrix`, `inputs`, and `vars`.\",\n invalidWorkflowConcurrencyContext:\n \"Workflow `{{field}}` references unsupported context access ({{contexts}}). Top-level concurrency may only reference `github`, `inputs`, and `vars`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow invalid keys in GitHub Actions workflow mappings.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport { isWorkflowFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingValueAsMapping,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Valid top-level workflow keys. */\nconst VALID_TOP_LEVEL_KEYS = new Set<string>([\n \"concurrency\",\n \"defaults\",\n \"env\",\n \"jobs\",\n \"name\",\n \"on\",\n \"permissions\",\n \"run-name\",\n]);\n\n/** Valid job-level keys under `jobs.<job_id>`. */\nconst VALID_JOB_KEYS = new Set<string>([\n \"concurrency\",\n \"container\",\n \"continue-on-error\",\n \"defaults\",\n \"env\",\n \"environment\",\n \"if\",\n \"name\",\n \"needs\",\n \"outputs\",\n \"permissions\",\n \"runs-on\",\n \"secrets\",\n \"services\",\n \"steps\",\n \"strategy\",\n \"timeout-minutes\",\n \"uses\",\n \"with\",\n]);\n\n/** Valid strategy keys under `jobs.<job_id>.strategy`. */\nconst VALID_STRATEGY_KEYS = new Set<string>([\n \"fail-fast\",\n \"matrix\",\n \"max-parallel\",\n]);\n\n/** Valid container and service keys. */\nconst VALID_CONTAINER_OR_SERVICE_KEYS = new Set<string>([\n \"credentials\",\n \"env\",\n \"image\",\n \"options\",\n \"ports\",\n \"volumes\",\n]);\n\n/** Valid step keys under `jobs.<job_id>.steps[]`. */\nconst VALID_STEP_KEYS = new Set<string>([\n \"continue-on-error\",\n \"env\",\n \"id\",\n \"if\",\n \"name\",\n \"run\",\n \"shell\",\n \"timeout-minutes\",\n \"uses\",\n \"with\",\n \"working-directory\",\n]);\n\n/** Report invalid mapping keys for one workflow section. */\nconst reportInvalidKeys = (\n context: Readonly<Rule.RuleContext>,\n mapping: Readonly<AST.YAMLMapping>,\n validKeys: ReadonlySet<string>,\n messageId:\n | \"invalidContainerKey\"\n | \"invalidJobKey\"\n | \"invalidServiceKey\"\n | \"invalidStepKey\"\n | \"invalidStrategyKey\"\n | \"invalidTopLevelKey\"\n): void => {\n for (const pair of mapping.pairs) {\n const keyValue = getScalarStringValue(pair.key);\n\n if (keyValue === null || validKeys.has(keyValue)) {\n continue;\n }\n\n context.report({\n data: {\n key: keyValue,\n },\n messageId,\n node: (pair.key ?? pair) as unknown as Rule.Node,\n });\n }\n};\n\n/** Rule implementation for validating workflow mapping keys. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isWorkflowFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n reportInvalidKeys(\n context,\n root,\n VALID_TOP_LEVEL_KEYS,\n \"invalidTopLevelKey\"\n );\n\n for (const job of getWorkflowJobs(root)) {\n reportInvalidKeys(\n context,\n job.mapping,\n VALID_JOB_KEYS,\n \"invalidJobKey\"\n );\n\n const strategyMapping = getMappingValueAsMapping(\n job.mapping,\n \"strategy\"\n );\n\n if (strategyMapping !== null) {\n reportInvalidKeys(\n context,\n strategyMapping,\n VALID_STRATEGY_KEYS,\n \"invalidStrategyKey\"\n );\n }\n\n const containerMapping = getMappingValueAsMapping(\n job.mapping,\n \"container\"\n );\n\n if (containerMapping !== null) {\n reportInvalidKeys(\n context,\n containerMapping,\n VALID_CONTAINER_OR_SERVICE_KEYS,\n \"invalidContainerKey\"\n );\n }\n\n const servicesMapping = getMappingValueAsMapping(\n job.mapping,\n \"services\"\n );\n\n if (servicesMapping !== null) {\n for (const servicePair of servicesMapping.pairs) {\n const serviceMapping = unwrapYamlValue(\n servicePair.value\n );\n\n if (serviceMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n reportInvalidKeys(\n context,\n serviceMapping,\n VALID_CONTAINER_OR_SERVICE_KEYS,\n \"invalidServiceKey\"\n );\n }\n }\n\n const stepsSequence = getMappingValueAsSequence(\n job.mapping,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n continue;\n }\n\n for (const step of stepsSequence.entries) {\n const stepMapping = unwrapYamlValue(step);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n reportInvalidKeys(\n context,\n stepMapping,\n VALID_STEP_KEYS,\n \"invalidStepKey\"\n );\n }\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow unsupported keys in common GitHub Actions workflow mappings.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R019\",\n ruleNumber: 19,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-invalid-key\",\n },\n messages: {\n invalidContainerKey:\n \"`{{key}}` is not a valid key for a job `container` block.\",\n invalidJobKey:\n \"`{{key}}` is not a valid key for a workflow job definition.\",\n invalidServiceKey:\n \"`{{key}}` is not a valid key for a job `services` entry.\",\n invalidStepKey: \"`{{key}}` is not a valid key for a workflow step.\",\n invalidStrategyKey:\n \"`{{key}}` is not a valid key for a job `strategy` block.\",\n invalidTopLevelKey:\n \"`{{key}}` is not a valid top-level workflow key.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow unsupported keys on jobs that call reusable workflows.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Supported keywords for jobs that call reusable workflows via `uses`. */\nconst reusableWorkflowJobKeys = [\n \"name\",\n \"uses\",\n \"with\",\n \"secrets\",\n \"strategy\",\n \"needs\",\n \"if\",\n \"concurrency\",\n \"permissions\",\n] as const;\n\n/** Constant-time lookup for supported reusable-workflow caller job keys. */\nconst reusableWorkflowJobKeySet: ReadonlySet<string> = new Set(\n reusableWorkflowJobKeys\n);\n\n/** Determine whether a job calls a reusable workflow. */\nconst isReusableWorkflowJob = (\n jobMapping: Readonly<AST.YAMLMapping>\n): boolean => getMappingPair(jobMapping, \"uses\") !== null;\n\n/** Rule implementation for validating reusable-workflow caller job keys. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n if (!isReusableWorkflowJob(job.mapping)) {\n continue;\n }\n\n for (const pair of job.mapping.pairs) {\n const key = getScalarStringValue(pair.key);\n\n if (\n key === null ||\n reusableWorkflowJobKeySet.has(key)\n ) {\n continue;\n }\n\n context.report({\n data: {\n allowedKeys: reusableWorkflowJobKeys.join(\", \"),\n jobId: job.id,\n key,\n },\n messageId: \"invalidReusableWorkflowJobKey\",\n node: pair.key as unknown as Rule.Node,\n });\n }\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow unsupported keys on jobs that call reusable workflows via `jobs.<job_id>.uses`.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R041\",\n ruleNumber: 41,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-invalid-reusable-workflow-job-key\",\n },\n messages: {\n invalidReusableWorkflowJobKey:\n \"Job '{{jobId}}' calls a reusable workflow via `uses`, so `{{key}}` is not supported here. Caller jobs may only use: {{allowedKeys}}.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow invalid regular expressions in workflow-template `filePatterns`.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowTemplatePropertiesFile } from \"../_internal/lint-targets.js\";\nimport {\n getWorkflowTemplateFilePatternEntries,\n getWorkflowTemplatePropertiesRoot,\n} from \"../_internal/workflow-template-properties.js\";\n\n/** Construct a unicode regex from a pattern string. */\nconst createUnicodeRegex = (pattern: string): RegExp =>\n // eslint-disable-next-line security/detect-non-literal-regexp -- Intentional syntax validation of user-provided regex patterns.\n new RegExp(pattern, \"u\");\n\n/** Rule implementation for validating `filePatterns` regex syntax. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowTemplatePropertiesRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const {\n node,\n value,\n } of getWorkflowTemplateFilePatternEntries(root)) {\n try {\n createUnicodeRegex(value);\n } catch {\n context.report({\n data: {\n pattern: value,\n },\n messageId: \"invalidTemplateFilePatternRegex\",\n node: node as unknown as Rule.Node,\n });\n }\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow syntactically invalid regexes in workflow-template `filePatterns`.\",\n dialects: [\"GitHub Actions workflow template metadata\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R059\",\n ruleNumber: 59,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-invalid-template-file-pattern-regex\",\n },\n messages: {\n invalidTemplateFilePatternRegex:\n \"Template `filePatterns` entry '{{pattern}}' is not a valid regular expression.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow invalid reusable workflow output values.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getGithubExpressionBodies,\n getReferencedContextRoots,\n} from \"../_internal/github-expressions.js\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Match reusable workflow output mappings to job outputs. */\nconst jobsOutputReferencePattern =\n /jobs\\.[A-Z_a-z][\\w-]*\\.outputs\\.[A-Z_a-z][\\w-]*/;\n\n/** Allowed expression contexts for `on.workflow_call.outputs.*.value`. */\nconst allowedWorkflowCallOutputContexts: ReadonlySet<string> = new Set([\n \"github\",\n \"inputs\",\n \"jobs\",\n \"vars\",\n]);\n\n/** Determine whether a scalar value reads at least one declared job output. */\nconst hasJobsOutputReference = (value: string): boolean =>\n getGithubExpressionBodies(value).some((expression) =>\n jobsOutputReferencePattern.test(expression)\n );\n\n/** Rule implementation for validating reusable workflow output values. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const onMapping = getMappingValueAsMapping(root, \"on\");\n\n if (onMapping === null) {\n return;\n }\n\n const workflowCallMapping = unwrapYamlValue(\n getMappingPair(onMapping, \"workflow_call\")?.value ?? null\n );\n\n if (workflowCallMapping?.type !== \"YAMLMapping\") {\n return;\n }\n\n const outputsMapping = getMappingValueAsMapping(\n workflowCallMapping,\n \"outputs\"\n );\n\n if (outputsMapping === null) {\n return;\n }\n\n for (const pair of outputsMapping.pairs) {\n const outputId = getScalarStringValue(pair.key);\n const outputMapping = unwrapYamlValue(pair.value);\n\n if (\n outputId === null ||\n outputMapping?.type !== \"YAMLMapping\"\n ) {\n continue;\n }\n\n const valuePair = getMappingPair(outputMapping, \"value\");\n const value = getScalarStringValue(\n valuePair?.value ?? null\n );\n\n if (\n valuePair === null ||\n value === null ||\n value.trim().length === 0\n ) {\n continue;\n }\n\n const disallowedContexts = getReferencedContextRoots(\n value\n ).filter(\n (contextRoot) =>\n !allowedWorkflowCallOutputContexts.has(contextRoot)\n );\n\n if (disallowedContexts.length > 0) {\n context.report({\n data: {\n contexts: disallowedContexts.join(\", \"),\n outputId,\n },\n messageId: \"invalidContext\",\n node: (valuePair.value ??\n valuePair) as unknown as Rule.Node,\n });\n\n continue;\n }\n\n if (!hasJobsOutputReference(value)) {\n context.report({\n data: {\n outputId,\n },\n messageId: \"missingJobOutputReference\",\n node: (valuePair.value ??\n valuePair) as unknown as Rule.Node,\n });\n }\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow `workflow_call` output values that use unavailable contexts or fail to map from `jobs.<job_id>.outputs.<output_name>`.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R040\",\n ruleNumber: 40,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-invalid-workflow-call-output-value\",\n },\n messages: {\n invalidContext:\n \"`workflow_call` output '{{outputId}}' uses unsupported context access in `value` ({{contexts}}). Reusable workflow output values may only reference `github`, `jobs`, `vars`, and `inputs`.\",\n missingJobOutputReference:\n \"`workflow_call` output '{{outputId}}' must map `value` from a job output such as `jobs.build.outputs.artifact`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * YAML helpers for `.github/dependabot.yml` configuration files.\n */\n/* eslint-disable @typescript-eslint/prefer-readonly-parameter-types -- YAML AST nodes come from parser-owned mutable types shared across helper boundaries. */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport { isDependabotFile } from \"./lint-targets.js\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"./workflow-yaml.js\";\n\n/** Directory selector entry declared by a Dependabot update block. */\nexport type DependabotDirectorySelectorEntry = {\n readonly node: AST.YAMLNode;\n readonly value: string;\n};\n\n/** String scalar entry contained in a YAML sequence. */\nexport type DependabotStringSequenceEntry = {\n readonly node: AST.YAMLNode;\n readonly value: string;\n};\n\n/** Dependabot update block paired with derived metadata useful for reporting. */\nexport type DependabotUpdateEntry = {\n readonly index: number;\n readonly mapping: AST.YAMLMapping;\n readonly multiEcosystemGroup: null | string;\n readonly node: AST.YAMLContent | AST.YAMLWithMeta;\n readonly packageEcosystem: null | string;\n};\n\n/**\n * Normalize a scalar-like Dependabot string value into a trimmed non-empty\n * string.\n */\nexport const getDependabotTrimmedStringValue = (\n node: AST.YAMLContent | AST.YAMLWithMeta | null | undefined\n): null | string => {\n const stringValue = getScalarStringValue(node ?? null)?.trim();\n\n return stringValue === undefined || stringValue.length === 0\n ? null\n : stringValue;\n};\n\n/** Read a trimmed non-empty string value from a mapping pair by key. */\nexport const getDependabotMappingStringValue = (\n mapping: AST.YAMLMapping,\n key: string\n): null | string =>\n getDependabotTrimmedStringValue(\n getMappingPair(mapping, key)?.value ?? null\n );\n\n/** Resolve the root mapping for a Dependabot configuration file. */\nexport const getDependabotRoot = (\n context: Rule.RuleContext\n): AST.YAMLMapping | null =>\n isDependabotFile(context.filename) ? getWorkflowRoot(context) : null;\n\n/** Collect every valid update mapping under the top-level `updates` sequence. */\nexport const getDependabotUpdateEntries = (\n root: AST.YAMLMapping\n): readonly DependabotUpdateEntry[] => {\n const updatesSequence = getMappingValueAsSequence(root, \"updates\");\n\n if (updatesSequence === null) {\n return [];\n }\n\n const entries: DependabotUpdateEntry[] = [];\n\n for (const [index, entry] of updatesSequence.entries.entries()) {\n const updateMapping = unwrapYamlValue(entry);\n\n if (entry === null || entry === undefined) {\n continue;\n }\n\n if (updateMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n entries.push({\n index: index + 1,\n mapping: updateMapping,\n multiEcosystemGroup: getScalarStringValue(\n getMappingPair(updateMapping, \"multi-ecosystem-group\")?.value\n ),\n node: entry,\n packageEcosystem: getScalarStringValue(\n getMappingPair(updateMapping, \"package-ecosystem\")?.value\n ),\n });\n }\n\n return entries;\n};\n\n/** Resolve a named multi-ecosystem-group mapping by its declared group key. */\nexport const getDependabotMultiEcosystemGroup = (\n root: AST.YAMLMapping,\n groupName: string\n): AST.YAMLMapping | null => {\n const groupsMapping = getMappingValueAsMapping(\n root,\n \"multi-ecosystem-groups\"\n );\n\n if (groupsMapping === null) {\n return null;\n }\n\n for (const pair of groupsMapping.pairs) {\n if (getScalarStringValue(pair.key) !== groupName) {\n continue;\n }\n\n const groupMapping = unwrapYamlValue(pair.value);\n\n return groupMapping?.type === \"YAMLMapping\" ? groupMapping : null;\n }\n\n return null;\n};\n\n/** Resolve the referenced multi-ecosystem-group mapping for an update entry. */\nexport const getDependabotReferencedGroup = (\n root: AST.YAMLMapping,\n update: DependabotUpdateEntry\n): AST.YAMLMapping | null =>\n update.multiEcosystemGroup === null\n ? null\n : getDependabotMultiEcosystemGroup(root, update.multiEcosystemGroup);\n\n/**\n * Resolve an update-scoped value, falling back to the referenced group when\n * present.\n */\nexport const getEffectiveDependabotUpdateValue = (\n root: AST.YAMLMapping,\n update: DependabotUpdateEntry,\n key: string\n): AST.YAMLContent | AST.YAMLWithMeta | null => {\n const directValue = getMappingPair(update.mapping, key)?.value ?? null;\n\n if (directValue !== null) {\n return directValue;\n }\n\n return (\n getMappingPair(\n getDependabotReferencedGroup(root, update) ?? update.mapping,\n key\n )?.value ?? null\n );\n};\n\n/** Read a trimmed non-empty string value from an effective update-scoped key. */\nexport const getEffectiveDependabotStringValue = (\n root: AST.YAMLMapping,\n update: DependabotUpdateEntry,\n key: string\n): null | string =>\n getDependabotTrimmedStringValue(\n getEffectiveDependabotUpdateValue(root, update, key)\n );\n\n/**\n * Resolve an update-scoped mapping value, honoring multi-ecosystem-group\n * fallback.\n */\nexport const getEffectiveDependabotUpdateMapping = (\n root: AST.YAMLMapping,\n update: DependabotUpdateEntry,\n key: string\n): AST.YAMLMapping | null => {\n const value = unwrapYamlValue(\n getEffectiveDependabotUpdateValue(root, update, key)\n );\n\n return value?.type === \"YAMLMapping\" ? value : null;\n};\n\n/** Collect all non-empty string entries from a YAML sequence. */\nexport const getNonEmptyStringSequenceEntries = (\n node: AST.YAMLContent | AST.YAMLWithMeta | null | undefined\n): readonly DependabotStringSequenceEntry[] => {\n const sequence = unwrapYamlValue(node ?? null);\n\n if (sequence?.type !== \"YAMLSequence\") {\n return [];\n }\n\n const entries: DependabotStringSequenceEntry[] = [];\n\n for (const entry of sequence.entries) {\n const stringValue = getScalarStringValue(entry)?.trim();\n\n if (\n stringValue === undefined ||\n stringValue === null ||\n stringValue.length === 0 ||\n entry === null ||\n entry === undefined\n ) {\n continue;\n }\n\n entries.push({\n node: entry,\n value: stringValue,\n });\n }\n\n return entries;\n};\n\n/** Describe an update entry for human-readable diagnostics. */\nexport const getDependabotUpdateLabel = (\n update: DependabotUpdateEntry\n): string =>\n update.packageEcosystem === null\n ? `updates[${String(update.index)}]`\n : `updates[${String(update.index)}] (${update.packageEcosystem})`;\n\n/**\n * Resolve the effective target branch for an update, defaulting to the\n * repository default branch.\n */\nexport const getEffectiveDependabotTargetBranch = (\n root: AST.YAMLMapping,\n update: DependabotUpdateEntry\n): string => {\n const targetBranch = getEffectiveDependabotStringValue(\n root,\n update,\n \"target-branch\"\n );\n\n return targetBranch === null ? \"<default-branch>\" : targetBranch;\n};\n\n/** Collect normalized directory selectors declared by a Dependabot update block. */\nexport const getDependabotDirectorySelectorEntries = (\n update: DependabotUpdateEntry\n): readonly DependabotDirectorySelectorEntry[] => {\n const selectors: DependabotDirectorySelectorEntry[] = [];\n const directoryPair = getMappingPair(update.mapping, \"directory\");\n const directoryValue = getScalarStringValue(\n directoryPair?.value ?? null\n )?.trim();\n\n if (\n directoryPair?.value !== null &&\n directoryPair?.value !== undefined &&\n directoryValue !== undefined &&\n directoryValue !== null &&\n directoryValue.length > 0\n ) {\n selectors.push({\n node: directoryPair.value,\n value: directoryValue,\n });\n }\n\n const directoriesPair = getMappingPair(update.mapping, \"directories\");\n\n for (const entry of getNonEmptyStringSequenceEntries(\n directoriesPair?.value\n )) {\n selectors.push(entry);\n }\n\n return selectors;\n};\n\n/* eslint-enable @typescript-eslint/prefer-readonly-parameter-types -- Re-enable readonly-parameter checks outside parser AST helper signatures. */\n", "/**\n * @packageDocumentation\n * Disallow guaranteed overlapping Dependabot directory selectors for the same ecosystem and target branch.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n type DependabotUpdateEntry,\n getDependabotDirectorySelectorEntries,\n getDependabotRoot,\n getDependabotUpdateEntries,\n getDependabotUpdateLabel,\n getEffectiveDependabotTargetBranch,\n} from \"../_internal/dependabot-yaml.js\";\n\ntype SeenSelectorEntry = {\n readonly directoryNode: AST.YAMLNode;\n readonly directorySelector: string;\n readonly packageEcosystem: string;\n readonly targetBranch: string;\n readonly update: DependabotUpdateEntry;\n};\n\n/** Normalize a directory selector string for stable overlap comparison. */\nconst normalizeDirectorySelector = (selector: string): string => {\n const trimmedSelector = selector.trim().replaceAll(\"\\\\\", \"/\");\n\n if (trimmedSelector === \"/\") {\n return trimmedSelector;\n }\n\n return trimmedSelector.endsWith(\"/\")\n ? trimmedSelector.slice(0, -1)\n : trimmedSelector;\n};\n\n/** Determine whether a selector contains glob syntax. */\nconst hasGlobSyntax = (selector: string): boolean =>\n /[*?[\\]{}]/u.test(selector);\n\n/** Escape regex-significant characters except glob tokens handled separately. */\nconst escapeRegexLiteral = (value: string): string =>\n value.replaceAll(/[$()+.?[\\\\\\]^{|}]/gu, String.raw`\\$&`);\n\n/**\n * Convert a conservative subset of glob syntax into a regex for exact-path\n * overlap checks.\n */\nconst globSelectorToRegExp = (selector: string): RegExp => {\n let pattern = \"^\";\n\n let index = 0;\n\n while (index < selector.length) {\n const character = selector[index];\n\n if (character === undefined) {\n index += 1;\n continue;\n }\n\n const nextCharacter = selector[index + 1];\n\n if (character === \"*\" && nextCharacter === \"*\") {\n pattern += \".*\";\n index += 1;\n index += 1;\n continue;\n }\n\n if (character === \"*\") {\n pattern += \"[^/]*\";\n index += 1;\n continue;\n }\n\n if (character === \"?\") {\n pattern += \"[^/]\";\n index += 1;\n continue;\n }\n\n if (character === \"[\") {\n const closingBracketIndex = selector.indexOf(\"]\", index + 1);\n\n if (closingBracketIndex > index + 1) {\n pattern += selector.slice(index, closingBracketIndex + 1);\n index = closingBracketIndex;\n index += 1;\n continue;\n }\n }\n\n pattern += escapeRegexLiteral(character);\n index += 1;\n }\n\n pattern += \"$\";\n\n // eslint-disable-next-line security/detect-non-literal-regexp -- the pattern is derived from normalized repository-local Dependabot directory selectors, not user input from runtime requests\n return new RegExp(pattern, \"u\");\n};\n\n/** Determine whether two selectors are guaranteed to overlap. */\nconst selectorsDefinitelyOverlap = (\n leftSelector: string,\n rightSelector: string\n): boolean => {\n if (leftSelector === rightSelector) {\n return true;\n }\n\n const leftHasGlob = hasGlobSyntax(leftSelector);\n const rightHasGlob = hasGlobSyntax(rightSelector);\n\n if (leftHasGlob && !rightHasGlob) {\n return globSelectorToRegExp(leftSelector).test(rightSelector);\n }\n\n if (!leftHasGlob && rightHasGlob) {\n return globSelectorToRegExp(rightSelector).test(leftSelector);\n }\n\n return false;\n};\n\n/** Rule implementation for overlapping Dependabot directory selectors. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getDependabotRoot(context);\n\n if (root === null) {\n return;\n }\n\n const seenSelectors: SeenSelectorEntry[] = [];\n\n for (const update of getDependabotUpdateEntries(root)) {\n const packageEcosystem = update.packageEcosystem?.trim();\n\n if (\n packageEcosystem === undefined ||\n packageEcosystem === null ||\n packageEcosystem.length === 0\n ) {\n continue;\n }\n\n const targetBranch = getEffectiveDependabotTargetBranch(\n root,\n update\n );\n\n for (const selectorEntry of getDependabotDirectorySelectorEntries(\n update\n )) {\n const directorySelector = normalizeDirectorySelector(\n selectorEntry.value\n );\n\n const overlappingSelector = seenSelectors.find(\n (seenSelector) =>\n seenSelector.packageEcosystem ===\n packageEcosystem &&\n seenSelector.targetBranch === targetBranch &&\n selectorsDefinitelyOverlap(\n seenSelector.directorySelector,\n directorySelector\n )\n );\n\n if (overlappingSelector !== undefined) {\n context.report({\n data: {\n directorySelector,\n otherDirectorySelector:\n overlappingSelector.directorySelector,\n otherUpdateLabel: getDependabotUpdateLabel(\n overlappingSelector.update\n ),\n targetBranch,\n updateLabel:\n getDependabotUpdateLabel(update),\n },\n messageId: \"overlappingDependabotDirectories\",\n node: selectorEntry.node as unknown as Rule.Node,\n });\n\n continue;\n }\n\n seenSelectors.push({\n directoryNode: selectorEntry.node,\n directorySelector,\n packageEcosystem,\n targetBranch,\n update,\n });\n }\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.dependabot\",\n ],\n description:\n \"disallow guaranteed overlapping Dependabot directory selectors for the same package ecosystem and target branch.\",\n dialects: [\"Dependabot configuration\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R095\",\n ruleNumber: 95,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-overlapping-dependabot-directories\",\n },\n messages: {\n overlappingDependabotDirectories:\n \"{{updateLabel}} directory selector '{{directorySelector}}' overlaps with {{otherUpdateLabel}} selector '{{otherDirectorySelector}}' for package ecosystem updates targeting '{{targetBranch}}'.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow path separators in workflow-template `iconName` values.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowTemplatePropertiesFile } from \"../_internal/lint-targets.js\";\nimport { getWorkflowTemplatePropertiesRoot } from \"../_internal/workflow-template-properties.js\";\nimport {\n getMappingPair,\n getScalarStringValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for icon path-separator checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowTemplatePropertiesRoot(context);\n\n if (root === null) {\n return;\n }\n\n const iconNamePair = getMappingPair(root, \"iconName\");\n const iconNameNode = iconNamePair?.value ?? null;\n const iconName = getScalarStringValue(iconNameNode);\n\n if (\n iconName === null ||\n (!iconName.includes(\"/\") && !iconName.includes(\"\\\\\"))\n ) {\n return;\n }\n\n const suggestedIconName = iconName.split(/[/\\\\]/u).at(-1);\n\n context.report({\n data: {\n iconName,\n },\n messageId: \"iconNameContainsPathSeparator\",\n node: (iconNameNode ?? node) as unknown as Rule.Node,\n suggest:\n suggestedIconName === undefined ||\n suggestedIconName.length === 0 ||\n iconNameNode === null\n ? undefined\n : [\n {\n data: {\n iconName,\n suggestedIconName,\n },\n fix: (fixer) =>\n fixer.replaceTextRange(\n iconNameNode.range,\n JSON.stringify(suggestedIconName)\n ),\n messageId: \"replaceIconNameWithBasename\",\n },\n ],\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow path separators in workflow-template `iconName` values.\",\n dialects: [\"GitHub Actions workflow template metadata\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R064\",\n ruleNumber: 64,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-path-separators-in-template-icon-name\",\n },\n hasSuggestions: true,\n messages: {\n iconNameContainsPathSeparator:\n \"Template `iconName` '{{iconName}}' should be a plain icon token, not a path.\",\n replaceIconNameWithBasename:\n \"Replace '{{iconName}}' with '{{suggestedIconName}}'.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow `runs.post-if` when `runs.post` is not declared.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isActionMetadataFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\nimport { getEnclosingLineRemovalRange } from \"../_internal/yaml-fixes.js\";\n\n/** Rule implementation for invalid `runs.post-if` usage. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isActionMetadataFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n const runsMapping =\n root === null\n ? null\n : getMappingValueAsMapping(root, \"runs\");\n\n if (runsMapping === null) {\n return;\n }\n\n const postIfPair = getMappingPair(runsMapping, \"post-if\");\n\n if (\n postIfPair === null ||\n getMappingPair(runsMapping, \"post\")\n ) {\n return;\n }\n\n context.report({\n fix: (fixer) =>\n fixer.removeRange(\n getEnclosingLineRemovalRange(\n context.sourceCode.text,\n postIfPair.range\n )\n ),\n messageId: \"postIfWithoutPost\",\n node: (postIfPair.value ??\n postIfPair) as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.actionMetadata\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow `runs.post-if` when `runs.post` is not configured in action metadata.\",\n dialects: [\"GitHub Action metadata\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R046\",\n ruleNumber: 46,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-post-if-without-post\",\n },\n fixable: \"code\",\n messages: {\n postIfWithoutPost:\n \"`runs.post-if` is set, but `runs.post` is missing. Remove `post-if` or add `post`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow checking out pull-request head content in `pull_request_target` workflows.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowEventNames,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Detect `actions/checkout` references. */\nconst isCheckoutActionReference = (reference: string): boolean =>\n reference.startsWith(\"actions/checkout@\");\n\n/** Detect risky PR-head references in checkout parameters. */\nconst hasPullRequestHeadReference = (value: string): boolean =>\n /\\bgithub\\.head_ref\\b/u.test(value) ||\n /\\bgithub\\.event\\.pull_request\\.head\\./u.test(value);\n\n/**\n * Rule implementation for disallowing pull-request head checkouts in\n * pull_request_target.\n */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const eventNames = getWorkflowEventNames(root);\n\n if (!eventNames.has(\"pull_request_target\")) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n const stepsSequence = getMappingValueAsSequence(\n job.mapping,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n continue;\n }\n\n for (const entry of stepsSequence.entries) {\n const stepMapping = unwrapYamlValue(entry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const usesPair = getMappingPair(stepMapping, \"uses\");\n const usesReference = getScalarStringValue(\n usesPair?.value ?? null\n );\n\n if (\n usesPair === null ||\n usesReference === null ||\n !isCheckoutActionReference(usesReference)\n ) {\n continue;\n }\n\n const withMapping = getMappingValueAsMapping(\n stepMapping,\n \"with\"\n );\n\n if (withMapping === null) {\n continue;\n }\n\n for (const key of [\"ref\", \"repository\"] as const) {\n const optionPair = getMappingPair(withMapping, key);\n const optionValue = getScalarStringValue(\n optionPair?.value ?? null\n );\n\n if (\n optionPair === null ||\n optionValue === null ||\n !hasPullRequestHeadReference(optionValue)\n ) {\n continue;\n }\n\n context.report({\n data: {\n jobId: job.id,\n key,\n },\n messageId: \"pullRequestHeadCheckout\",\n node: (optionPair.value ??\n optionPair) as unknown as Rule.Node,\n });\n }\n }\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.security\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow `actions/checkout` configurations in `pull_request_target` workflows that fetch pull request head refs, SHAs, or repositories into a privileged run.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R030\",\n ruleNumber: 30,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-pr-head-checkout-in-pull-request-target\",\n },\n messages: {\n pullRequestHeadCheckout:\n \"Job '{{jobId}}' uses `actions/checkout` with `with.{{key}}` pointing at pull request head content inside a `pull_request_target` workflow. Avoid checking out untrusted PR head code in this privileged trigger.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow `runs.pre-if` when `runs.pre` is not declared.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isActionMetadataFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\nimport { getEnclosingLineRemovalRange } from \"../_internal/yaml-fixes.js\";\n\n/** Rule implementation for invalid `runs.pre-if` usage. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isActionMetadataFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n const runsMapping =\n root === null\n ? null\n : getMappingValueAsMapping(root, \"runs\");\n\n if (runsMapping === null) {\n return;\n }\n\n const preIfPair = getMappingPair(runsMapping, \"pre-if\");\n\n if (preIfPair === null || getMappingPair(runsMapping, \"pre\")) {\n return;\n }\n\n context.report({\n fix: (fixer) =>\n fixer.removeRange(\n getEnclosingLineRemovalRange(\n context.sourceCode.text,\n preIfPair.range\n )\n ),\n messageId: \"preIfWithoutPre\",\n node: (preIfPair.value ??\n preIfPair) as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.actionMetadata\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow `runs.pre-if` when `runs.pre` is not configured in action metadata.\",\n dialects: [\"GitHub Action metadata\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R045\",\n ruleNumber: 45,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-pre-if-without-pre\",\n },\n fixable: \"code\",\n messages: {\n preIfWithoutPre:\n \"`runs.pre-if` is set, but `runs.pre` is missing. Remove `pre-if` or add `pre`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow action inputs that are both required and defaulted.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isActionMetadataFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\nimport { getEnclosingLineRemovalRange } from \"../_internal/yaml-fixes.js\";\n\n/** Rule implementation for contradictory action input definitions. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isActionMetadataFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n const inputsMapping =\n root === null\n ? null\n : getMappingValueAsMapping(root, \"inputs\");\n\n if (inputsMapping === null) {\n return;\n }\n\n for (const pair of inputsMapping.pairs) {\n const inputId = getScalarStringValue(pair.key);\n const inputMapping = unwrapYamlValue(pair.value);\n\n if (\n inputId === null ||\n inputMapping?.type !== \"YAMLMapping\"\n ) {\n continue;\n }\n\n const requiredPair = getMappingPair(\n inputMapping,\n \"required\"\n );\n const defaultPair = getMappingPair(inputMapping, \"default\");\n\n if (requiredPair === null || defaultPair === null) {\n continue;\n }\n\n const requiredValue = unwrapYamlValue(requiredPair.value);\n\n if (\n requiredValue?.type !== \"YAMLScalar\" ||\n requiredValue.value !== true\n ) {\n continue;\n }\n\n context.report({\n data: {\n inputId,\n },\n messageId: \"requiredInputWithDefault\",\n node: (defaultPair.value ??\n defaultPair) as unknown as Rule.Node,\n suggest: [\n {\n data: {\n inputId,\n },\n fix: (fixer) =>\n fixer.removeRange(\n getEnclosingLineRemovalRange(\n context.sourceCode.text,\n requiredPair.range\n )\n ),\n messageId: \"removeRequiredSuggestion\",\n },\n {\n data: {\n inputId,\n },\n fix: (fixer) =>\n fixer.removeRange(\n getEnclosingLineRemovalRange(\n context.sourceCode.text,\n defaultPair.range\n )\n ),\n messageId: \"removeDefaultSuggestion\",\n },\n ],\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.actionMetadata\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow action inputs that set both `required: true` and `default`.\",\n dialects: [\"GitHub Action metadata\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R047\",\n ruleNumber: 47,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-required-input-with-default\",\n },\n hasSuggestions: true,\n messages: {\n removeDefaultSuggestion:\n \"Remove the default value from input '{{inputId}}' and keep it required.\",\n removeRequiredSuggestion:\n \"Remove `required: true` from input '{{inputId}}' and keep the default value.\",\n requiredInputWithDefault:\n \"Input '{{inputId}}' sets both `required: true` and `default`, which is contradictory for action callers.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow direct secret references in `if` conditionals.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Direct secret-access patterns that GitHub discourages in `if` conditionals. */\nconst directSecretsPatterns = [\n /\\bsecrets\\.\\w+\\b/u,\n /\\bsecrets\\[[\"'][^\"'\\]]+[\"']\\]/u,\n] as const;\n\n/**\n * Determine whether an `if` expression directly references the `secrets`\n * context.\n */\nconst hasDirectSecretsReference = (expression: string): boolean =>\n directSecretsPatterns.some((pattern) => pattern.test(expression));\n\n/** Report a direct-secrets conditional reference. */\nconst reportDirectSecretsConditional = (\n context: Readonly<Rule.RuleContext>,\n ifPair: Readonly<AST.YAMLPair>,\n scope: string\n): void => {\n context.report({\n data: {\n scope,\n },\n messageId: \"directSecretsInIf\",\n node: ifPair.value as unknown as Rule.Node,\n });\n};\n\n/** Rule implementation for disallowing direct secret usage in `if` conditionals. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n const jobIfPair = getMappingPair(job.mapping, \"if\");\n const jobIfExpression = getScalarStringValue(\n jobIfPair?.value ?? null\n );\n\n if (\n jobIfPair !== null &&\n jobIfExpression !== null &&\n hasDirectSecretsReference(jobIfExpression)\n ) {\n reportDirectSecretsConditional(\n context,\n jobIfPair,\n `job '${job.id}'`\n );\n }\n\n const stepsSequence = getMappingValueAsSequence(\n job.mapping,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n continue;\n }\n\n for (const entry of stepsSequence.entries) {\n const stepMapping = unwrapYamlValue(entry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const stepIfPair = getMappingPair(stepMapping, \"if\");\n const stepIfExpression = getScalarStringValue(\n stepIfPair?.value ?? null\n );\n\n if (\n stepIfPair === null ||\n stepIfExpression === null ||\n !hasDirectSecretsReference(stepIfExpression)\n ) {\n continue;\n }\n\n reportDirectSecretsConditional(\n context,\n stepIfPair,\n `a step in job '${job.id}'`\n );\n }\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.security\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow direct `secrets.*` references in job and step `if` conditionals; move secret values into `env` first and condition on that instead.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R027\",\n ruleNumber: 27,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-secrets-in-if\",\n },\n messages: {\n directSecretsInIf:\n \"Do not reference `secrets` directly in {{scope}} `if` conditionals. Assign the secret to `env` first, then check the environment variable.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow self-hosted runners on fork-capable pull request events.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowEventNames,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Pull-request-adjacent events that can be invoked from forked PR activity. */\nconst forkPullRequestEventNames = [\n \"issue_comment\",\n \"pull_request\",\n \"pull_request_review\",\n \"pull_request_review_comment\",\n \"pull_request_target\",\n] as const;\n\n/** Fast lookup set for fork-capable pull request events. */\nconst forkPullRequestEventNameSet: ReadonlySet<string> = new Set(\n forkPullRequestEventNames\n);\n\n/** Determine whether a scalar string denotes the self-hosted runner label. */\nconst isSelfHostedRunnerLabel = (value: string): boolean =>\n value.trim().toLowerCase() === \"self-hosted\";\n\n/** Determine whether a runs-on node selects a self-hosted runner. */\nconst hasSelfHostedRunner = (\n node: null | Readonly<AST.YAMLContent | AST.YAMLWithMeta>\n): boolean => {\n const unwrappedNode = unwrapYamlValue(\n node as AST.YAMLContent | AST.YAMLWithMeta | null\n );\n\n if (unwrappedNode === null) {\n return false;\n }\n\n if (unwrappedNode.type === \"YAMLScalar\") {\n const value = getScalarStringValue(unwrappedNode);\n\n return value !== null && isSelfHostedRunnerLabel(value);\n }\n\n if (unwrappedNode.type === \"YAMLSequence\") {\n return unwrappedNode.entries.some((entry) => {\n const value = getScalarStringValue(entry);\n\n return value !== null && isSelfHostedRunnerLabel(value);\n });\n }\n\n if (unwrappedNode.type !== \"YAMLMapping\") {\n return false;\n }\n\n return hasSelfHostedRunner(\n getMappingPair(unwrappedNode, \"labels\")?.value ?? null\n );\n};\n\n/** Rule implementation for blocking self-hosted runners on fork PR events. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const triggeringForkPullRequestEvents = [\n ...getWorkflowEventNames(root),\n ]\n .filter((eventName) =>\n forkPullRequestEventNameSet.has(eventName)\n )\n .toSorted((left, right) => left.localeCompare(right));\n\n if (triggeringForkPullRequestEvents.length === 0) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n const runsOnPair = getMappingPair(job.mapping, \"runs-on\");\n\n if (\n runsOnPair === null ||\n !hasSelfHostedRunner(runsOnPair.value ?? null)\n ) {\n continue;\n }\n\n context.report({\n data: {\n events: triggeringForkPullRequestEvents.join(\", \"),\n jobId: job.id,\n },\n messageId: \"selfHostedRunnerOnForkPullRequestEvent\",\n node: (runsOnPair.value ??\n runsOnPair) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.security\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow self-hosted runners in workflows triggered by fork-capable pull-request events that can execute untrusted contributor activity.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R036\",\n ruleNumber: 36,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-self-hosted-runner-on-fork-pr-events\",\n },\n messages: {\n selfHostedRunnerOnForkPullRequestEvent:\n \"Job '{{jobId}}' uses a self-hosted runner in a workflow triggered by {{events}}, which can be invoked from forked or Dependabot pull requests. Prefer GitHub-hosted runners, or isolate the workload behind hardened ephemeral self-hosted infrastructure.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow workflow-template file patterns that target subdirectory paths.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowTemplatePropertiesFile } from \"../_internal/lint-targets.js\";\nimport {\n getWorkflowTemplateFilePatternEntries,\n getWorkflowTemplatePropertiesRoot,\n} from \"../_internal/workflow-template-properties.js\";\n\n/** Rule implementation for root-directory-oriented template file pattern checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowTemplatePropertiesRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const {\n node,\n value,\n } of getWorkflowTemplateFilePatternEntries(root)) {\n if (!value.includes(\"/\") && !value.includes(\"\\\\\")) {\n continue;\n }\n\n context.report({\n data: {\n pattern: value,\n },\n messageId: \"subdirectoryTemplateFilePattern\",\n node: node as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow workflow-template `filePatterns` that match subdirectory paths instead of repository-root files.\",\n dialects: [\"GitHub Actions workflow template metadata\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R062\",\n ruleNumber: 62,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-subdirectory-template-file-pattern\",\n },\n messages: {\n subdirectoryTemplateFilePattern:\n \"Template file pattern '{{pattern}}' targets subdirectory paths; workflow-template file patterns should match repository-root files.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow `$default-branch` placeholder usage outside workflow template files.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n isWorkflowTemplatePropertiesFile,\n isWorkflowTemplateYamlFile,\n} from \"../_internal/lint-targets.js\";\nimport { getWorkflowRoot } from \"../_internal/workflow-yaml.js\";\nimport { visitYamlStringScalars } from \"../_internal/yaml-traversal.js\";\n\n/** Placeholder token supported in template files. */\nconst defaultBranchPlaceholder = \"$default-branch\";\n\n/** Rule implementation for invalid placeholder usage outside templates. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (isWorkflowTemplateYamlFile(context.filename)) {\n return;\n }\n\n if (isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n visitYamlStringScalars(root, (node, value) => {\n if (!value.includes(defaultBranchPlaceholder)) {\n return;\n }\n\n context.report({\n messageId: \"templatePlaceholderOutsideTemplate\",\n node: node as unknown as Rule.Node,\n });\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow `$default-branch` placeholder usage outside workflow template YAML files.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R069\",\n ruleNumber: 69,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-template-placeholder-in-non-template-workflow\",\n },\n messages: {\n templatePlaceholderOutsideTemplate:\n \"`$default-branch` is intended for workflow template files and should not be used in regular workflow YAML files.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow workflow-wide environment variables under the top-level `env` key.\n */\nimport type { Rule } from \"eslint\";\n\nimport { getMappingPair, getWorkflowRoot } from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for disallowing top-level workflow env. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const envPair = getMappingPair(root, \"env\");\n\n if (envPair !== null) {\n context.report({\n messageId: \"topLevelEnv\",\n node: envPair.key as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow top-level workflow `env` when you want environment variables scoped closer to the jobs and steps that use them.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R013\",\n ruleNumber: 13,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-top-level-env\",\n },\n messages: {\n topLevelEnv:\n \"Avoid top-level workflow `env`; prefer job-level or step-level `env` declarations instead.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow declaring workflow permissions at the top level.\n */\nimport type { Rule } from \"eslint\";\n\nimport { getMappingPair, getWorkflowRoot } from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for disallowing top-level workflow permissions. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const permissionsPair = getMappingPair(root, \"permissions\");\n\n if (permissionsPair !== null) {\n context.report({\n messageId: \"topLevelPermissions\",\n node: permissionsPair.key as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\"github-actions.configs.all\"],\n description:\n \"disallow top-level workflow `permissions` when you want every job to declare its own token scope explicitly.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R014\",\n ruleNumber: 14,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-top-level-permissions\",\n },\n messages: {\n topLevelPermissions:\n \"Avoid top-level workflow `permissions`; declare `permissions` on each job instead.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow universal catch-all regexes in template `filePatterns`.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowTemplatePropertiesFile } from \"../_internal/lint-targets.js\";\nimport {\n getWorkflowTemplateFilePatternEntries,\n getWorkflowTemplatePropertiesRoot,\n} from \"../_internal/workflow-template-properties.js\";\n\n/** Normalized regex strings treated as universal catch-all template patterns. */\nconst universalTemplateFilePatterns = new Set([\n \".*\",\n \".+\",\n \"^.*$\",\n \"^.+$\",\n]);\n\n/** Rule implementation for universal template file pattern checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowTemplatePropertiesRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const {\n node,\n value,\n } of getWorkflowTemplateFilePatternEntries(root)) {\n const normalizedPattern = value.trim();\n\n if (!universalTemplateFilePatterns.has(normalizedPattern)) {\n continue;\n }\n\n context.report({\n data: {\n pattern: value,\n },\n messageId: \"universalTemplateFilePattern\",\n node: node as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow universal catch-all regexes in workflow-template `filePatterns`.\",\n dialects: [\"GitHub Actions workflow template metadata\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R061\",\n ruleNumber: 61,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-universal-template-file-pattern\",\n },\n messages: {\n universalTemplateFilePattern:\n \"Template file pattern '{{pattern}}' is too broad and matches nearly every repository.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow references to undefined Dependabot multi-ecosystem groups.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getDependabotReferencedGroup,\n getDependabotRoot,\n getDependabotUpdateEntries,\n getDependabotUpdateLabel,\n} from \"../_internal/dependabot-yaml.js\";\nimport { getMappingPair } from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for unknown multi-ecosystem-group references. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getDependabotRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const update of getDependabotUpdateEntries(root)) {\n if (update.multiEcosystemGroup === null) {\n continue;\n }\n\n if (getDependabotReferencedGroup(root, update) !== null) {\n continue;\n }\n\n const groupPair = getMappingPair(\n update.mapping,\n \"multi-ecosystem-group\"\n );\n\n context.report({\n data: {\n groupName: update.multiEcosystemGroup,\n updateLabel: getDependabotUpdateLabel(update),\n },\n messageId: \"unknownMultiEcosystemGroup\",\n node: (groupPair?.value ??\n groupPair ??\n update.node) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.dependabot\",\n ],\n description:\n \"disallow Dependabot `multi-ecosystem-group` references that do not match a declared top-level group.\",\n dialects: [\"Dependabot configuration\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R081\",\n ruleNumber: 81,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-unknown-dependabot-multi-ecosystem-group\",\n },\n messages: {\n unknownMultiEcosystemGroup:\n \"{{updateLabel}} references unknown `multi-ecosystem-group` '{{groupName}}'. Declare it under top-level `multi-ecosystem-groups` or remove the reference.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow references to undeclared inputs in composite action metadata.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isActionMetadataFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\nimport { visitYamlStringScalars } from \"../_internal/yaml-traversal.js\";\n\n/**\n * Pattern for extracting `inputs.<input_id>` references from expression-like\n * strings.\n */\nconst inputReferencePattern = /inputs\\.(?<inputId>[^\\s.\\]}]+)/g;\n\n/** Rule implementation for unknown composite input references. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isActionMetadataFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const runsMapping = getMappingValueAsMapping(root, \"runs\");\n\n if (runsMapping === null) {\n return;\n }\n\n const usingRuntime = getScalarStringValue(\n runsMapping.pairs.find(\n (pair) =>\n pair !== null &&\n getScalarStringValue(pair.key) === \"using\"\n )?.value\n );\n\n if (usingRuntime !== \"composite\") {\n return;\n }\n\n const inputsMapping = getMappingValueAsMapping(root, \"inputs\");\n const declaredInputIds = new Set<string>();\n\n if (inputsMapping !== null) {\n for (const pair of inputsMapping.pairs) {\n const inputId = getScalarStringValue(pair.key);\n\n if (inputId !== null) {\n declaredInputIds.add(inputId);\n }\n }\n }\n\n visitYamlStringScalars(runsMapping, (node, value) => {\n for (const match of value.matchAll(inputReferencePattern)) {\n const inputId = match.groups?.[\"inputId\"];\n\n if (\n inputId === undefined ||\n declaredInputIds.has(inputId)\n ) {\n continue;\n }\n\n context.report({\n data: {\n inputId,\n },\n messageId: \"unknownInputReference\",\n node: node as unknown as Rule.Node,\n });\n }\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.actionMetadata\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow `inputs.<id>` references in composite action metadata when the input id is not declared.\",\n dialects: [\"GitHub Action metadata\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R050\",\n ruleNumber: 50,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-unknown-input-reference-in-composite\",\n },\n messages: {\n unknownInputReference:\n \"Composite action references `inputs.{{inputId}}`, but that input is not declared in `inputs`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow references to undeclared job outputs.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/**\n * `needs.<job_id>.outputs.<output_name>` references inside workflow\n * expressions.\n */\nconst needsOutputReferencePattern =\n /needs\\.(?<neededJobId>[A-Z_a-z][\\w-]*)\\.outputs\\.(?<outputName>[A-Z_a-z][\\w-]*)/g;\n\n/**\n * `jobs.<job_id>.outputs.<output_name>` references inside reusable workflow\n * outputs.\n */\nconst jobsOutputReferencePattern =\n /jobs\\.(?<jobId>[A-Z_a-z][\\w-]*)\\.outputs\\.(?<outputName>[A-Z_a-z][\\w-]*)/g;\n\n/** Visit every string scalar reachable from a YAML value node. */\nconst visitStringScalars = (\n node: null | Readonly<AST.YAMLContent | AST.YAMLWithMeta>,\n visitor: (node: Readonly<AST.YAMLScalar>, value: string) => void\n): void => {\n const unwrappedNode = unwrapYamlValue(\n node as AST.YAMLContent | AST.YAMLWithMeta | null\n );\n\n if (unwrappedNode === null) {\n return;\n }\n\n if (unwrappedNode.type === \"YAMLScalar\") {\n const value = getScalarStringValue(unwrappedNode);\n\n if (value !== null) {\n visitor(unwrappedNode, value);\n }\n\n return;\n }\n\n if (unwrappedNode.type === \"YAMLSequence\") {\n for (const entry of unwrappedNode.entries) {\n visitStringScalars(entry, visitor);\n }\n\n return;\n }\n\n if (unwrappedNode.type !== \"YAMLMapping\") {\n return;\n }\n\n for (const pair of unwrappedNode.pairs) {\n visitStringScalars(pair.value ?? null, visitor);\n }\n};\n\n/** Collect declared output names from a job definition. */\nconst getDeclaredJobOutputNames = (\n jobMapping: Readonly<AST.YAMLMapping>\n): ReadonlySet<string> => {\n const outputsMapping = getMappingValueAsMapping(jobMapping, \"outputs\");\n const outputNames = new Set<string>();\n\n if (outputsMapping === null) {\n return outputNames;\n }\n\n for (const pair of outputsMapping.pairs) {\n const outputName = getScalarStringValue(pair.key);\n\n if (outputName !== null) {\n outputNames.add(outputName);\n }\n }\n\n return outputNames;\n};\n\n/** Collect the direct `needs` dependencies configured for a job. */\nconst getDirectNeedsJobIds = (\n jobMapping: Readonly<AST.YAMLMapping>\n): ReadonlySet<string> => {\n const needsPair = getMappingPair(jobMapping, \"needs\");\n const needsValue = unwrapYamlValue(needsPair?.value ?? null);\n const directNeeds = new Set<string>();\n\n if (needsValue === null) {\n return directNeeds;\n }\n\n if (needsValue.type === \"YAMLScalar\") {\n const jobId = getScalarStringValue(needsValue);\n\n if (jobId !== null) {\n directNeeds.add(jobId);\n }\n\n return directNeeds;\n }\n\n if (needsValue.type !== \"YAMLSequence\") {\n return directNeeds;\n }\n\n for (const entry of needsValue.entries) {\n const jobId = getScalarStringValue(entry);\n\n if (jobId !== null) {\n directNeeds.add(jobId);\n }\n }\n\n return directNeeds;\n};\n\n/** Rule implementation for validating job output references. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const jobs = getWorkflowJobs(root);\n const declaredOutputsByJobId = new Map(\n jobs.map((job) => [\n job.id,\n getDeclaredJobOutputNames(job.mapping),\n ])\n );\n\n const onMapping = getMappingValueAsMapping(root, \"on\");\n const workflowCallMapping =\n onMapping === null\n ? null\n : getMappingValueAsMapping(onMapping, \"workflow_call\");\n const workflowCallOutputsMapping =\n workflowCallMapping === null\n ? null\n : getMappingValueAsMapping(\n workflowCallMapping,\n \"outputs\"\n );\n\n if (workflowCallOutputsMapping !== null) {\n for (const pair of workflowCallOutputsMapping.pairs) {\n const reusableOutputName = getScalarStringValue(\n pair.key\n );\n const reusableOutputMapping = unwrapYamlValue(\n pair.value\n );\n\n if (\n reusableOutputName === null ||\n reusableOutputMapping?.type !== \"YAMLMapping\"\n ) {\n continue;\n }\n\n const valuePair = getMappingPair(\n reusableOutputMapping,\n \"value\"\n );\n\n visitStringScalars(\n valuePair?.value ?? null,\n (node, value) => {\n for (const match of value.matchAll(\n jobsOutputReferencePattern\n )) {\n const reference = match[0];\n const jobId = match.groups?.[\"jobId\"];\n const outputName =\n match.groups?.[\"outputName\"];\n\n if (\n jobId === undefined ||\n outputName === undefined\n ) {\n continue;\n }\n\n const declaredOutputNames =\n declaredOutputsByJobId.get(jobId);\n\n if (declaredOutputNames === undefined) {\n context.report({\n data: {\n jobId,\n reference,\n reusableOutputName,\n },\n messageId:\n \"unknownReusableWorkflowJob\",\n node: node as unknown as Rule.Node,\n });\n\n continue;\n }\n\n if (declaredOutputNames.has(outputName)) {\n continue;\n }\n\n context.report({\n data: {\n jobId,\n outputName,\n reference,\n reusableOutputName,\n },\n messageId:\n \"unknownReusableWorkflowJobOutput\",\n node: node as unknown as Rule.Node,\n });\n }\n }\n );\n }\n }\n\n for (const job of jobs) {\n const directNeedsJobIds = getDirectNeedsJobIds(job.mapping);\n\n visitStringScalars(job.mapping, (node, value) => {\n for (const match of value.matchAll(\n needsOutputReferencePattern\n )) {\n const reference = match[0];\n const neededJobId = match.groups?.[\"neededJobId\"];\n const outputName = match.groups?.[\"outputName\"];\n\n if (\n neededJobId === undefined ||\n outputName === undefined\n ) {\n continue;\n }\n\n const declaredOutputNames =\n declaredOutputsByJobId.get(neededJobId);\n\n if (declaredOutputNames === undefined) {\n context.report({\n data: {\n currentJobId: job.id,\n neededJobId,\n reference,\n },\n messageId: \"unknownNeedsJob\",\n node: node as unknown as Rule.Node,\n });\n\n continue;\n }\n\n if (!directNeedsJobIds.has(neededJobId)) {\n context.report({\n data: {\n currentJobId: job.id,\n neededJobId,\n reference,\n },\n messageId: \"missingNeedsDependency\",\n node: node as unknown as Rule.Node,\n });\n\n continue;\n }\n\n if (declaredOutputNames.has(outputName)) {\n continue;\n }\n\n context.report({\n data: {\n currentJobId: job.id,\n neededJobId,\n outputName,\n reference,\n },\n messageId: \"unknownNeedsOutput\",\n node: node as unknown as Rule.Node,\n });\n }\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow `needs.*.outputs.*` and reusable-workflow `jobs.*.outputs.*` references that point at undeclared jobs or outputs.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R037\",\n ruleNumber: 37,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-unknown-job-output-reference\",\n },\n messages: {\n missingNeedsDependency:\n \"Job '{{currentJobId}}' references `{{reference}}`, but job '{{neededJobId}}' is not listed in that job's direct `needs` dependencies.\",\n unknownNeedsJob:\n \"Job '{{currentJobId}}' references `{{reference}}`, but job '{{neededJobId}}' is not declared in this workflow.\",\n unknownNeedsOutput:\n \"Job '{{currentJobId}}' references `{{reference}}`, but job '{{neededJobId}}' does not declare output '{{outputName}}' under `jobs.{{neededJobId}}.outputs`.\",\n unknownReusableWorkflowJob:\n \"Reusable workflow output '{{reusableOutputName}}' references `{{reference}}`, but job '{{jobId}}' is not declared in this workflow.\",\n unknownReusableWorkflowJobOutput:\n \"Reusable workflow output '{{reusableOutputName}}' references `{{reference}}`, but job '{{jobId}}' does not declare output '{{outputName}}' under `jobs.{{jobId}}.outputs`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow references to undefined or not-yet-available steps.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Step context references using property dereference syntax. */\nconst stepReferencePattern =\n /steps\\.(?<stepId>[A-Z_a-z][\\w-]*)\\.(?:outputs\\.[A-Z_a-z][\\w-]*|conclusion|outcome)/g;\n\n/**\n * Visit every string scalar in a job, tracking the current step index when\n * applicable.\n */\nconst visitJobStringScalars = (\n node: null | Readonly<AST.YAMLContent | AST.YAMLWithMeta>,\n visitor: (\n node: Readonly<AST.YAMLScalar>,\n value: string,\n currentStepIndex: null | number\n ) => void,\n currentStepIndex: null | number = null\n): void => {\n const unwrappedNode = unwrapYamlValue(\n node as AST.YAMLContent | AST.YAMLWithMeta | null\n );\n\n if (unwrappedNode === null) {\n return;\n }\n\n if (unwrappedNode.type === \"YAMLScalar\") {\n const value = getScalarStringValue(unwrappedNode);\n\n if (value !== null) {\n visitor(unwrappedNode, value, currentStepIndex);\n }\n\n return;\n }\n\n if (unwrappedNode.type === \"YAMLSequence\") {\n for (const entry of unwrappedNode.entries) {\n visitJobStringScalars(entry, visitor, currentStepIndex);\n }\n\n return;\n }\n\n if (unwrappedNode.type !== \"YAMLMapping\") {\n return;\n }\n\n const stepsSequence = getMappingValueAsSequence(unwrappedNode, \"steps\");\n\n if (stepsSequence !== null) {\n for (const [stepIndex, entry] of stepsSequence.entries.entries()) {\n visitJobStringScalars(entry, visitor, stepIndex);\n }\n }\n\n for (const pair of unwrappedNode.pairs) {\n if (getScalarStringValue(pair.key) === \"steps\") {\n continue;\n }\n\n visitJobStringScalars(pair.value ?? null, visitor, currentStepIndex);\n }\n};\n\n/** Collect the first declared index for each step id in a job. */\nconst getStepIndexById = (\n jobMapping: Readonly<AST.YAMLMapping>\n): ReadonlyMap<string, number> => {\n const stepsSequence = getMappingValueAsSequence(jobMapping, \"steps\");\n const stepIndexById = new Map<string, number>();\n\n if (stepsSequence === null) {\n return stepIndexById;\n }\n\n for (const [stepIndex, entry] of stepsSequence.entries.entries()) {\n const stepMapping = unwrapYamlValue(entry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const stepId = getScalarStringValue(\n getMappingPair(stepMapping, \"id\")?.value ?? null\n );\n\n if (stepId !== null && !stepIndexById.has(stepId)) {\n stepIndexById.set(stepId, stepIndex);\n }\n }\n\n return stepIndexById;\n};\n\n/** Rule implementation for validating step context references. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n const stepIndexById = getStepIndexById(job.mapping);\n\n visitJobStringScalars(\n job.mapping,\n (node, value, currentStepIndex) => {\n for (const match of value.matchAll(\n stepReferencePattern\n )) {\n const reference = match[0];\n const stepId = match.groups?.[\"stepId\"];\n\n if (stepId === undefined) {\n continue;\n }\n\n const referencedStepIndex =\n stepIndexById.get(stepId);\n\n if (referencedStepIndex === undefined) {\n context.report({\n data: {\n jobId: job.id,\n reference,\n stepId,\n },\n messageId: \"unknownStepReference\",\n node: node as unknown as Rule.Node,\n });\n\n continue;\n }\n\n if (\n currentStepIndex === null ||\n referencedStepIndex < currentStepIndex\n ) {\n continue;\n }\n\n context.report({\n data: {\n jobId: job.id,\n reference,\n stepId,\n },\n messageId:\n \"stepReferenceBeforeAvailability\",\n node: node as unknown as Rule.Node,\n });\n }\n }\n );\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow `steps.<id>.*` references that target a missing step id or a step that has not run yet.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R038\",\n ruleNumber: 38,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-unknown-step-reference\",\n },\n messages: {\n stepReferenceBeforeAvailability:\n \"Job '{{jobId}}' references `{{reference}}` before step '{{stepId}}' has run. The `steps` context only contains prior steps in the same job.\",\n unknownStepReference:\n \"Job '{{jobId}}' references `{{reference}}`, but no step with `id: {{stepId}}` exists in that job.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow directly interpolating untrusted event inputs inside `run` steps.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/**\n * Untrusted workflow-expression sources that should not be embedded directly in\n * `run`.\n */\nconst untrustedRunExpressionSources = [\n {\n fragments: [\n \"github.event.pull_request.body\",\n \"github.event.pull_request.title\",\n ],\n source: \"pull request title/body\",\n },\n {\n fragments: [\"github.event.issue.body\", \"github.event.issue.title\"],\n source: \"issue title/body\",\n },\n {\n fragments: [\"github.event.comment.body\"],\n source: \"comment body\",\n },\n {\n fragments: [\"github.event.review.body\"],\n source: \"review body\",\n },\n {\n fragments: [\n \"github.event.discussion.body\",\n \"github.event.discussion.title\",\n ],\n source: \"discussion title/body\",\n },\n {\n fragments: [\"github.event.discussion_comment.body\"],\n source: \"discussion comment body\",\n },\n {\n fragments: [\"github.event.client_payload.\"],\n source: \"repository_dispatch client payload\",\n },\n] as const;\n\n/** Resolve the first matching untrusted expression source inside a run script. */\nconst getUnsafeRunSource = (runScript: string): null | string => {\n for (const source of untrustedRunExpressionSources) {\n if (source.fragments.some((fragment) => runScript.includes(fragment))) {\n return source.source;\n }\n }\n\n return null;\n};\n\n/** Rule implementation for disallowing unsafe direct interpolation in `run`. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n const stepsSequence = getMappingValueAsSequence(\n job.mapping,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n continue;\n }\n\n for (const entry of stepsSequence.entries) {\n const stepMapping = unwrapYamlValue(entry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const runPair = getMappingPair(stepMapping, \"run\");\n const runScript = getScalarStringValue(\n runPair?.value ?? null\n );\n\n if (runPair === null || runScript === null) {\n continue;\n }\n\n const unsafeSource = getUnsafeRunSource(runScript);\n\n if (unsafeSource === null) {\n continue;\n }\n\n context.report({\n data: {\n jobId: job.id,\n source: unsafeSource,\n },\n messageId: \"unsafeRunInterpolation\",\n node: (runPair.value ??\n runPair) as unknown as Rule.Node,\n });\n }\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.security\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow directly embedding untrusted event payload values inside `run` scripts; move them through `env` first or pass them to an action input.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R029\",\n ruleNumber: 29,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-untrusted-input-in-run\",\n },\n messages: {\n unsafeRunInterpolation:\n \"Job '{{jobId}}' interpolates untrusted {{source}} directly inside `run`. Assign the value to `env` first or pass it to an action input.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow the unused top-level `enable-beta-ecosystems` Dependabot setting.\n */\nimport type { Rule } from \"eslint\";\n\nimport { getDependabotRoot } from \"../_internal/dependabot-yaml.js\";\nimport { getMappingPair } from \"../_internal/workflow-yaml.js\";\nimport { getEnclosingLineRemovalRange } from \"../_internal/yaml-fixes.js\";\n\n/** Rule implementation for the unused `enable-beta-ecosystems` key. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getDependabotRoot(context);\n\n if (root === null) {\n return;\n }\n\n const enableBetaEcosystemsPair = getMappingPair(\n root,\n \"enable-beta-ecosystems\"\n );\n\n if (enableBetaEcosystemsPair === null) {\n return;\n }\n\n context.report({\n fix: (fixer) =>\n fixer.removeRange(\n getEnclosingLineRemovalRange(\n context.sourceCode.text,\n enableBetaEcosystemsPair.range\n )\n ),\n messageId: \"unusedEnableBetaEcosystems\",\n node: (enableBetaEcosystemsPair.value ??\n enableBetaEcosystemsPair) as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.dependabot\",\n ],\n description:\n \"disallow the top-level Dependabot `enable-beta-ecosystems` setting because GitHub currently documents it as unused.\",\n dialects: [\"Dependabot configuration\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R085\",\n ruleNumber: 85,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-unused-dependabot-enable-beta-ecosystems\",\n },\n fixable: \"code\",\n messages: {\n unusedEnableBetaEcosystems:\n \"Remove `enable-beta-ecosystems`. GitHub currently documents this Dependabot setting as not in use.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow declared inputs that are never used in a composite action.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isActionMetadataFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\nimport { collectYamlStringScalars } from \"../_internal/yaml-traversal.js\";\n\n/** Matches `inputs.<id>` references in composite-step string values. */\nconst INPUT_REFERENCE_PATTERN = /inputs\\.(?<inputId>[\\w-]+)/gu;\n\n/** Rule implementation for unused composite input checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isActionMetadataFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const runsMapping = getMappingValueAsMapping(root, \"runs\");\n const inputsMapping = getMappingValueAsMapping(root, \"inputs\");\n\n if (runsMapping === null || inputsMapping === null) {\n return;\n }\n\n const usingRuntime = getScalarStringValue(\n getMappingPair(runsMapping, \"using\")?.value\n );\n\n if (usingRuntime !== \"composite\") {\n return;\n }\n\n const allScalarValues = collectYamlStringScalars(runsMapping);\n const referencedInputIds = new Set<string>();\n\n for (const scalarValue of allScalarValues) {\n for (const match of scalarValue.matchAll(\n INPUT_REFERENCE_PATTERN\n )) {\n const matchedInputId = match.groups?.[\"inputId\"];\n\n if (matchedInputId === undefined) {\n continue;\n }\n\n referencedInputIds.add(matchedInputId);\n }\n }\n\n for (const inputPair of inputsMapping.pairs) {\n const inputId = getScalarStringValue(inputPair.key);\n\n if (inputId === null) {\n continue;\n }\n\n if (referencedInputIds.has(inputId)) {\n continue;\n }\n\n context.report({\n data: {\n inputId,\n },\n messageId: \"unusedCompositeInput\",\n node: inputPair.key as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.actionMetadata\",\n \"github-actions.configs.all\",\n ],\n description:\n \"disallow declared composite-action inputs that are never referenced.\",\n dialects: [\"GitHub Action metadata\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R053\",\n ruleNumber: 53,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-unused-input-in-composite\",\n },\n messages: {\n unusedCompositeInput:\n \"Composite action input '{{inputId}}' is declared but never referenced via `inputs.{{inputId}}`.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Disallow broad `write-all` GitHub token permissions.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Determine whether a permissions node is the broad `write-all` shortcut. */\nconst isWriteAllPermissionsValue = (\n permissionsPair: Readonly<AST.YAMLPair>\n): boolean =>\n getScalarStringValue(permissionsPair.value)?.trim().toLowerCase() ===\n \"write-all\";\n\n/** Rule implementation for disallowing `permissions: write-all`. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const reportWriteAll = (\n permissionsPair: Readonly<AST.YAMLPair>,\n scope: string\n ): void => {\n context.report({\n data: {\n scope,\n },\n messageId: \"writeAllPermissions\",\n node: permissionsPair.value as unknown as Rule.Node,\n });\n };\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const workflowPermissionsPair = getMappingPair(\n root,\n \"permissions\"\n );\n\n if (\n workflowPermissionsPair !== null &&\n isWriteAllPermissionsValue(workflowPermissionsPair)\n ) {\n reportWriteAll(\n workflowPermissionsPair,\n \"top-level workflow `permissions`\"\n );\n }\n\n for (const job of getWorkflowJobs(root)) {\n const jobPermissionsPair = getMappingPair(\n job.mapping,\n \"permissions\"\n );\n\n if (\n jobPermissionsPair !== null &&\n isWriteAllPermissionsValue(jobPermissionsPair)\n ) {\n reportWriteAll(\n jobPermissionsPair,\n `job '${job.id}' permissions`\n );\n }\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.security\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow `permissions: write-all` so workflows and jobs keep GitHub token scopes least-privileged.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R023\",\n ruleNumber: 23,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/no-write-all-permissions\",\n },\n messages: {\n writeAllPermissions:\n \"Avoid `write-all` in {{scope}}. Declare only the specific write scopes the workflow or job actually needs.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require immutable full-length SHA pins for third-party actions and reusable workflows.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Full commit SHA pattern recommended by GitHub for pinning action refs. */\nconst FULL_SHA_PATTERN = /^[0-9a-f]{40}$/u;\n\n/** Determine whether a `uses` reference is a local action path. */\nconst isLocalActionReference = (reference: string): boolean =>\n reference.startsWith(\"./\");\n\n/** Determine whether a `uses` reference is a Docker image reference. */\nconst isDockerReference = (reference: string): boolean =>\n reference.startsWith(\"docker://\");\n\n/** Determine whether a `uses` reference targets a reusable workflow. */\nconst isReusableWorkflowReference = (reference: string): boolean =>\n reference.includes(\"/.github/workflows/\");\n\n/** Extract the ref segment after the final `@` delimiter. */\nconst getReferenceRef = (reference: string): null | string => {\n const delimiterIndex = reference.lastIndexOf(\"@\");\n\n return delimiterIndex === -1 ? null : reference.slice(delimiterIndex + 1);\n};\n\n/** Determine whether a GitHub `uses` reference must be SHA pinned. */\nconst shouldValidateUsesReference = (reference: string): boolean =>\n !isLocalActionReference(reference) && !isDockerReference(reference);\n\n/**\n * Rule implementation for requiring immutable SHA pins on external uses\n * references.\n */\nconst rule: Rule.RuleModule = {\n create(context) {\n const reportReference = (\n node: Readonly<NonNullable<Rule.Node>>,\n reference: string\n ): void => {\n if (!shouldValidateUsesReference(reference)) {\n return;\n }\n\n const ref = getReferenceRef(reference);\n\n if (ref !== null && FULL_SHA_PATTERN.test(ref)) {\n return;\n }\n\n context.report({\n data: {\n ref: ref ?? \"<missing ref>\",\n reference,\n },\n messageId: isReusableWorkflowReference(reference)\n ? \"unpinnedReusableWorkflow\"\n : \"unpinnedAction\",\n node: node as Rule.Node,\n });\n };\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n const reusableWorkflowPair = getMappingPair(\n job.mapping,\n \"uses\"\n );\n const reusableWorkflowReference = getScalarStringValue(\n reusableWorkflowPair?.value ?? null\n );\n\n if (\n reusableWorkflowPair !== null &&\n reusableWorkflowReference !== null\n ) {\n reportReference(\n (reusableWorkflowPair.value ??\n reusableWorkflowPair) as unknown as Rule.Node,\n reusableWorkflowReference\n );\n }\n\n const stepsSequence = getMappingValueAsSequence(\n job.mapping,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n continue;\n }\n\n for (const entry of stepsSequence.entries) {\n const stepMapping = unwrapYamlValue(entry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const usesPair = getMappingPair(stepMapping, \"uses\");\n const usesReference = getScalarStringValue(\n usesPair?.value ?? null\n );\n\n if (usesPair === null || usesReference === null) {\n continue;\n }\n\n reportReference(\n (usesPair.value ??\n usesPair) as unknown as Rule.Node,\n usesReference\n );\n }\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.security\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require third-party `uses` references to pin full-length commit SHAs instead of mutable tags or branches.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R003\",\n ruleNumber: 3,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/pin-action-shas\",\n },\n messages: {\n unpinnedAction:\n \"Action reference '{{reference}}' should pin a full 40-character commit SHA instead of '{{ref}}'.\",\n unpinnedReusableWorkflow:\n \"Reusable workflow reference '{{reference}}' should pin a full 40-character commit SHA instead of '{{ref}}'.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Prefer `action.yml` over `action.yaml` for action metadata.\n */\nimport type { Rule } from \"eslint\";\n\n/** Rule implementation for preferring `action.yml`. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!context.filename.toLowerCase().endsWith(\"action.yaml\")) {\n return;\n }\n\n context.report({\n messageId: \"preferActionYml\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.actionMetadata\",\n \"github-actions.configs.all\",\n ],\n description:\n \"require action metadata files to prefer `action.yml` over `action.yaml`.\",\n dialects: [\"GitHub Action metadata\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R043\",\n ruleNumber: 43,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/prefer-action-yml\",\n },\n messages: {\n preferActionYml:\n \"Prefer naming action metadata files `action.yml` instead of `action.yaml`.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Prefer matrix fail-fast behavior over explicitly disabling it.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n isGithubExpressionScalar,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for discouraging `strategy.fail-fast: false`. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n const strategyPair = getMappingPair(\n job.mapping,\n \"strategy\"\n );\n const strategyValue = unwrapYamlValue(\n strategyPair?.value ?? null\n );\n\n if (strategyValue?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const failFastPair = getMappingPair(\n strategyValue,\n \"fail-fast\"\n );\n\n if (\n failFastPair === null ||\n isGithubExpressionScalar(failFastPair.value)\n ) {\n continue;\n }\n\n const failFastValue = unwrapYamlValue(failFastPair.value);\n const failFastText = getScalarStringValue(\n failFastPair.value\n );\n\n if (\n failFastValue?.type === \"YAMLScalar\" &&\n (failFastValue.value === false ||\n failFastText === \"false\")\n ) {\n context.report({\n data: {\n jobId: job.id,\n },\n messageId: \"failFastDisabled\",\n node: (failFastPair.value ??\n failFastPair) as unknown as Rule.Node,\n });\n }\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow `strategy.fail-fast: false` so failing matrix jobs can stop redundant work sooner.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R015\",\n ruleNumber: 15,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/prefer-fail-fast\",\n },\n messages: {\n failFastDisabled:\n \"Job '{{jobId}}' disables `strategy.fail-fast`. Prefer `true` or a GitHub expression instead.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Enforce a consistent file extension for workflow files.\n */\nimport type { Rule } from \"eslint\";\n\nimport { extname } from \"node:path\";\n\n/** Supported workflow filename extensions. */\nconst workflowFileExtensions = [\"yaml\", \"yml\"] as const;\n\n/** Allowed workflow filename extension. */\ntype WorkflowFileExtension = (typeof workflowFileExtensions)[number];\n\n/** Object-style options for `prefer-file-extension`. */\ntype WorkflowFileExtensionOptionObject = {\n readonly caseSensitive?: boolean;\n readonly extension?: WorkflowFileExtension;\n};\n\n/** Rule options for `prefer-file-extension`. */\ntype WorkflowFileExtensionOptions = [\n (WorkflowFileExtension | WorkflowFileExtensionOptionObject)?,\n];\n\n/** Default workflow file extension. */\nconst DEFAULT_WORKFLOW_FILE_EXTENSION: WorkflowFileExtension = \"yml\";\n\n/** Normalize file extension options into a consistent runtime shape. */\nconst normalizePreferFileExtensionOptions = (\n option: Readonly<\n undefined | WorkflowFileExtension | WorkflowFileExtensionOptionObject\n >\n): {\n caseSensitive: boolean;\n extension: WorkflowFileExtension;\n} => {\n if (option === undefined || typeof option === \"string\") {\n return {\n caseSensitive: true,\n extension: option ?? DEFAULT_WORKFLOW_FILE_EXTENSION,\n };\n }\n\n return {\n caseSensitive: option.caseSensitive ?? true,\n extension: option.extension ?? DEFAULT_WORKFLOW_FILE_EXTENSION,\n };\n};\n\n/** Rule implementation for enforcing workflow file extensions. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const [option] = context.options as WorkflowFileExtensionOptions;\n const { caseSensitive, extension } =\n normalizePreferFileExtensionOptions(option ?? undefined);\n\n return {\n Program(node) {\n const actualExtensionWithDot = extname(context.filename);\n\n if (actualExtensionWithDot.length === 0) {\n return;\n }\n\n const actualExtension = actualExtensionWithDot.slice(1);\n\n if (actualExtension === undefined) {\n return;\n }\n\n const normalizedActualExtension = caseSensitive\n ? actualExtension\n : actualExtension.toLowerCase();\n const normalizedExpectedExtension = caseSensitive\n ? extension\n : extension.toLowerCase();\n\n if (normalizedActualExtension === normalizedExpectedExtension) {\n return;\n }\n\n context.report({\n data: {\n actual: `.${actualExtension}`,\n expected: `.${extension}`,\n },\n messageId: \"unexpectedExtension\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n defaultOptions: [DEFAULT_WORKFLOW_FILE_EXTENSION],\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"enforce a consistent file extension for GitHub Actions workflow files.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R020\",\n ruleNumber: 20,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/prefer-file-extension\",\n },\n messages: {\n unexpectedExtension:\n \"Expected workflow files to use the {{expected}} extension, but found {{actual}}.\",\n },\n schema: [\n {\n anyOf: [\n {\n description: \"Expected workflow filename extension.\",\n enum: workflowFileExtensions,\n type: \"string\",\n },\n {\n additionalProperties: false,\n description: \"Workflow filename extension options.\",\n properties: {\n caseSensitive: {\n description:\n \"Whether extension matching should preserve case.\",\n type: \"boolean\",\n },\n extension: {\n description:\n \"Expected workflow filename extension.\",\n enum: workflowFileExtensions,\n type: \"string\",\n },\n },\n type: \"object\",\n },\n ],\n description:\n \"Workflow filename extension preference, either as a simple extension string or an option object.\",\n },\n ],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Prefer the `inputs` context over `github.event.inputs` in manual workflows.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getScalarStringValue,\n getWorkflowEventNames,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Legacy workflow_dispatch inputs context prefix. */\nconst githubEventInputsPrefix = \"github.event.inputs.\";\n\n/** Preferred workflow_dispatch inputs context prefix. */\nconst inputsContextPrefix = \"inputs.\";\n\n/** Check whether a scalar string references the legacy inputs context. */\nconst hasGithubEventInputsReference = (value: string): boolean =>\n value.includes(githubEventInputsPrefix);\n\n/** Replace legacy workflow_dispatch inputs references with the preferred form. */\nconst replaceGithubEventInputsReferences = (value: string): string =>\n value.replaceAll(githubEventInputsPrefix, inputsContextPrefix);\n\n/** Visit every string scalar reachable from a YAML value node. */\nconst visitStringScalars = (\n node: null | Readonly<AST.YAMLContent | AST.YAMLWithMeta>,\n visitor: (node: Readonly<AST.YAMLScalar>, value: string) => void\n): void => {\n const unwrappedNode = unwrapYamlValue(\n node as AST.YAMLContent | AST.YAMLWithMeta | null\n );\n\n if (unwrappedNode === null) {\n return;\n }\n\n if (unwrappedNode.type === \"YAMLScalar\") {\n const value = getScalarStringValue(unwrappedNode);\n\n if (value !== null) {\n visitor(unwrappedNode, value);\n }\n\n return;\n }\n\n if (unwrappedNode.type === \"YAMLSequence\") {\n for (const entry of unwrappedNode.entries) {\n visitStringScalars(entry, visitor);\n }\n\n return;\n }\n\n if (unwrappedNode.type !== \"YAMLMapping\") {\n return;\n }\n\n for (const pair of unwrappedNode.pairs) {\n visitStringScalars(pair.value ?? null, visitor);\n }\n};\n\n/** Rule implementation for preferring the `inputs` context. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const eventNames = getWorkflowEventNames(root);\n\n if (!eventNames.has(\"workflow_dispatch\")) {\n return;\n }\n\n visitStringScalars(root, (node, value) => {\n if (!hasGithubEventInputsReference(value)) {\n return;\n }\n\n context.report({\n fix: (fixer) => {\n const originalText = context.sourceCode.text.slice(\n node.range[0],\n node.range[1]\n );\n const fixedText =\n replaceGithubEventInputsReferences(\n originalText\n );\n\n return originalText === fixedText\n ? null\n : fixer.replaceTextRange(node.range, fixedText);\n },\n messageId: \"preferInputsContext\",\n node: node as unknown as Rule.Node,\n });\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"enforce the `inputs` context instead of `github.event.inputs` in `workflow_dispatch` workflows so boolean inputs preserve their native type semantics.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R033\",\n ruleNumber: 33,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/prefer-inputs-context\",\n },\n fixable: \"code\",\n messages: {\n preferInputsContext:\n \"Prefer `inputs.*` over `github.event.inputs.*` in `workflow_dispatch` workflows because the `inputs` context preserves booleans and is the documented shorthand.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Enforce a consistent style for step-level `uses:` references.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Supported `uses:` reference styles. */\nconst usesStyles = [\n \"branch\",\n \"commit\",\n \"release\",\n] as const;\n\n/** Object-style configuration for `prefer-step-uses-style`. */\ntype PreferStepUsesStyleObjectOption = Partial<\n Record<StepUsesStyle, boolean>\n> & {\n readonly allowDocker?: boolean;\n readonly allowRepository?: boolean;\n readonly ignores?: readonly string[];\n};\n\n/** String literal union of supported `uses:` styles. */\ntype StepUsesStyle = (typeof usesStyles)[number];\n\n/** Default `uses:` style enforced by the rule. */\nconst DEFAULT_STEP_USES_STYLE: StepUsesStyle = \"commit\";\n\n/** Normalize prefer-step-uses-style options into a consistent runtime shape. */\nconst normalizeStepUsesStyleOptions = (\n option: Readonly<\n PreferStepUsesStyleObjectOption | StepUsesStyle | undefined\n >\n): {\n allowDocker: boolean;\n allowedStyles: readonly StepUsesStyle[];\n allowRepository: boolean;\n ignoredReferences: readonly string[];\n} => {\n if (option === undefined || typeof option === \"string\") {\n return {\n allowDocker: false,\n allowedStyles: [option ?? DEFAULT_STEP_USES_STYLE],\n allowRepository: false,\n ignoredReferences: [],\n };\n }\n\n const allowedStyles = usesStyles.filter((style) => option[style] === true);\n\n return {\n allowDocker: option.allowDocker ?? false,\n allowedStyles:\n allowedStyles.length > 0\n ? allowedStyles\n : [DEFAULT_STEP_USES_STYLE],\n allowRepository: option.allowRepository ?? false,\n ignoredReferences: [...(option.ignores ?? [])],\n };\n};\n\n/** Parse a step-level `uses:` reference into its normalized style. */\nconst parseStepUsesReference = (\n reference: string\n): {\n isDocker: boolean;\n isRepository: boolean;\n style: StepUsesStyle;\n} => {\n if (reference.startsWith(\"./\")) {\n return {\n isDocker: false,\n isRepository: true,\n style: DEFAULT_STEP_USES_STYLE,\n };\n }\n\n if (reference.startsWith(\"docker://\")) {\n return {\n isDocker: true,\n isRepository: false,\n style: DEFAULT_STEP_USES_STYLE,\n };\n }\n\n const delimiterIndex = reference.lastIndexOf(\"@\");\n const ref =\n delimiterIndex === -1 ? \"\" : reference.slice(delimiterIndex + 1);\n\n let isReleaseStyle = ref.startsWith(\"v\") && ref.length > 1;\n\n if (isReleaseStyle) {\n for (const character of ref.slice(1)) {\n if (character !== \".\" && (character < \"0\" || character > \"9\")) {\n isReleaseStyle = false;\n break;\n }\n }\n }\n\n if (/^[0-9a-f]{40}$/u.test(ref)) {\n return {\n isDocker: false,\n isRepository: false,\n style: \"commit\",\n };\n }\n\n if (isReleaseStyle) {\n return {\n isDocker: false,\n isRepository: false,\n style: \"release\",\n };\n }\n\n return {\n isDocker: false,\n isRepository: false,\n style: \"branch\",\n };\n};\n\n/** Rule implementation for enforcing step-level `uses:` reference style. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const [option] = context.options as [\n (PreferStepUsesStyleObjectOption | StepUsesStyle)?,\n ];\n const {\n allowDocker,\n allowedStyles,\n allowRepository,\n ignoredReferences,\n } = normalizeStepUsesStyleOptions(option ?? undefined);\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n const stepsSequence = getMappingValueAsSequence(\n job.mapping,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n continue;\n }\n\n for (const entry of stepsSequence.entries) {\n const stepMapping = unwrapYamlValue(entry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const usesPair = getMappingPair(stepMapping, \"uses\");\n const usesReference = getScalarStringValue(\n usesPair?.value ?? null\n );\n\n if (usesPair === null || usesReference === null) {\n continue;\n }\n\n if (ignoredReferences.includes(usesReference)) {\n continue;\n }\n\n const parsedReference =\n parseStepUsesReference(usesReference);\n\n if (parsedReference.isRepository) {\n if (!allowRepository) {\n context.report({\n messageId: \"repositoryActionDisallowed\",\n node: (usesPair.value ??\n usesPair) as unknown as Rule.Node,\n });\n }\n\n continue;\n }\n\n if (parsedReference.isDocker) {\n if (!allowDocker) {\n context.report({\n messageId: \"dockerActionDisallowed\",\n node: (usesPair.value ??\n usesPair) as unknown as Rule.Node,\n });\n }\n\n continue;\n }\n\n if (!allowedStyles.includes(parsedReference.style)) {\n context.report({\n data: {\n style: parsedReference.style,\n },\n messageId: \"styleDisallowed\",\n node: (usesPair.value ??\n usesPair) as unknown as Rule.Node,\n });\n }\n }\n }\n },\n };\n },\n meta: {\n defaultOptions: [DEFAULT_STEP_USES_STYLE],\n deprecated: false,\n docs: {\n configs: [\"github-actions.configs.all\"],\n description:\n \"enforce a consistent style for step-level `uses` references.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R016\",\n ruleNumber: 16,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/prefer-step-uses-style\",\n },\n messages: {\n dockerActionDisallowed:\n \"Docker-based `uses` references are disallowed by this rule configuration.\",\n repositoryActionDisallowed:\n \"Repository-local `uses` references are disallowed by this rule configuration.\",\n styleDisallowed:\n \"Step `uses` references with style '{{style}}' are disallowed by this rule configuration.\",\n },\n schema: [\n {\n anyOf: [\n {\n description:\n \"Single allowed style for step-level `uses` references.\",\n enum: usesStyles,\n type: \"string\",\n },\n {\n additionalProperties: false,\n description:\n \"Allowed styles and exceptions for step-level `uses` references.\",\n properties: {\n allowDocker: {\n description:\n \"Allow Docker-based step `uses` references such as docker://alpine:3.20.\",\n type: \"boolean\",\n },\n allowRepository: {\n description:\n \"Allow repository-local step `uses` references such as ./.github/actions/foo.\",\n type: \"boolean\",\n },\n branch: {\n description:\n \"Allow branch-style references such as @main.\",\n type: \"boolean\",\n },\n commit: {\n description:\n \"Allow full-commit-SHA references such as @0123...abcd.\",\n type: \"boolean\",\n },\n ignores: {\n description:\n \"Literal step `uses` references that should be ignored by this rule.\",\n items: {\n type: \"string\",\n },\n type: \"array\",\n uniqueItems: true,\n },\n release: {\n description:\n \"Allow release-style references such as @v4 or @v4.2.0.\",\n type: \"boolean\",\n },\n },\n type: \"object\",\n },\n ],\n description:\n \"Configure the allowed styles for step-level `uses` references.\",\n },\n ],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Prefer `.yml` over `.yaml` for workflow template YAML files.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n isWorkflowTemplateYamlFile,\n usesYamlExtension,\n} from \"../_internal/lint-targets.js\";\n\n/** Rule implementation for template YAML extension preference checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!isWorkflowTemplateYamlFile(context.filename)) {\n return;\n }\n\n if (!usesYamlExtension(context.filename)) {\n return;\n }\n\n context.report({\n messageId: \"preferTemplateYml\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"require workflow template files to prefer `.yml` over `.yaml`.\",\n dialects: [\"GitHub Actions workflow template\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R066\",\n ruleNumber: 66,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/prefer-template-yml-extension\",\n },\n messages: {\n preferTemplateYml:\n \"Prefer `.yml` for workflow template files instead of `.yaml`.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require every workflow file to declare a human-readable top-level name.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring a string workflow name. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!isWorkflowFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n context.report({\n messageId: \"missingName\",\n node: node as unknown as Rule.Node,\n });\n\n return;\n }\n\n const namePair = getMappingPair(root, \"name\");\n\n if (namePair === null) {\n context.report({\n messageId: \"missingName\",\n node: root as unknown as Rule.Node,\n });\n\n return;\n }\n\n const nameValue = getScalarStringValue(namePair.value);\n\n if (nameValue === null || nameValue.trim().length === 0) {\n context.report({\n messageId: \"invalidName\",\n node: (namePair.value ??\n namePair) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require a non-empty string workflow `name` so workflow runs stay readable in the GitHub Actions UI.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R005\",\n ruleNumber: 5,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-action-name\",\n },\n messages: {\n invalidName: \"Workflow `name` must be a non-empty string.\",\n missingName:\n \"Add a top-level workflow `name` so runs are identifiable in the GitHub Actions UI.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require every workflow file to declare a run-name string.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring a string workflow run-name. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!isWorkflowFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n context.report({\n messageId: \"missingRunName\",\n node: node as unknown as Rule.Node,\n });\n\n return;\n }\n\n const runNamePair = getMappingPair(root, \"run-name\");\n\n if (runNamePair === null) {\n context.report({\n messageId: \"missingRunName\",\n node: root as unknown as Rule.Node,\n });\n\n return;\n }\n\n const runNameValue = getScalarStringValue(runNamePair.value);\n\n if (runNameValue === null || runNameValue.trim().length === 0) {\n context.report({\n messageId: \"invalidRunName\",\n node: (runNamePair.value ??\n runNamePair) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require a non-empty string workflow `run-name` when you want queued and in-progress runs to remain self-describing.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R006\",\n ruleNumber: 6,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-action-run-name\",\n },\n messages: {\n invalidRunName: \"Workflow `run-name` must be a non-empty string.\",\n missingRunName:\n \"Add a top-level workflow `run-name` so individual workflow runs are easier to distinguish.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require a checkout step before using repository-local actions.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Determine whether a step uses the checkout action. */\nconst isCheckoutActionReference = (reference: string): boolean =>\n reference.startsWith(\"actions/checkout@\");\n\n/** Determine whether a step uses a repository-local action path. */\nconst isLocalActionReference = (reference: string): boolean =>\n reference.startsWith(\"./\");\n\n/** Rule implementation for requiring checkout before local actions. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n const stepsSequence = getMappingValueAsSequence(\n job.mapping,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n continue;\n }\n\n let hasSeenCheckout = false;\n\n for (const entry of stepsSequence.entries) {\n const stepMapping = unwrapYamlValue(entry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const usesPair = getMappingPair(stepMapping, \"uses\");\n const usesReference = getScalarStringValue(\n usesPair?.value ?? null\n );\n\n if (usesPair === null || usesReference === null) {\n continue;\n }\n\n if (isCheckoutActionReference(usesReference)) {\n hasSeenCheckout = true;\n continue;\n }\n\n if (\n isLocalActionReference(usesReference) &&\n !hasSeenCheckout\n ) {\n context.report({\n data: {\n jobId: job.id,\n reference: usesReference,\n },\n messageId: \"missingCheckoutBeforeLocalAction\",\n node: (usesPair.value ??\n usesPair) as unknown as Rule.Node,\n });\n }\n }\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require an `actions/checkout` step before using repository-local step actions so local action paths resolve reliably.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R025\",\n ruleNumber: 25,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-checkout-before-local-action\",\n },\n messages: {\n missingCheckoutBeforeLocalAction:\n \"Job '{{jobId}}' uses local action '{{reference}}' before any `actions/checkout` step. Check out the repository first.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Helpers for reasoning about workflow and job-level GitHub token permissions.\n */\n/* eslint-disable @typescript-eslint/prefer-readonly-parameter-types -- YAML AST nodes come from parser-owned mutable types shared across helper boundaries. */\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getScalarStringValue,\n unwrapYamlValue,\n type WorkflowJobEntry,\n} from \"./workflow-yaml.js\";\n\n/** GitHub token permission levels used in workflow YAML. */\nexport type WorkflowPermissionLevel = \"read\" | \"write\";\n\n/** Read the permissions node for a workflow or job mapping. */\nconst getPermissionsNode = (\n mapping: AST.YAMLMapping\n): AST.YAMLContent | AST.YAMLWithMeta | null =>\n getMappingPair(mapping, \"permissions\")?.value ?? null;\n\n/** Determine whether a permissions scalar satisfies the required access level. */\nconst scalarPermissionSatisfies = (\n scalarValue: string,\n requiredLevel: WorkflowPermissionLevel\n): boolean => {\n const normalizedValue = scalarValue.trim().toLowerCase();\n\n if (normalizedValue === \"write-all\") {\n return true;\n }\n\n if (requiredLevel === \"read\") {\n return normalizedValue === \"read-all\";\n }\n\n return false;\n};\n\n/**\n * Determine whether a permissions mapping satisfies a required permission\n * level.\n */\nconst mappingPermissionSatisfies = (\n permissionsMapping: AST.YAMLMapping,\n permissionName: string,\n requiredLevel: WorkflowPermissionLevel\n): boolean => {\n const permissionValue = getScalarStringValue(\n getMappingPair(permissionsMapping, permissionName)?.value ?? null\n )?.trim();\n\n if (permissionValue === undefined || permissionValue.length === 0) {\n return false;\n }\n\n if (requiredLevel === \"read\") {\n return permissionValue === \"read\" || permissionValue === \"write\";\n }\n\n return permissionValue === \"write\";\n};\n\n/** Determine whether a permissions node satisfies a required permission level. */\nconst permissionsNodeSatisfies = (\n permissionsNode: AST.YAMLContent | AST.YAMLWithMeta | null,\n permissionName: string,\n requiredLevel: WorkflowPermissionLevel\n): boolean => {\n const scalarValue = getScalarStringValue(permissionsNode)?.trim();\n\n if (scalarValue !== undefined && scalarValue.length > 0) {\n return scalarPermissionSatisfies(scalarValue, requiredLevel);\n }\n\n const unwrappedPermissionsNode = unwrapYamlValue(permissionsNode);\n\n if (unwrappedPermissionsNode?.type === \"YAMLMapping\") {\n return mappingPermissionSatisfies(\n unwrappedPermissionsNode,\n permissionName,\n requiredLevel\n );\n }\n\n return false;\n};\n\n/** Determine whether a workflow/job has the required effective permission level. */\nexport const hasRequiredWorkflowPermission = (\n root: AST.YAMLMapping,\n job: WorkflowJobEntry,\n permissionName: string,\n requiredLevel: WorkflowPermissionLevel\n): boolean => {\n const jobPermissionsNode = getPermissionsNode(job.mapping);\n\n if (jobPermissionsNode !== null) {\n return permissionsNodeSatisfies(\n jobPermissionsNode,\n permissionName,\n requiredLevel\n );\n }\n\n return permissionsNodeSatisfies(\n getPermissionsNode(root),\n permissionName,\n requiredLevel\n );\n};\n\n/* eslint-enable @typescript-eslint/prefer-readonly-parameter-types -- Re-enable readonly-parameter checks outside parser AST helper signatures. */\n", "/**\n * @packageDocumentation\n * Require CodeQL jobs to grant actions read permissions.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getCodeqlAnalyzeSteps,\n getCodeqlAutobuildSteps,\n getCodeqlInitSteps,\n getSarifUploadSteps,\n} from \"../_internal/code-scanning-workflow.ts\";\nimport { hasRequiredWorkflowPermission } from \"../_internal/workflow-permissions.ts\";\nimport { getWorkflowRoot } from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for CodeQL actions:read requirements. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const steps = [\n ...getCodeqlInitSteps(root),\n ...getCodeqlAutobuildSteps(root),\n ...getCodeqlAnalyzeSteps(root),\n ...getSarifUploadSteps(root),\n ];\n const seenJobIds = new Set<string>();\n\n for (const step of steps) {\n if (seenJobIds.has(step.job.id)) {\n continue;\n }\n\n seenJobIds.add(step.job.id);\n\n if (\n hasRequiredWorkflowPermission(\n root,\n step.job,\n \"actions\",\n \"read\"\n )\n ) {\n continue;\n }\n\n context.report({\n data: {\n jobId: step.job.id,\n },\n messageId: \"missingActionsRead\",\n node: step.job.idNode as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.codeScanning\",\n ],\n description:\n \"require jobs running CodeQL actions to grant `actions: read`.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R099\",\n ruleNumber: 99,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-codeql-actions-read\",\n },\n messages: {\n missingActionsRead:\n \"Job '{{jobId}}' uses CodeQL actions and should grant `actions: read`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require CodeQL push and pull_request triggers to scope branches explicitly.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport { getCodeqlInitSteps } from \"../_internal/code-scanning-workflow.ts\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\nconst hasConfiguredBranchFilter = (\n node: null | Readonly<AST.YAMLPair> | undefined\n): boolean => {\n const valueNode = unwrapYamlValue(node?.value ?? null);\n\n if (valueNode === null) {\n return false;\n }\n\n if (valueNode.type === \"YAMLScalar\") {\n const value = getScalarStringValue(valueNode);\n\n return value !== null && value.trim().length > 0;\n }\n\n if (valueNode.type !== \"YAMLSequence\") {\n return false;\n }\n\n return valueNode.entries.some((entry) => {\n const value = getScalarStringValue(entry);\n\n return value !== null && value.trim().length > 0;\n });\n};\n\n/**\n * Rule implementation for requiring branch filters on CodeQL push and PR\n * triggers.\n */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null || getCodeqlInitSteps(root).length === 0) {\n return;\n }\n\n const onMapping = getMappingValueAsMapping(root, \"on\");\n\n if (onMapping === null) {\n return;\n }\n\n for (const triggerName of [\"push\", \"pull_request\"]) {\n const triggerPair = getMappingPair(onMapping, triggerName);\n const triggerMapping =\n triggerPair === null\n ? null\n : unwrapYamlValue(triggerPair.value);\n\n if (triggerMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const branchesPair = getMappingPair(\n triggerMapping,\n \"branches\"\n );\n const branchesIgnorePair = getMappingPair(\n triggerMapping,\n \"branches-ignore\"\n );\n\n if (\n hasConfiguredBranchFilter(branchesPair) ||\n hasConfiguredBranchFilter(branchesIgnorePair)\n ) {\n continue;\n }\n\n context.report({\n data: { triggerName },\n messageId: \"missingBranchFilter\",\n node: triggerMapping as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.codeScanning\",\n ],\n description:\n \"require CodeQL `push` and `pull_request` triggers to scope branches explicitly.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R113\",\n ruleNumber: 113,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-codeql-branch-filters\",\n },\n messages: {\n missingBranchFilter:\n \"CodeQL trigger '{{triggerName}}' should declare a non-empty `branches` or `branches-ignore` filter.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require CodeQL analyze steps to set a category that includes the matrix language when a language matrix is used.\n */\nimport type { Rule } from \"eslint\";\n\nimport { getCodeqlAnalyzeSteps } from \"../_internal/code-scanning-workflow.ts\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/**\n * Rule implementation for requiring CodeQL category when matrix.language is\n * used.\n */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const step of getCodeqlAnalyzeSteps(root)) {\n const strategyMapping = getMappingValueAsMapping(\n step.job.mapping,\n \"strategy\"\n );\n const matrixMapping =\n strategyMapping === null\n ? null\n : getMappingValueAsMapping(\n strategyMapping,\n \"matrix\"\n );\n\n if (\n matrixMapping === null ||\n getMappingPair(matrixMapping, \"language\") === null\n ) {\n continue;\n }\n\n const withMapping = getMappingValueAsMapping(\n step.stepMapping,\n \"with\"\n );\n const categoryPair =\n withMapping === null\n ? null\n : getMappingPair(withMapping, \"category\");\n const categoryValue = getScalarStringValue(\n categoryPair?.value ?? null\n )?.trim();\n\n if (categoryValue?.includes(\"matrix.language\") === true) {\n continue;\n }\n\n context.report({\n data: { jobId: step.job.id },\n messageId: \"missingCategoryForLanguageMatrix\",\n node: (categoryPair?.value ??\n categoryPair ??\n withMapping ??\n step.usesPair) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.codeScanning\",\n ],\n description:\n \"require CodeQL analyze steps to set `with.category` using `matrix.language` when the job uses a language matrix.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R114\",\n ruleNumber: 114,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-codeql-category-when-language-matrix\",\n },\n messages: {\n missingCategoryForLanguageMatrix:\n \"CodeQL analyze step in job '{{jobId}}' should set `with.category` to include `matrix.language` when a language matrix is used.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require CodeQL workflows to run on pull_request.\n */\nimport type { Rule } from \"eslint\";\n\nimport { getCodeqlInitSteps } from \"../_internal/code-scanning-workflow.ts\";\nimport {\n getWorkflowEventNames,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring pull_request triggers on CodeQL workflows. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n const root = getWorkflowRoot(context);\n\n if (root === null || getCodeqlInitSteps(root).length === 0) {\n return;\n }\n\n if (getWorkflowEventNames(root).has(\"pull_request\")) {\n return;\n }\n\n context.report({\n messageId: \"missingPullRequestTrigger\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.codeScanning\",\n ],\n description:\n \"require CodeQL workflows to listen for `pull_request`.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R100\",\n ruleNumber: 100,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-codeql-pull-request-trigger\",\n },\n messages: {\n missingPullRequestTrigger:\n \"CodeQL workflows should listen for `pull_request` so code scanning runs on incoming pull requests.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require CodeQL workflows to run on a schedule.\n */\nimport type { Rule } from \"eslint\";\n\nimport { getCodeqlInitSteps } from \"../_internal/code-scanning-workflow.ts\";\nimport {\n getWorkflowEventNames,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring scheduled CodeQL runs. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n const root = getWorkflowRoot(context);\n\n if (root === null || getCodeqlInitSteps(root).length === 0) {\n return;\n }\n\n if (getWorkflowEventNames(root).has(\"schedule\")) {\n return;\n }\n\n context.report({\n messageId: \"missingScheduleTrigger\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.codeScanning\",\n ],\n description:\n \"require CodeQL workflows to include a scheduled trigger for periodic re-analysis.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R101\",\n ruleNumber: 101,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-codeql-schedule\",\n },\n messages: {\n missingScheduleTrigger:\n \"CodeQL workflows should include a `schedule` trigger for periodic re-analysis.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require CodeQL analysis jobs to grant security-events write permissions.\n */\nimport type { Rule } from \"eslint\";\n\nimport { getCodeqlAnalyzeSteps } from \"../_internal/code-scanning-workflow.ts\";\nimport { hasRequiredWorkflowPermission } from \"../_internal/workflow-permissions.ts\";\nimport { getWorkflowRoot } from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for CodeQL security-events permission requirements. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const step of getCodeqlAnalyzeSteps(root)) {\n if (\n hasRequiredWorkflowPermission(\n root,\n step.job,\n \"security-events\",\n \"write\"\n )\n ) {\n continue;\n }\n\n context.report({\n data: {\n jobId: step.job.id,\n },\n messageId: \"missingSecurityEventsWrite\",\n node: step.job.idNode as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.codeScanning\",\n \"github-actions.configs.security\",\n ],\n description:\n \"require jobs running CodeQL analysis to grant `security-events: write`.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R098\",\n ruleNumber: 98,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-codeql-security-events-write\",\n },\n messages: {\n missingSecurityEventsWrite:\n \"Job '{{jobId}}' runs CodeQL analysis and should grant `security-events: write`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require `name` on composite action steps.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isActionMetadataFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring names on composite steps. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n if (!isActionMetadataFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n const runsMapping =\n root === null\n ? null\n : getMappingValueAsMapping(root, \"runs\");\n\n if (runsMapping === null) {\n return;\n }\n\n const usingRuntime = getScalarStringValue(\n getMappingPair(runsMapping, \"using\")?.value\n );\n\n if (usingRuntime !== \"composite\") {\n return;\n }\n\n const stepsSequence = getMappingValueAsSequence(\n runsMapping,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n return;\n }\n\n for (const [\n index,\n stepEntry,\n ] of stepsSequence.entries.entries()) {\n const stepMapping = unwrapYamlValue(stepEntry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const nameValue = getScalarStringValue(\n getMappingPair(stepMapping, \"name\")?.value\n );\n\n if (nameValue !== null && nameValue.trim().length > 0) {\n continue;\n }\n\n context.report({\n data: {\n index: String(index + 1),\n },\n messageId: \"missingCompositeStepName\",\n node: stepMapping as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.actionMetadata\",\n \"github-actions.configs.all\",\n ],\n description:\n \"require each composite action step to declare a descriptive `name`.\",\n dialects: [\"GitHub Action metadata\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R052\",\n ruleNumber: 52,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-composite-step-name\",\n },\n messages: {\n missingCompositeStepName:\n \"Composite step #{{index}} should declare a non-empty `name` for readability and debugging.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require Dependabot update entries to define effective assignees.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getDependabotRoot,\n getDependabotUpdateEntries,\n getDependabotUpdateLabel,\n getEffectiveDependabotUpdateValue,\n getNonEmptyStringSequenceEntries,\n} from \"../_internal/dependabot-yaml.js\";\n\n/** Rule implementation for requiring effective assignees. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getDependabotRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const update of getDependabotUpdateEntries(root)) {\n const assigneesValue = getEffectiveDependabotUpdateValue(\n root,\n update,\n \"assignees\"\n );\n\n if (\n getNonEmptyStringSequenceEntries(assigneesValue)\n .length > 0\n ) {\n continue;\n }\n\n context.report({\n data: {\n updateLabel: getDependabotUpdateLabel(update),\n },\n messageId: \"missingAssignees\",\n node: (assigneesValue ??\n update.node) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.dependabot\",\n ],\n description:\n \"require Dependabot update entries to define effective `assignees` directly or via a multi-ecosystem group.\",\n dialects: [\"Dependabot configuration\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R077\",\n ruleNumber: 77,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependabot-assignees\",\n },\n messages: {\n missingAssignees:\n \"{{updateLabel}} should define non-empty `assignees` so Dependabot pull requests have clear ownership.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Helpers for workflows that automate Dependabot pull requests.\n */\n/* eslint-disable @typescript-eslint/prefer-readonly-parameter-types -- YAML AST nodes come from parser-owned mutable types shared across helper boundaries. */\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport type {\n WorkflowActionStep,\n WorkflowRunStep,\n} from \"./workflow-action-steps.js\";\n\nimport {\n getWorkflowActionSteps,\n getWorkflowRunSteps,\n hasWorkflowRunStep,\n} from \"./workflow-action-steps.js\";\n\n/**\n * Determine whether a `uses` reference points to the Dependabot fetch-metadata\n * action.\n */\nexport const isDependabotFetchMetadataReference = (\n usesReference: string\n): boolean => usesReference.trim().startsWith(\"dependabot/fetch-metadata@\");\n\n/** Determine whether a run step edits a pull request via `gh pr edit`. */\nexport const isGhPrEditRunScript = (runScript: string): boolean =>\n /\\bgh\\s+pr\\s+edit\\b/u.test(runScript);\n\n/** Determine whether a run step reviews a pull request via `gh pr review`. */\nexport const isGhPrReviewRunScript = (runScript: string): boolean =>\n /\\bgh\\s+pr\\s+review\\b/u.test(runScript);\n\n/** Determine whether a run step merges a pull request via `gh pr merge`. */\nexport const isGhPrMergeRunScript = (runScript: string): boolean =>\n /\\bgh\\s+pr\\s+merge\\b/u.test(runScript);\n\n/** Determine whether a run step automates a pull request via GitHub CLI. */\nexport const isDependabotAutomationRunScript = (runScript: string): boolean =>\n isGhPrEditRunScript(runScript) ||\n isGhPrReviewRunScript(runScript) ||\n isGhPrMergeRunScript(runScript);\n\n/** Collect all Dependabot fetch-metadata action steps in a workflow. */\nexport const getDependabotFetchMetadataSteps = (\n root: AST.YAMLMapping\n): readonly WorkflowActionStep[] =>\n getWorkflowActionSteps(root, isDependabotFetchMetadataReference);\n\n/** Collect all GitHub CLI run steps that automate pull requests. */\nexport const getDependabotAutomationRunSteps = (\n root: AST.YAMLMapping\n): readonly WorkflowRunStep[] =>\n getWorkflowRunSteps(root, isDependabotAutomationRunScript);\n\n/** Determine whether a workflow contains recognized Dependabot automation steps. */\nexport const hasDependabotAutomation = (root: AST.YAMLMapping): boolean =>\n getDependabotFetchMetadataSteps(root).length > 0 ||\n hasWorkflowRunStep(root, isDependabotAutomationRunScript);\n\n/* eslint-enable @typescript-eslint/prefer-readonly-parameter-types -- Re-enable readonly-parameter checks outside parser AST helper signatures. */\n", "/**\n * @packageDocumentation\n * Require minimum permissions for workflows that automate Dependabot pull requests.\n */\nimport type { Rule } from \"eslint\";\n\nimport { getDependabotAutomationRunSteps } from \"../_internal/dependabot-automation-workflow.ts\";\nimport { hasRequiredWorkflowPermission } from \"../_internal/workflow-permissions.ts\";\nimport { getWorkflowRoot } from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for Dependabot automation permission requirements. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const step of getDependabotAutomationRunSteps(root)) {\n if (\n !hasRequiredWorkflowPermission(\n root,\n step.job,\n \"pull-requests\",\n \"write\"\n )\n ) {\n context.report({\n data: { jobId: step.job.id },\n messageId: \"missingPullRequestsWrite\",\n node: step.job.idNode as unknown as Rule.Node,\n });\n }\n\n if (\n step.runScript.includes(\"gh pr edit\") &&\n step.runScript.includes(\"--add-label\") &&\n !hasRequiredWorkflowPermission(\n root,\n step.job,\n \"issues\",\n \"write\"\n )\n ) {\n context.report({\n data: { jobId: step.job.id },\n messageId: \"missingIssuesWrite\",\n node: step.job.idNode as unknown as Rule.Node,\n });\n }\n\n if (\n step.runScript.includes(\"gh pr merge\") &&\n !hasRequiredWorkflowPermission(\n root,\n step.job,\n \"contents\",\n \"write\"\n )\n ) {\n context.report({\n data: { jobId: step.job.id },\n messageId: \"missingContentsWrite\",\n node: step.job.idNode as unknown as Rule.Node,\n });\n }\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.security\",\n ],\n description:\n \"require minimum GitHub token permissions for Dependabot pull request automation steps.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R111\",\n ruleNumber: 111,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependabot-automation-permissions\",\n },\n messages: {\n missingContentsWrite:\n \"Job '{{jobId}}' uses `gh pr merge` and should grant `contents: write`.\",\n missingIssuesWrite:\n \"Job '{{jobId}}' edits pull request labels and should grant `issues: write`.\",\n missingPullRequestsWrite:\n \"Job '{{jobId}}' automates pull requests and should grant `pull-requests: write`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require Dependabot pull request automation workflows to run on pull_request.\n */\nimport type { Rule } from \"eslint\";\n\nimport { hasDependabotAutomation } from \"../_internal/dependabot-automation-workflow.ts\";\nimport {\n getWorkflowEventNames,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/**\n * Rule implementation for requiring pull_request on Dependabot automation\n * workflows.\n */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n const root = getWorkflowRoot(context);\n\n if (root === null || !hasDependabotAutomation(root)) {\n return;\n }\n\n if (getWorkflowEventNames(root).has(\"pull_request\")) {\n return;\n }\n\n context.report({\n messageId: \"missingPullRequestTrigger\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.security\",\n ],\n description:\n \"require Dependabot pull request automation workflows to listen for `pull_request`.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R112\",\n ruleNumber: 112,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependabot-automation-pull-request-trigger\",\n },\n messages: {\n missingPullRequestTrigger:\n \"Dependabot pull request automation workflows should listen for `pull_request`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require Dependabot automation jobs or steps to guard on the Dependabot bot actor.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getDependabotAutomationRunSteps,\n getDependabotFetchMetadataSteps,\n hasDependabotAutomation,\n} from \"../_internal/dependabot-automation-workflow.ts\";\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\nconst hasDependabotBotGuard = (value: null | string | undefined): boolean =>\n typeof value === \"string\" && value.includes(\"dependabot[bot]\");\n\n/** Rule implementation for Dependabot bot guard requirements. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null || !hasDependabotAutomation(root)) {\n return;\n }\n\n const runStepsByJobId = new Map(\n getDependabotAutomationRunSteps(root).map((step) => [\n step.job.id,\n step,\n ])\n );\n\n for (const step of getDependabotFetchMetadataSteps(root)) {\n const jobIfValue = getScalarStringValue(\n getMappingPair(step.job.mapping, \"if\")?.value ?? null\n );\n\n if (hasDependabotBotGuard(jobIfValue)) {\n continue;\n }\n\n const pairedRunStep = runStepsByJobId.get(step.job.id);\n const runStepIfValue = getScalarStringValue(\n pairedRunStep\n ? (getMappingPair(pairedRunStep.stepMapping, \"if\")\n ?.value ?? null)\n : null\n );\n\n if (\n pairedRunStep !== undefined &&\n hasDependabotBotGuard(runStepIfValue)\n ) {\n continue;\n }\n\n context.report({\n data: { jobId: step.job.id },\n messageId: \"missingDependabotBotGuard\",\n node: step.job.idNode as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.security\",\n ],\n description:\n \"require Dependabot automation jobs to guard execution on `dependabot[bot]`.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R109\",\n ruleNumber: 109,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependabot-bot-actor-guard\",\n },\n messages: {\n missingDependabotBotGuard:\n \"Job '{{jobId}}' automates Dependabot pull requests and should guard execution on `dependabot[bot]`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require Dependabot commit messages to include dependency scope information.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getDependabotMappingStringValue,\n getDependabotRoot,\n getDependabotUpdateEntries,\n getDependabotUpdateLabel,\n getEffectiveDependabotUpdateMapping,\n} from \"../_internal/dependabot-yaml.js\";\nimport { getMappingPair } from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for commit-message.include requirements. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getDependabotRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const update of getDependabotUpdateEntries(root)) {\n const commitMessageMapping =\n getEffectiveDependabotUpdateMapping(\n root,\n update,\n \"commit-message\"\n );\n const includePair =\n commitMessageMapping === null\n ? null\n : getMappingPair(commitMessageMapping, \"include\");\n const includeValue =\n commitMessageMapping === null\n ? null\n : getDependabotMappingStringValue(\n commitMessageMapping,\n \"include\"\n );\n\n if (includeValue === \"scope\") {\n continue;\n }\n\n context.report({\n data: {\n updateLabel: getDependabotUpdateLabel(update),\n },\n messageId: \"missingCommitMessageIncludeScope\",\n node: (includePair?.value ??\n includePair ??\n update.node) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.dependabot\",\n ],\n description:\n 'require Dependabot commit messages to set `commit-message.include: \"scope\"`.',\n dialects: [\"Dependabot configuration\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R089\",\n ruleNumber: 89,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependabot-commit-message-include-scope\",\n },\n messages: {\n missingCommitMessageIncludeScope:\n '{{updateLabel}} should set `commit-message.include: \"scope\"` so Dependabot pull request titles indicate dependency scope clearly.',\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require npm-like Dependabot update entries to define commit-message.prefix-development.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getDependabotMappingStringValue,\n getDependabotRoot,\n getDependabotUpdateEntries,\n getDependabotUpdateLabel,\n getEffectiveDependabotUpdateMapping,\n} from \"../_internal/dependabot-yaml.js\";\nimport { getMappingPair } from \"../_internal/workflow-yaml.js\";\n\nconst ecosystemsSupportingPrefixDevelopment = new Set([\n \"bundler\",\n \"composer\",\n \"maven\",\n \"mix\",\n \"npm\",\n \"pip\",\n \"uv\",\n]);\n\n/** Rule implementation for commit-message.prefix-development requirements. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getDependabotRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const update of getDependabotUpdateEntries(root)) {\n const packageEcosystem = update.packageEcosystem?.trim();\n\n if (\n packageEcosystem === undefined ||\n packageEcosystem === null ||\n !ecosystemsSupportingPrefixDevelopment.has(\n packageEcosystem\n )\n ) {\n continue;\n }\n\n const commitMessageMapping =\n getEffectiveDependabotUpdateMapping(\n root,\n update,\n \"commit-message\"\n );\n const prefixDevelopmentPair =\n commitMessageMapping === null\n ? null\n : getMappingPair(\n commitMessageMapping,\n \"prefix-development\"\n );\n const prefixDevelopmentValue =\n commitMessageMapping === null\n ? null\n : getDependabotMappingStringValue(\n commitMessageMapping,\n \"prefix-development\"\n );\n\n if (prefixDevelopmentValue !== null) {\n continue;\n }\n\n context.report({\n data: {\n updateLabel: getDependabotUpdateLabel(update),\n },\n messageId: \"missingPrefixDevelopment\",\n node: (prefixDevelopmentPair?.value ??\n prefixDevelopmentPair ??\n update.node) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.dependabot\",\n ],\n description:\n \"require npm-like Dependabot update entries to define `commit-message.prefix-development`.\",\n dialects: [\"Dependabot configuration\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R090\",\n ruleNumber: 90,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependabot-commit-message-prefix-development\",\n },\n messages: {\n missingPrefixDevelopment:\n \"{{updateLabel}} should define `commit-message.prefix-development` so development dependency updates have a distinct title convention.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require Dependabot update entries to define an effective commit message prefix.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getDependabotMappingStringValue,\n getDependabotRoot,\n getDependabotUpdateEntries,\n getDependabotUpdateLabel,\n getEffectiveDependabotUpdateMapping,\n} from \"../_internal/dependabot-yaml.js\";\nimport { getMappingPair } from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring effective commit-message prefixes. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getDependabotRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const update of getDependabotUpdateEntries(root)) {\n const commitMessageMapping =\n getEffectiveDependabotUpdateMapping(\n root,\n update,\n \"commit-message\"\n );\n const prefixPair =\n commitMessageMapping === null\n ? null\n : getMappingPair(commitMessageMapping, \"prefix\");\n const prefixValue =\n commitMessageMapping === null\n ? null\n : getDependabotMappingStringValue(\n commitMessageMapping,\n \"prefix\"\n );\n\n if (prefixValue !== null) {\n continue;\n }\n\n context.report({\n data: {\n updateLabel: getDependabotUpdateLabel(update),\n },\n messageId: \"missingCommitMessagePrefix\",\n node: (prefixPair?.value ??\n prefixPair ??\n update.node) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.dependabot\",\n ],\n description:\n \"require Dependabot update entries to define an effective `commit-message.prefix` directly or via a multi-ecosystem group.\",\n dialects: [\"Dependabot configuration\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R079\",\n ruleNumber: 79,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependabot-commit-message-prefix\",\n },\n messages: {\n missingCommitMessagePrefix:\n \"{{updateLabel}} should define `commit-message.prefix` so Dependabot pull requests follow a predictable title convention.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require Dependabot update entries to declare cooldown settings.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getDependabotRoot,\n getDependabotUpdateEntries,\n getDependabotUpdateLabel,\n} from \"../_internal/dependabot-yaml.js\";\nimport { getMappingPair } from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring cooldown settings. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getDependabotRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const update of getDependabotUpdateEntries(root)) {\n const cooldownPair = getMappingPair(\n update.mapping,\n \"cooldown\"\n );\n\n if (cooldownPair !== null) {\n continue;\n }\n\n context.report({\n data: {\n updateLabel: getDependabotUpdateLabel(update),\n },\n messageId: \"missingCooldown\",\n node: update.node as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.dependabot\",\n ],\n description:\n \"require Dependabot update entries to declare a `cooldown` policy.\",\n dialects: [\"Dependabot configuration\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R086\",\n ruleNumber: 86,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependabot-cooldown\",\n },\n messages: {\n missingCooldown:\n \"{{updateLabel}} should declare `cooldown` so version update churn is intentionally throttled.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require every Dependabot update entry to define `directory` or `directories`.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getDependabotRoot,\n getDependabotUpdateEntries,\n getDependabotUpdateLabel,\n getNonEmptyStringSequenceEntries,\n} from \"../_internal/dependabot-yaml.js\";\nimport {\n getMappingPair,\n getScalarStringValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Determine whether a scalar-like directory value is present and non-empty. */\nconst hasNonEmptyDirectory = (\n value: null | Readonly<AST.YAMLContent | AST.YAMLWithMeta> | undefined\n): boolean => {\n const directoryValue = getScalarStringValue(value)?.trim();\n\n return (\n directoryValue !== undefined &&\n directoryValue !== null &&\n directoryValue.length > 0\n );\n};\n\n/** Rule implementation for requiring `directory` or `directories`. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getDependabotRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const update of getDependabotUpdateEntries(root)) {\n const directoryPair = getMappingPair(\n update.mapping,\n \"directory\"\n );\n const directoriesPair = getMappingPair(\n update.mapping,\n \"directories\"\n );\n const hasDirectory = hasNonEmptyDirectory(\n directoryPair?.value\n );\n const directoryEntries = getNonEmptyStringSequenceEntries(\n directoriesPair?.value\n );\n const hasDirectories = directoryEntries.length > 0;\n\n if (hasDirectory !== hasDirectories) {\n continue;\n }\n\n context.report({\n data: {\n updateLabel: getDependabotUpdateLabel(update),\n },\n messageId:\n hasDirectory && hasDirectories\n ? \"conflictingDirectorySettings\"\n : \"missingDirectorySetting\",\n node: (directoriesPair ??\n directoryPair ??\n update.node) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.dependabot\",\n ],\n description:\n \"require every Dependabot `updates` entry to define exactly one of `directory` or `directories`.\",\n dialects: [\"Dependabot configuration\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R073\",\n ruleNumber: 73,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependabot-directory\",\n },\n messages: {\n conflictingDirectorySettings:\n \"{{updateLabel}} should define either `directory` or `directories`, not both.\",\n missingDirectorySetting:\n \"{{updateLabel}} must define a non-empty `directory` or `directories` value.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require GitHub Actions Dependabot updates to use `directory: /`.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getDependabotMappingStringValue,\n getDependabotRoot,\n getDependabotUpdateEntries,\n getDependabotUpdateLabel,\n} from \"../_internal/dependabot-yaml.js\";\nimport { getMappingPair } from \"../_internal/workflow-yaml.js\";\nimport { getEnclosingLineRemovalRange } from \"../_internal/yaml-fixes.js\";\n\n/** Rule implementation for GitHub Actions directory-root enforcement. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getDependabotRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const update of getDependabotUpdateEntries(root)) {\n if (update.packageEcosystem?.trim() !== \"github-actions\") {\n continue;\n }\n\n const directoryPair = getMappingPair(\n update.mapping,\n \"directory\"\n );\n const directoriesPair = getMappingPair(\n update.mapping,\n \"directories\"\n );\n const directoryValue = getDependabotMappingStringValue(\n update.mapping,\n \"directory\"\n );\n\n if (directoryValue === \"/\" && directoriesPair === null) {\n continue;\n }\n\n context.report({\n data: {\n updateLabel: getDependabotUpdateLabel(update),\n },\n fix: (fixer) => {\n const fixes = [];\n\n if (directoryPair !== null) {\n fixes.push(\n directoryPair.value === null\n ? fixer.replaceTextRange(\n directoryPair.range,\n 'directory: \"/\"'\n )\n : fixer.replaceTextRange(\n directoryPair.value.range,\n '\"/\"'\n )\n );\n\n if (directoriesPair !== null) {\n fixes.push(\n fixer.removeRange(\n getEnclosingLineRemovalRange(\n context.sourceCode.text,\n directoriesPair.range\n )\n )\n );\n }\n } else if (directoriesPair !== null) {\n fixes.push(\n fixer.replaceTextRange(\n directoriesPair.range,\n 'directory: \"/\"'\n )\n );\n }\n\n return fixes;\n },\n messageId: \"githubActionsDirectoryMustBeRoot\",\n node: (directoriesPair ??\n directoryPair ??\n update.node) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.dependabot\",\n ],\n description:\n 'require Dependabot `github-actions` update entries to use `directory: \"/\"`.',\n dialects: [\"Dependabot configuration\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R084\",\n ruleNumber: 84,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependabot-github-actions-directory-root\",\n },\n fixable: \"code\",\n messages: {\n githubActionsDirectoryMustBeRoot:\n '{{updateLabel}} uses `package-ecosystem: github-actions` and should use `directory: \"/\"` so Dependabot scans the standard workflow and root action metadata locations.',\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require Dependabot update entries to define effective labels.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getDependabotRoot,\n getDependabotUpdateEntries,\n getDependabotUpdateLabel,\n getEffectiveDependabotUpdateValue,\n getNonEmptyStringSequenceEntries,\n} from \"../_internal/dependabot-yaml.js\";\n\n/** Rule implementation for requiring effective labels. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getDependabotRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const update of getDependabotUpdateEntries(root)) {\n const labelsValue = getEffectiveDependabotUpdateValue(\n root,\n update,\n \"labels\"\n );\n\n if (\n getNonEmptyStringSequenceEntries(labelsValue).length > 0\n ) {\n continue;\n }\n\n context.report({\n data: {\n updateLabel: getDependabotUpdateLabel(update),\n },\n messageId: \"missingLabels\",\n node: (labelsValue ??\n update.node) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.dependabot\",\n ],\n description:\n \"require Dependabot update entries to define effective `labels` directly or via a multi-ecosystem group.\",\n dialects: [\"Dependabot configuration\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R080\",\n ruleNumber: 80,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependabot-labels\",\n },\n messages: {\n missingLabels:\n \"{{updateLabel}} should define non-empty `labels` so Dependabot pull requests stay easy to triage and automate.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require Dependabot update entries to define open pull request limits.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getDependabotRoot,\n getDependabotUpdateEntries,\n getDependabotUpdateLabel,\n} from \"../_internal/dependabot-yaml.js\";\nimport {\n getMappingPair,\n getScalarNumberValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring open-pull-requests-limit. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getDependabotRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const update of getDependabotUpdateEntries(root)) {\n const limitPair = getMappingPair(\n update.mapping,\n \"open-pull-requests-limit\"\n );\n const limitValue = getScalarNumberValue(\n limitPair?.value ?? null\n );\n\n if (limitValue !== null) {\n continue;\n }\n\n context.report({\n data: {\n updateLabel: getDependabotUpdateLabel(update),\n },\n messageId: \"missingOpenPullRequestsLimit\",\n node: (limitPair?.value ??\n limitPair ??\n update.node) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.dependabot\",\n ],\n description:\n \"require Dependabot update entries to define `open-pull-requests-limit`.\",\n dialects: [\"Dependabot configuration\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R087\",\n ruleNumber: 87,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependabot-open-pull-requests-limit\",\n },\n messages: {\n missingOpenPullRequestsLimit:\n \"{{updateLabel}} should define `open-pull-requests-limit` so Dependabot pull request volume is explicitly controlled.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require every Dependabot update entry to define a non-empty `package-ecosystem`.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getDependabotRoot,\n getDependabotUpdateLabel,\n} from \"../_internal/dependabot-yaml.js\";\nimport {\n getMappingPair,\n getMappingValueAsSequence,\n getScalarStringValue,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring `package-ecosystem` in each update entry. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getDependabotRoot(context);\n\n if (root === null) {\n return;\n }\n\n const updatesSequence = getMappingValueAsSequence(\n root,\n \"updates\"\n );\n\n if (updatesSequence === null) {\n return;\n }\n\n for (const [\n index,\n entry,\n ] of updatesSequence.entries.entries()) {\n const updateMapping = unwrapYamlValue(entry);\n\n if (entry === null || entry === undefined) {\n continue;\n }\n\n if (updateMapping?.type !== \"YAMLMapping\") {\n context.report({\n messageId: \"invalidDependabotUpdateEntry\",\n node: entry as unknown as Rule.Node,\n });\n\n continue;\n }\n\n const ecosystemPair = getMappingPair(\n updateMapping,\n \"package-ecosystem\"\n );\n const ecosystemValue = getScalarStringValue(\n ecosystemPair?.value\n )?.trim();\n\n if (\n ecosystemValue !== undefined &&\n ecosystemValue !== null &&\n ecosystemValue.length > 0\n ) {\n continue;\n }\n\n context.report({\n data: {\n updateLabel: getDependabotUpdateLabel({\n index: index + 1,\n mapping: updateMapping,\n multiEcosystemGroup: null,\n node: entry,\n packageEcosystem: null,\n }),\n },\n messageId: \"missingPackageEcosystem\",\n node: (ecosystemPair?.value ??\n ecosystemPair ??\n entry) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.dependabot\",\n ],\n description:\n \"require every Dependabot `updates` entry to define a non-empty `package-ecosystem`.\",\n dialects: [\"Dependabot configuration\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R072\",\n ruleNumber: 72,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependabot-package-ecosystem\",\n },\n messages: {\n invalidDependabotUpdateEntry:\n \"Each `updates` entry must be a mapping so Dependabot options such as `package-ecosystem` can be defined.\",\n missingPackageEcosystem:\n \"{{updateLabel}} is missing a non-empty `package-ecosystem` value.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require grouped Dependabot update entries to declare `patterns`.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getDependabotRoot,\n getDependabotUpdateEntries,\n getDependabotUpdateLabel,\n getNonEmptyStringSequenceEntries,\n} from \"../_internal/dependabot-yaml.js\";\nimport { getMappingPair } from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for grouped-update pattern requirements. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getDependabotRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const update of getDependabotUpdateEntries(root)) {\n if (update.multiEcosystemGroup === null) {\n continue;\n }\n\n const patternsPair = getMappingPair(\n update.mapping,\n \"patterns\"\n );\n const patternEntries = getNonEmptyStringSequenceEntries(\n patternsPair?.value\n );\n\n if (patternEntries.length > 0) {\n continue;\n }\n\n context.report({\n data: {\n updateLabel: getDependabotUpdateLabel(update),\n },\n messageId: \"missingPatternsForGroupedUpdate\",\n node: (patternsPair?.value ??\n patternsPair ??\n update.node) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.dependabot\",\n ],\n description:\n \"require Dependabot update entries that use `multi-ecosystem-group` to define non-empty `patterns`.\",\n dialects: [\"Dependabot configuration\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R082\",\n ruleNumber: 82,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependabot-patterns-for-multi-ecosystem-group\",\n },\n messages: {\n missingPatternsForGroupedUpdate:\n \"{{updateLabel}} uses `multi-ecosystem-group` and should define non-empty `patterns` so Dependabot knows which dependencies to group.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require cron schedules to declare `cronjob` and non-cron schedules to omit it.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getDependabotRoot,\n getDependabotUpdateEntries,\n getDependabotUpdateLabel,\n getEffectiveDependabotUpdateMapping,\n} from \"../_internal/dependabot-yaml.js\";\nimport {\n getMappingPair,\n getScalarStringValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for `schedule.cronjob` correctness. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getDependabotRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const update of getDependabotUpdateEntries(root)) {\n const scheduleMapping = getEffectiveDependabotUpdateMapping(\n root,\n update,\n \"schedule\"\n );\n\n if (scheduleMapping === null) {\n continue;\n }\n\n const intervalValue = getScalarStringValue(\n getMappingPair(scheduleMapping, \"interval\")?.value\n )?.trim();\n const cronjobPair = getMappingPair(\n scheduleMapping,\n \"cronjob\"\n );\n const cronjobValueNode = cronjobPair?.value ?? null;\n const cronjobValue =\n getScalarStringValue(cronjobValueNode)?.trim();\n\n if (intervalValue === \"cron\") {\n if (\n cronjobValue !== undefined &&\n cronjobValue !== null &&\n cronjobValue.length > 0\n ) {\n continue;\n }\n\n context.report({\n data: {\n updateLabel: getDependabotUpdateLabel(update),\n },\n messageId: \"missingCronjob\",\n node: (cronjobValueNode ??\n cronjobPair ??\n update.node) as unknown as Rule.Node,\n });\n\n continue;\n }\n\n if (\n cronjobValue === undefined ||\n cronjobValue === null ||\n cronjobValue.length === 0\n ) {\n continue;\n }\n\n context.report({\n data: {\n intervalValue: intervalValue ?? \"(missing)\",\n updateLabel: getDependabotUpdateLabel(update),\n },\n messageId: \"unexpectedCronjob\",\n node: (cronjobValueNode ??\n cronjobPair ??\n update.node) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.dependabot\",\n ],\n description:\n \"require Dependabot `schedule.cronjob` for `interval: cron` and disallow it for non-cron intervals.\",\n dialects: [\"Dependabot configuration\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R083\",\n ruleNumber: 83,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependabot-schedule-cronjob\",\n },\n messages: {\n missingCronjob:\n \"{{updateLabel}} uses `schedule.interval: cron` and must define a non-empty `schedule.cronjob`.\",\n unexpectedCronjob:\n \"{{updateLabel}} defines `schedule.cronjob`, but `schedule.interval` is '{{intervalValue}}'. Use `cronjob` only with `interval: cron`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require every Dependabot update entry to define an effective `schedule.interval`.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getDependabotRoot,\n getDependabotUpdateEntries,\n getDependabotUpdateLabel,\n getEffectiveDependabotUpdateMapping,\n} from \"../_internal/dependabot-yaml.js\";\nimport {\n getMappingPair,\n getScalarStringValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Valid schedule interval values documented by GitHub. */\nconst validDependabotIntervals = new Set([\n \"cron\",\n \"daily\",\n \"monthly\",\n \"quarterly\",\n \"semiannually\",\n \"weekly\",\n \"yearly\",\n]);\n\n/** Rule implementation for requiring effective `schedule.interval`. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getDependabotRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const update of getDependabotUpdateEntries(root)) {\n const scheduleMapping = getEffectiveDependabotUpdateMapping(\n root,\n update,\n \"schedule\"\n );\n const intervalPair =\n scheduleMapping === null\n ? null\n : getMappingPair(scheduleMapping, \"interval\");\n const intervalValue = getScalarStringValue(\n intervalPair?.value\n )?.trim();\n\n if (\n intervalValue !== undefined &&\n intervalValue !== null &&\n validDependabotIntervals.has(intervalValue)\n ) {\n continue;\n }\n\n context.report({\n data: {\n updateLabel: getDependabotUpdateLabel(update),\n },\n messageId:\n intervalPair === null\n ? \"missingScheduleInterval\"\n : \"invalidScheduleInterval\",\n node: (intervalPair?.value ??\n intervalPair ??\n update.node) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.dependabot\",\n ],\n description:\n \"require every Dependabot update entry to define a valid effective `schedule.interval`.\",\n dialects: [\"Dependabot configuration\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R074\",\n ruleNumber: 74,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependabot-schedule-interval\",\n },\n messages: {\n invalidScheduleInterval:\n \"{{updateLabel}} must use a supported `schedule.interval` value such as `daily`, `weekly`, `monthly`, or `cron`.\",\n missingScheduleInterval:\n \"{{updateLabel}} must define an effective `schedule.interval` (directly or via its `multi-ecosystem-group`).\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require non-cron Dependabot schedules to declare an explicit `schedule.time`.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getDependabotRoot,\n getDependabotUpdateEntries,\n getDependabotUpdateLabel,\n getEffectiveDependabotUpdateMapping,\n} from \"../_internal/dependabot-yaml.js\";\nimport {\n getMappingPair,\n getScalarStringValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring `schedule.time` on non-cron schedules. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getDependabotRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const update of getDependabotUpdateEntries(root)) {\n const scheduleMapping = getEffectiveDependabotUpdateMapping(\n root,\n update,\n \"schedule\"\n );\n\n if (scheduleMapping === null) {\n continue;\n }\n\n const intervalValue = getScalarStringValue(\n getMappingPair(scheduleMapping, \"interval\")?.value\n )?.trim();\n\n if (intervalValue === undefined || intervalValue === null) {\n continue;\n }\n\n if (intervalValue === \"cron\") {\n continue;\n }\n\n const timePair = getMappingPair(scheduleMapping, \"time\");\n const timeValue = getScalarStringValue(\n timePair?.value\n )?.trim();\n\n if (\n timeValue !== undefined &&\n timeValue !== null &&\n timeValue.length > 0\n ) {\n continue;\n }\n\n context.report({\n data: {\n updateLabel: getDependabotUpdateLabel(update),\n },\n messageId: \"missingScheduleTime\",\n node: (timePair?.value ??\n timePair ??\n update.node) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.dependabot\",\n ],\n description:\n \"require non-cron Dependabot schedules to declare an explicit `schedule.time`.\",\n dialects: [\"Dependabot configuration\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R075\",\n ruleNumber: 75,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependabot-schedule-time\",\n },\n messages: {\n missingScheduleTime:\n \"{{updateLabel}} should declare an explicit `schedule.time` for predictable Dependabot update runs.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require explicit `schedule.timezone` when Dependabot uses `time` or `cron` scheduling.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getDependabotRoot,\n getDependabotUpdateEntries,\n getDependabotUpdateLabel,\n getEffectiveDependabotUpdateMapping,\n} from \"../_internal/dependabot-yaml.js\";\nimport {\n getMappingPair,\n getScalarStringValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring explicit schedule timezones. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getDependabotRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const update of getDependabotUpdateEntries(root)) {\n const scheduleMapping = getEffectiveDependabotUpdateMapping(\n root,\n update,\n \"schedule\"\n );\n\n if (scheduleMapping === null) {\n continue;\n }\n\n const intervalValue = getScalarStringValue(\n getMappingPair(scheduleMapping, \"interval\")?.value\n )?.trim();\n const timeValue = getScalarStringValue(\n getMappingPair(scheduleMapping, \"time\")?.value\n )?.trim();\n\n if (\n intervalValue !== \"cron\" &&\n (timeValue === undefined ||\n timeValue === null ||\n timeValue.length === 0)\n ) {\n continue;\n }\n\n const timezonePair = getMappingPair(\n scheduleMapping,\n \"timezone\"\n );\n const timezoneValue = getScalarStringValue(\n timezonePair?.value\n )?.trim();\n\n if (\n timezoneValue !== undefined &&\n timezoneValue !== null &&\n timezoneValue.length > 0\n ) {\n continue;\n }\n\n context.report({\n data: {\n updateLabel: getDependabotUpdateLabel(update),\n },\n messageId: \"missingScheduleTimezone\",\n node: (timezonePair?.value ??\n timezonePair ??\n update.node) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.dependabot\",\n ],\n description:\n \"require explicit `schedule.timezone` when Dependabot schedules use `time` or `cron` semantics.\",\n dialects: [\"Dependabot configuration\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R076\",\n ruleNumber: 76,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependabot-schedule-timezone\",\n },\n messages: {\n missingScheduleTimezone:\n \"{{updateLabel}} should declare `schedule.timezone` so Dependabot runs at the intended local time.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require Dependabot update entries to define an effective target branch.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getDependabotRoot,\n getDependabotUpdateEntries,\n getDependabotUpdateLabel,\n getEffectiveDependabotStringValue,\n getEffectiveDependabotUpdateValue,\n} from \"../_internal/dependabot-yaml.js\";\n\n/** Rule implementation for requiring effective target branches. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getDependabotRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const update of getDependabotUpdateEntries(root)) {\n const targetBranchValue = getEffectiveDependabotUpdateValue(\n root,\n update,\n \"target-branch\"\n );\n const targetBranch = getEffectiveDependabotStringValue(\n root,\n update,\n \"target-branch\"\n );\n\n if (targetBranch !== null) {\n continue;\n }\n\n context.report({\n data: {\n updateLabel: getDependabotUpdateLabel(update),\n },\n messageId: \"missingTargetBranch\",\n node: (targetBranchValue ??\n update.node) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.dependabot\",\n ],\n description:\n \"require Dependabot update entries to define an effective `target-branch` directly or via a multi-ecosystem group.\",\n dialects: [\"Dependabot configuration\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R078\",\n ruleNumber: 78,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependabot-target-branch\",\n },\n messages: {\n missingTargetBranch:\n \"{{updateLabel}} should define `target-branch` so Dependabot pull requests land on the intended maintenance branch.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require a non-empty top-level `updates` sequence in Dependabot configuration files.\n */\nimport type { Rule } from \"eslint\";\n\nimport { getDependabotRoot } from \"../_internal/dependabot-yaml.js\";\nimport {\n getMappingPair,\n getMappingValueAsSequence,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring a non-empty `updates` sequence. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n const root = getDependabotRoot(context);\n\n if (root === null) {\n return;\n }\n\n const updatesPair = getMappingPair(root, \"updates\");\n const updatesSequence = getMappingValueAsSequence(\n root,\n \"updates\"\n );\n\n if (\n updatesSequence !== null &&\n updatesSequence.entries.length > 0\n ) {\n return;\n }\n\n context.report({\n messageId:\n updatesPair === null\n ? \"missingDependabotUpdates\"\n : \"emptyDependabotUpdates\",\n node: (updatesPair?.value ??\n updatesPair ??\n node) as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.dependabot\",\n ],\n description:\n \"require Dependabot configuration files to define a non-empty top-level `updates` sequence.\",\n dialects: [\"Dependabot configuration\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R071\",\n ruleNumber: 71,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependabot-updates\",\n },\n messages: {\n emptyDependabotUpdates:\n \"Dependabot configuration must define at least one entry under the top-level `updates` sequence.\",\n missingDependabotUpdates:\n \"Dependabot configuration is missing the required top-level `updates` sequence.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require `version: 2` in Dependabot configuration files.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getDependabotMappingStringValue,\n getDependabotRoot,\n} from \"../_internal/dependabot-yaml.js\";\nimport { getMappingPair } from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring `version: 2` in Dependabot config. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n const root = getDependabotRoot(context);\n\n if (root === null) {\n return;\n }\n\n const versionPair = getMappingPair(root, \"version\");\n const versionValue = getDependabotMappingStringValue(\n root,\n \"version\"\n );\n\n if (versionValue === \"2\") {\n return;\n }\n\n context.report({\n fix: (fixer) => {\n if (versionPair === null) {\n return fixer.insertTextBeforeRange(\n [root.range[0], root.range[0]],\n \"version: 2\\n\"\n );\n }\n\n return versionPair.value === null\n ? fixer.replaceTextRange(\n versionPair.range,\n \"version: 2\"\n )\n : fixer.replaceTextRange(\n versionPair.value.range,\n \"2\"\n );\n },\n messageId:\n versionPair === null\n ? \"missingDependabotVersion\"\n : \"invalidDependabotVersion\",\n node: (versionPair?.value ??\n versionPair ??\n node) as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.dependabot\",\n ],\n description:\n \"require Dependabot configuration files to declare `version: 2`.\",\n dialects: [\"Dependabot configuration\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R070\",\n ruleNumber: 70,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependabot-version\",\n },\n fixable: \"code\",\n messages: {\n invalidDependabotVersion:\n \"Dependabot configuration must declare `version: 2`.\",\n missingDependabotVersion:\n \"Dependabot configuration is missing the required top-level `version: 2` key.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require npm Dependabot update entries to define versioning strategy.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getDependabotMappingStringValue,\n getDependabotRoot,\n getDependabotUpdateEntries,\n getDependabotUpdateLabel,\n} from \"../_internal/dependabot-yaml.js\";\nimport { getMappingPair } from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for npm versioning strategy requirements. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getDependabotRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const update of getDependabotUpdateEntries(root)) {\n if (update.packageEcosystem?.trim() !== \"npm\") {\n continue;\n }\n\n const strategyPair = getMappingPair(\n update.mapping,\n \"versioning-strategy\"\n );\n const strategyValue = getDependabotMappingStringValue(\n update.mapping,\n \"versioning-strategy\"\n );\n\n if (strategyValue !== null) {\n continue;\n }\n\n context.report({\n data: {\n updateLabel: getDependabotUpdateLabel(update),\n },\n messageId: \"missingVersioningStrategy\",\n node: (strategyPair?.value ??\n strategyPair ??\n update.node) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.dependabot\",\n ],\n description:\n \"require npm Dependabot update entries to define `versioning-strategy`.\",\n dialects: [\"Dependabot configuration\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R088\",\n ruleNumber: 88,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependabot-versioning-strategy-for-npm\",\n },\n messages: {\n missingVersioningStrategy:\n \"{{updateLabel}} should define `versioning-strategy` so npm dependency range updates follow an explicit policy.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Helpers for workflows that use `actions/dependency-review-action`.\n */\n/* eslint-disable @typescript-eslint/prefer-readonly-parameter-types -- YAML AST nodes come from parser-owned mutable types shared across helper boundaries. */\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport type { WorkflowJobEntry } from \"./workflow-yaml.js\";\n\nimport { getWorkflowActionSteps } from \"./workflow-action-steps.js\";\n\n/** Workflow step using the dependency review action. */\nexport type DependencyReviewActionStep = {\n readonly job: WorkflowJobEntry;\n readonly stepMapping: AST.YAMLMapping;\n readonly usesPair: AST.YAMLPair;\n readonly usesReference: string;\n};\n\n/** Determine whether a `uses` reference points to the dependency review action. */\nexport const isDependencyReviewActionReference = (\n usesReference: string\n): boolean =>\n usesReference.trim().startsWith(\"actions/dependency-review-action@\");\n\n/** Collect all workflow steps that use the dependency review action. */\nexport const getDependencyReviewActionSteps = (\n root: AST.YAMLMapping\n): readonly DependencyReviewActionStep[] =>\n getWorkflowActionSteps(root, isDependencyReviewActionReference);\n\n/** Determine whether a workflow uses the dependency review action anywhere. */\nexport const hasDependencyReviewAction = (root: AST.YAMLMapping): boolean =>\n getDependencyReviewActionSteps(root).length > 0;\n\n/* eslint-enable @typescript-eslint/prefer-readonly-parameter-types -- Re-enable readonly-parameter checks outside parser AST helper signatures. */\n", "/**\n * @packageDocumentation\n * Require dependency-review workflow files to invoke actions/dependency-review-action.\n */\nimport type { Rule } from \"eslint\";\n\nimport { getDependencyReviewActionSteps } from \"../_internal/dependency-review-workflow.ts\";\nimport { isDependencyReviewWorkflowFile } from \"../_internal/lint-targets.js\";\nimport { getWorkflowRoot } from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring dependency review action usage. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!isDependencyReviewWorkflowFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n if (getDependencyReviewActionSteps(root).length > 0) {\n return;\n }\n\n context.report({\n messageId: \"missingDependencyReviewAction\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.codeScanning\",\n \"github-actions.configs.security\",\n ],\n description:\n \"require dependency-review workflow files to invoke `actions/dependency-review-action`.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R091\",\n ruleNumber: 91,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependency-review-action\",\n },\n messages: {\n missingDependencyReviewAction:\n \"Dependency review workflow files should invoke `actions/dependency-review-action` in at least one job step.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require actions/dependency-review-action steps to configure fail-on-severity.\n */\nimport type { Rule } from \"eslint\";\n\nimport { getDependencyReviewActionSteps } from \"../_internal/dependency-review-workflow.ts\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for dependency-review fail-on-severity requirements. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const step of getDependencyReviewActionSteps(root)) {\n const withMapping = getMappingValueAsMapping(\n step.stepMapping,\n \"with\"\n );\n const failOnSeverityPair =\n withMapping === null\n ? null\n : getMappingPair(withMapping, \"fail-on-severity\");\n const failOnSeverityValue = getScalarStringValue(\n failOnSeverityPair?.value ?? null\n )?.trim();\n\n if (\n failOnSeverityValue !== undefined &&\n failOnSeverityValue !== null &&\n failOnSeverityValue.length > 0\n ) {\n continue;\n }\n\n context.report({\n data: {\n jobId: step.job.id,\n },\n messageId: \"missingFailOnSeverity\",\n node: (failOnSeverityPair?.value ??\n failOnSeverityPair ??\n withMapping ??\n step.usesPair) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.codeScanning\",\n \"github-actions.configs.security\",\n ],\n description:\n \"require `actions/dependency-review-action` steps to set `with.fail-on-severity`.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R093\",\n ruleNumber: 93,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependency-review-fail-on-severity\",\n },\n messages: {\n missingFailOnSeverity:\n \"Dependency review action steps in job '{{jobId}}' should set `with.fail-on-severity` so vulnerability blocking policy is explicit.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require workflows using actions/dependency-review-action to set permissions.contents to read.\n */\nimport type { Rule } from \"eslint\";\n\nimport { hasDependencyReviewAction } from \"../_internal/dependency-review-workflow.ts\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for dependency-review contents permission requirements. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null || !hasDependencyReviewAction(root)) {\n return;\n }\n\n const permissionsMapping = getMappingValueAsMapping(\n root,\n \"permissions\"\n );\n const contentsPair =\n permissionsMapping === null\n ? null\n : getMappingPair(permissionsMapping, \"contents\");\n const contentsValue = getScalarStringValue(\n contentsPair?.value ?? null\n )?.trim();\n\n if (contentsValue === \"read\") {\n return;\n }\n\n context.report({\n messageId: \"missingContentsReadPermission\",\n node: (contentsPair?.value ??\n contentsPair ??\n permissionsMapping ??\n root) as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.codeScanning\",\n \"github-actions.configs.security\",\n ],\n description:\n \"require workflows using `actions/dependency-review-action` to set top-level `permissions.contents: read`.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R092\",\n ruleNumber: 92,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependency-review-permissions-contents-read\",\n },\n messages: {\n missingContentsReadPermission:\n \"Workflows using `actions/dependency-review-action` should set top-level `permissions.contents: read`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require workflows using actions/dependency-review-action to run on pull_request.\n */\nimport type { Rule } from \"eslint\";\n\nimport { hasDependencyReviewAction } from \"../_internal/dependency-review-workflow.ts\";\nimport {\n getWorkflowEventNames,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for dependency review pull_request trigger requirements. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null || !hasDependencyReviewAction(root)) {\n return;\n }\n\n if (getWorkflowEventNames(root).has(\"pull_request\")) {\n return;\n }\n\n context.report({\n messageId: \"missingPullRequestTrigger\",\n node: root as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.codeScanning\",\n \"github-actions.configs.security\",\n ],\n description:\n \"require workflows using `actions/dependency-review-action` to listen for `pull_request`.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R094\",\n ruleNumber: 94,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-dependency-review-pull-request-trigger\",\n },\n messages: {\n missingPullRequestTrigger:\n \"Workflows using `actions/dependency-review-action` should listen for `pull_request` so dependency review runs on pull request changes.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require dependabot/fetch-metadata steps to provide github-token.\n */\nimport type { Rule } from \"eslint\";\n\nimport { getDependabotFetchMetadataSteps } from \"../_internal/dependabot-automation-workflow.ts\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for fetch-metadata github-token requirements. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const step of getDependabotFetchMetadataSteps(root)) {\n const withMapping = getMappingValueAsMapping(\n step.stepMapping,\n \"with\"\n );\n const tokenPair =\n withMapping === null\n ? null\n : getMappingPair(withMapping, \"github-token\");\n const tokenValue = getScalarStringValue(\n tokenPair?.value ?? null\n )?.trim();\n\n if (tokenValue !== undefined && tokenValue.length > 0) {\n continue;\n }\n\n context.report({\n data: { jobId: step.job.id },\n messageId: \"missingGithubToken\",\n node: (tokenPair?.value ??\n tokenPair ??\n withMapping ??\n step.usesPair) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.security\",\n ],\n description:\n \"require `dependabot/fetch-metadata` steps to configure `with.github-token`.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R110\",\n ruleNumber: 110,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-fetch-metadata-github-token\",\n },\n messages: {\n missingGithubToken:\n \"`dependabot/fetch-metadata` step in job '{{jobId}}' should configure `with.github-token`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require every GitHub Actions job to declare a string name.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\nimport {\n getIndexAfterLine,\n getLineIndentation,\n} from \"../_internal/yaml-fixes.js\";\n\n/** Rule implementation for requiring explicit job names. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const jobsMapping = getMappingValueAsMapping(root, \"jobs\");\n\n if (jobsMapping === null) {\n return;\n }\n\n for (const pair of jobsMapping.pairs) {\n const jobKeyNode = pair.key;\n const jobId = getScalarStringValue(pair.key) ?? \"<unknown>\";\n const jobValue = unwrapYamlValue(pair.value);\n\n if (jobValue?.type !== \"YAMLMapping\") {\n context.report({\n data: { jobId },\n messageId: \"missingJobName\",\n node: (pair.value ?? pair) as unknown as Rule.Node,\n });\n\n continue;\n }\n\n const namePair = getMappingPair(jobValue, \"name\");\n\n if (namePair === null) {\n context.report({\n data: { jobId },\n messageId: \"missingJobName\",\n node: pair.key as AST.YAMLNode as unknown as Rule.Node,\n suggest:\n jobId === \"<unknown>\" || jobKeyNode === null\n ? undefined\n : [\n {\n data: { jobId },\n fix: (fixer) => {\n const insertionIndex =\n getIndexAfterLine(\n context.sourceCode\n .text,\n jobKeyNode.range[1]\n );\n const childIndentation = `${getLineIndentation(\n context.sourceCode.text,\n jobKeyNode.range[0]\n )} `;\n\n return fixer.insertTextBeforeRange(\n [\n insertionIndex,\n insertionIndex,\n ],\n `${childIndentation}name: ${JSON.stringify(jobId)}\\n`\n );\n },\n messageId:\n \"insertJobNameSuggestion\",\n },\n ],\n });\n\n continue;\n }\n\n const nameValue = getScalarStringValue(namePair.value);\n const nameValueNode = namePair.value;\n\n if (nameValue === null || nameValue.trim().length === 0) {\n context.report({\n data: { jobId },\n messageId: \"invalidJobName\",\n node: (namePair.value ??\n namePair) as unknown as Rule.Node,\n suggest:\n jobId === \"<unknown>\" || nameValueNode === null\n ? undefined\n : [\n {\n data: { jobId },\n fix: (fixer) =>\n fixer.replaceTextRange(\n nameValueNode.range,\n JSON.stringify(jobId)\n ),\n messageId:\n \"replaceJobNameSuggestion\",\n },\n ],\n });\n }\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require every workflow job to declare a non-empty string `name` for readable run summaries.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R007\",\n ruleNumber: 7,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-job-name\",\n },\n hasSuggestions: true,\n messages: {\n insertJobNameSuggestion: \"Insert `name: {{jobId}}` for this job.\",\n invalidJobName:\n \"Job '{{jobId}}' must set `name` to a non-empty string.\",\n missingJobName:\n \"Job '{{jobId}}' is missing a human-readable `name`.\",\n replaceJobNameSuggestion:\n \"Replace the blank job name with `{{jobId}}`.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require every workflow step to declare a string name.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\nimport {\n getIndexAfterLine,\n getLineIndentation,\n} from \"../_internal/yaml-fixes.js\";\n\n/** Maximum suggested step-name length derived from a run command. */\nconst MAX_SUGGESTED_STEP_NAME_LENGTH = 60;\n\n/** Derive a suggestion label from a step's `uses` or `run` content. */\nconst getSuggestedStepName = (\n stepMapping: Readonly<ReturnType<typeof unwrapYamlValue>>\n): string | undefined => {\n if (stepMapping?.type !== \"YAMLMapping\") {\n return undefined;\n }\n\n const usesReference = getScalarStringValue(\n getMappingPair(stepMapping, \"uses\")?.value\n )?.trim();\n\n if (usesReference !== undefined && usesReference.length > 0) {\n const atSignIndex = usesReference.lastIndexOf(\"@\");\n\n return atSignIndex === -1\n ? usesReference\n : usesReference.slice(0, atSignIndex);\n }\n\n const runScript = getScalarStringValue(\n getMappingPair(stepMapping, \"run\")?.value\n );\n\n if (runScript === null) {\n return undefined;\n }\n\n const firstNonEmptyLine = runScript\n .split(/\\r?\\n/u)\n .map((line) => line.trim())\n .find((line) => line.length > 0);\n\n return firstNonEmptyLine === undefined ||\n firstNonEmptyLine.length > MAX_SUGGESTED_STEP_NAME_LENGTH\n ? undefined\n : firstNonEmptyLine;\n};\n\n/** Rule implementation for requiring explicit job step names. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n const stepsSequence = getMappingValueAsSequence(\n job.mapping,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n continue;\n }\n\n for (const entry of stepsSequence.entries) {\n const stepMapping = unwrapYamlValue(entry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const suggestedStepName =\n getSuggestedStepName(stepMapping);\n\n const namePair = getMappingPair(stepMapping, \"name\");\n\n if (namePair === null) {\n const firstStepPair = stepMapping.pairs[0];\n const firstStepKeyNode = firstStepPair?.key;\n\n context.report({\n data: {\n jobId: job.id,\n },\n messageId: \"missingStepName\",\n node: stepMapping as unknown as Rule.Node,\n suggest:\n suggestedStepName === undefined ||\n firstStepKeyNode === null ||\n firstStepKeyNode === undefined\n ? undefined\n : [\n {\n data: {\n jobId: job.id,\n suggestedStepName,\n },\n fix: (fixer) => {\n const insertionIndex =\n getIndexAfterLine(\n context.sourceCode\n .text,\n firstStepKeyNode\n .range[1]\n );\n const childIndentation = `${getLineIndentation(\n context.sourceCode\n .text,\n firstStepKeyNode\n .range[0]\n )} `;\n\n return fixer.insertTextBeforeRange(\n [\n insertionIndex,\n insertionIndex,\n ],\n `${childIndentation}name: ${JSON.stringify(suggestedStepName)}\\n`\n );\n },\n messageId:\n \"insertStepNameSuggestion\",\n },\n ],\n });\n\n continue;\n }\n\n const nameValue = getScalarStringValue(namePair.value);\n\n if (\n nameValue === null ||\n nameValue.trim().length === 0\n ) {\n const nameValueNode = namePair.value;\n\n context.report({\n data: {\n jobId: job.id,\n },\n messageId: \"invalidStepName\",\n node: (namePair.value ??\n namePair) as unknown as Rule.Node,\n suggest:\n suggestedStepName === undefined ||\n nameValueNode === null\n ? undefined\n : [\n {\n data: {\n jobId: job.id,\n suggestedStepName,\n },\n fix: (fixer) =>\n fixer.replaceTextRange(\n nameValueNode.range,\n JSON.stringify(\n suggestedStepName\n )\n ),\n messageId:\n \"replaceStepNameSuggestion\",\n },\n ],\n });\n }\n }\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require every workflow step to declare a non-empty string `name` so job logs remain readable.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R008\",\n ruleNumber: 8,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-job-step-name\",\n },\n hasSuggestions: true,\n messages: {\n insertStepNameSuggestion:\n \"Insert `name: {{suggestedStepName}}` for this step in job '{{jobId}}'.\",\n invalidStepName:\n \"A step in job '{{jobId}}' must set `name` to a non-empty string.\",\n missingStepName:\n \"A step in job '{{jobId}}' is missing a human-readable `name`.\",\n replaceStepNameSuggestion:\n \"Replace the blank step name with `{{suggestedStepName}}` in job '{{jobId}}'.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require bounded job timeouts for GitHub Actions jobs.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getScalarNumberValue,\n getWorkflowJobs,\n getWorkflowRoot,\n isGithubExpressionScalar,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule options for `require-job-timeout-minutes`. */\ntype RequireJobTimeoutMinutesOptions = [\n {\n readonly maxMinutes?: number;\n }?,\n];\n\n/** Default upper bound used when validating workflow job timeouts. */\nconst DEFAULT_MAX_MINUTES = 60;\n\n/** Rule implementation for requiring bounded timeout-minutes on workflow jobs. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const [options] = context.options as RequireJobTimeoutMinutesOptions;\n const maxMinutes = options?.maxMinutes ?? DEFAULT_MAX_MINUTES;\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const job of getWorkflowJobs(root)) {\n if (getMappingPair(job.mapping, \"uses\") !== null) {\n continue;\n }\n\n const timeoutPair = getMappingPair(\n job.mapping,\n \"timeout-minutes\"\n );\n\n if (timeoutPair === null) {\n context.report({\n data: {\n jobId: job.id,\n },\n messageId: \"missingTimeout\",\n node: job.idNode,\n });\n\n continue;\n }\n\n if (isGithubExpressionScalar(timeoutPair.value)) {\n continue;\n }\n\n const timeoutMinutes = getScalarNumberValue(\n timeoutPair.value\n );\n\n if (\n timeoutMinutes === null ||\n !Number.isInteger(timeoutMinutes) ||\n timeoutMinutes <= 0\n ) {\n context.report({\n data: {\n jobId: job.id,\n },\n messageId: \"invalidTimeout\",\n node: timeoutPair.value ?? timeoutPair,\n });\n\n continue;\n }\n\n if (timeoutMinutes > maxMinutes) {\n context.report({\n data: {\n actualMinutes: String(timeoutMinutes),\n jobId: job.id,\n maxMinutes: String(maxMinutes),\n },\n messageId: \"timeoutTooLarge\",\n node: timeoutPair.value ?? timeoutPair,\n });\n }\n }\n },\n };\n },\n meta: {\n defaultOptions: [{}],\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require every non-reusable workflow job to define a bounded `timeout-minutes` value.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R002\",\n ruleNumber: 2,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-job-timeout-minutes\",\n },\n messages: {\n invalidTimeout:\n \"Job '{{jobId}}' has an invalid `timeout-minutes` value. Use a positive integer or a GitHub expression.\",\n missingTimeout:\n \"Job '{{jobId}}' is missing `timeout-minutes`. Add an explicit timeout to prevent hung runners from waiting indefinitely.\",\n timeoutTooLarge:\n \"Job '{{jobId}}' sets `timeout-minutes` to {{actualMinutes}}, which exceeds the configured maximum of {{maxMinutes}}.\",\n },\n schema: [\n {\n additionalProperties: false,\n description:\n \"Optional configuration for the maximum allowed job timeout in minutes.\",\n properties: {\n maxMinutes: {\n description:\n \"Maximum allowed timeout-minutes value for a non-reusable workflow job.\",\n minimum: 1,\n type: \"integer\",\n },\n },\n type: \"object\",\n },\n ],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require merge-queue-aware workflows to listen for merge_group.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Determine whether the workflow declares a specific trigger event. */\nconst hasTriggerEvent = (\n root: Readonly<AST.YAMLMapping>,\n eventName: string\n): boolean => {\n const onPair = getMappingPair(root, \"on\");\n const onValue = unwrapYamlValue(onPair?.value ?? null);\n\n if (onValue === null) {\n return false;\n }\n\n if (onValue.type === \"YAMLScalar\") {\n return getScalarStringValue(onValue) === eventName;\n }\n\n if (onValue.type === \"YAMLSequence\") {\n return onValue.entries.some(\n (entry) =>\n entry !== null && getScalarStringValue(entry) === eventName\n );\n }\n\n if (onValue.type !== \"YAMLMapping\") {\n return false;\n }\n\n return getMappingPair(onValue, eventName) !== null;\n};\n\n/** Rule implementation for requiring merge_group triggers. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null || !hasTriggerEvent(root, \"pull_request\")) {\n return;\n }\n\n if (hasTriggerEvent(root, \"merge_group\")) {\n return;\n }\n\n const onPair = getMappingPair(root, \"on\");\n const onValue = unwrapYamlValue(onPair?.value ?? null);\n\n if (onValue === null) {\n return;\n }\n\n context.report({\n messageId: \"missingMergeGroup\",\n node: onValue as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require pull-request validation workflows to include the `merge_group` trigger so required checks also run for merge queues.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R035\",\n ruleNumber: 35,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-merge-group-trigger\",\n },\n messages: {\n missingMergeGroup:\n \"Workflows that validate pull requests should also listen to `merge_group` so required status checks are reported when pull requests enter a merge queue.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require base-branch scoping for `pull_request_target` triggers.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Determine whether a branch filter node is meaningfully configured. */\nconst hasConfiguredBranchFilter = (\n node: null | Readonly<AST.YAMLPair> | undefined\n): boolean => {\n const valueNode = unwrapYamlValue(node?.value ?? null);\n\n if (valueNode === null) {\n return false;\n }\n\n if (valueNode.type === \"YAMLScalar\") {\n const value = getScalarStringValue(valueNode);\n\n return value !== null && value.trim().length > 0;\n }\n\n if (valueNode.type !== \"YAMLSequence\") {\n return false;\n }\n\n return valueNode.entries.some((entry) => {\n const value = getScalarStringValue(entry);\n\n return value !== null && value.trim().length > 0;\n });\n};\n\n/** Rule implementation for requiring `pull_request_target` branch filters. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const reportMissingBranchFilter = (\n node: Readonly<AST.YAMLNode>\n ): void => {\n context.report({\n messageId: \"missingBranchFilter\",\n node: node as unknown as Rule.Node,\n });\n };\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const onPair = getMappingPair(root, \"on\");\n const onValue = unwrapYamlValue(onPair?.value ?? null);\n\n if (onValue === null) {\n return;\n }\n\n if (onValue.type === \"YAMLScalar\") {\n if (\n getScalarStringValue(onValue) === \"pull_request_target\"\n ) {\n reportMissingBranchFilter(onValue);\n }\n\n return;\n }\n\n if (onValue.type === \"YAMLSequence\") {\n for (const entry of onValue.entries) {\n if (\n entry !== null &&\n getScalarStringValue(entry) ===\n \"pull_request_target\"\n ) {\n reportMissingBranchFilter(entry);\n }\n }\n\n return;\n }\n\n const onMapping = getMappingValueAsMapping(root, \"on\");\n\n if (onMapping === null) {\n return;\n }\n\n const pullRequestTargetPair = getMappingPair(\n onMapping,\n \"pull_request_target\"\n );\n const pullRequestTargetValue = unwrapYamlValue(\n pullRequestTargetPair?.value ?? null\n );\n\n if (pullRequestTargetPair === null) {\n return;\n }\n\n if (pullRequestTargetValue?.type !== \"YAMLMapping\") {\n reportMissingBranchFilter(\n (pullRequestTargetPair.value ??\n pullRequestTargetPair) as AST.YAMLNode\n );\n\n return;\n }\n\n const branchesPair = getMappingPair(\n pullRequestTargetValue,\n \"branches\"\n );\n const branchesIgnorePair = getMappingPair(\n pullRequestTargetValue,\n \"branches-ignore\"\n );\n\n if (\n hasConfiguredBranchFilter(branchesPair) ||\n hasConfiguredBranchFilter(branchesIgnorePair)\n ) {\n return;\n }\n\n reportMissingBranchFilter(pullRequestTargetValue);\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.security\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require `on.pull_request_target` triggers to scope target base branches with `branches` or `branches-ignore` so privileged workflows do not react to every branch by default.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R032\",\n ruleNumber: 32,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-pull-request-target-branches\",\n },\n messages: {\n missingBranchFilter:\n \"`on.pull_request_target` should declare a non-empty `branches` or `branches-ignore` filter to scope which base branches can trigger this privileged workflow.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require `run` steps to declare an explicit shell directly or through defaults.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getMappingValueAsSequence,\n getScalarStringValue,\n getWorkflowJobs,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Runtime status for a discovered shell declaration. */\ntype ShellDeclarationState = \"invalid\" | \"missing\" | \"valid\";\n\n/** Inspect a shell pair and determine whether it is usable. */\nconst getShellDeclarationState = (\n shellPair: null | Readonly<AST.YAMLPair>\n): ShellDeclarationState => {\n if (shellPair === null) {\n return \"missing\";\n }\n\n const shellValue = getScalarStringValue(shellPair.value);\n\n return shellValue !== null && shellValue.trim().length > 0\n ? \"valid\"\n : \"invalid\";\n};\n\n/** Resolve `defaults.run.shell` from a mapping when present. */\nconst getRunDefaultsShellPair = (\n mapping: Readonly<AST.YAMLMapping>\n): AST.YAMLPair | null => {\n const defaultsMapping = getMappingValueAsMapping(mapping, \"defaults\");\n\n if (defaultsMapping === null) {\n return null;\n }\n\n const runDefaultsMapping = getMappingValueAsMapping(defaultsMapping, \"run\");\n\n return runDefaultsMapping === null\n ? null\n : getMappingPair(runDefaultsMapping, \"shell\");\n};\n\n/** Rule implementation for requiring explicit shells on run steps. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const reportInvalidShell = (\n shellPair: Readonly<AST.YAMLPair>,\n scope: string\n ): void => {\n context.report({\n data: {\n scope,\n },\n messageId: \"invalidShell\",\n node: (shellPair.value ?? shellPair) as unknown as Rule.Node,\n });\n };\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const workflowShellPair = getRunDefaultsShellPair(root);\n const workflowShellState =\n getShellDeclarationState(workflowShellPair);\n\n if (\n workflowShellPair !== null &&\n workflowShellState === \"invalid\"\n ) {\n reportInvalidShell(\n workflowShellPair,\n \"workflow `defaults.run.shell`\"\n );\n }\n\n for (const job of getWorkflowJobs(root)) {\n const jobShellPair = getRunDefaultsShellPair(job.mapping);\n const jobShellState =\n getShellDeclarationState(jobShellPair);\n\n if (jobShellPair !== null && jobShellState === \"invalid\") {\n reportInvalidShell(\n jobShellPair,\n `job '${job.id}' defaults.run.shell`\n );\n }\n\n const stepsSequence = getMappingValueAsSequence(\n job.mapping,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n continue;\n }\n\n for (const entry of stepsSequence.entries) {\n const stepMapping = unwrapYamlValue(entry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const runPair = getMappingPair(stepMapping, \"run\");\n\n if (runPair === null) {\n continue;\n }\n\n const stepShellPair = getMappingPair(\n stepMapping,\n \"shell\"\n );\n const stepShellState =\n getShellDeclarationState(stepShellPair);\n\n if (stepShellPair !== null) {\n if (stepShellState === \"valid\") {\n continue;\n }\n\n reportInvalidShell(\n stepShellPair,\n `a run step in job '${job.id}'`\n );\n\n continue;\n }\n\n if (\n jobShellState !== \"missing\" ||\n workflowShellState !== \"missing\"\n ) {\n continue;\n }\n\n context.report({\n data: {\n jobId: job.id,\n },\n messageId: \"missingShell\",\n node: (runPair.value ??\n stepMapping) as unknown as Rule.Node,\n });\n }\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require `run` steps to use an explicit shell directly or through `defaults.run.shell` so execution behavior stays predictable across runners.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R021\",\n ruleNumber: 21,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-run-step-shell\",\n },\n messages: {\n invalidShell:\n \"{{scope}} must set `shell` to a non-empty string when declared.\",\n missingShell:\n \"A `run` step in job '{{jobId}}' should declare `shell` explicitly or inherit it from `defaults.run.shell`.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require workflows uploading SARIF to grant security-events write.\n */\nimport type { Rule } from \"eslint\";\n\nimport { getSarifUploadSteps } from \"../_internal/code-scanning-workflow.ts\";\nimport { hasRequiredWorkflowPermission } from \"../_internal/workflow-permissions.ts\";\nimport { getWorkflowRoot } from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for SARIF upload permission requirements. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const step of getSarifUploadSteps(root)) {\n if (\n hasRequiredWorkflowPermission(\n root,\n step.job,\n \"security-events\",\n \"write\"\n )\n ) {\n continue;\n }\n\n context.report({\n data: { jobId: step.job.id },\n messageId: \"missingSecurityEventsWrite\",\n node: step.job.idNode as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.codeScanning\",\n \"github-actions.configs.security\",\n ],\n description:\n \"require jobs uploading SARIF to GitHub code scanning to grant `security-events: write`.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R102\",\n ruleNumber: 102,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-sarif-upload-security-events-write\",\n },\n messages: {\n missingSecurityEventsWrite:\n \"Job '{{jobId}}' uploads SARIF results and should grant `security-events: write`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require Scorecard workflows to emit SARIF results.\n */\nimport type { Rule } from \"eslint\";\n\nimport { getScorecardSteps } from \"../_internal/code-scanning-workflow.ts\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring Scorecard SARIF output. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const step of getScorecardSteps(root)) {\n const withMapping = getMappingValueAsMapping(\n step.stepMapping,\n \"with\"\n );\n const formatPair =\n withMapping === null\n ? null\n : getMappingPair(withMapping, \"results_format\");\n const formatValue = getScalarStringValue(\n formatPair?.value ?? null\n )?.trim();\n\n if (formatValue === \"sarif\") {\n continue;\n }\n\n context.report({\n data: { jobId: step.job.id },\n messageId: \"missingSarifResultsFormat\",\n node: (formatPair?.value ??\n formatPair ??\n withMapping ??\n step.usesPair) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.codeScanning\",\n ],\n description:\n \"require `ossf/scorecard-action` steps to set `results_format: sarif`.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R103\",\n ruleNumber: 103,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-scorecard-results-format-sarif\",\n },\n messages: {\n missingSarifResultsFormat:\n \"Scorecard step in job '{{jobId}}' should set `results_format: sarif`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require Scorecard workflows producing SARIF to upload it with upload-sarif.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getSarifUploadSteps,\n getScorecardSteps,\n} from \"../_internal/code-scanning-workflow.ts\";\nimport { getWorkflowRoot } from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring SARIF upload in Scorecard workflows. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n const root = getWorkflowRoot(context);\n\n if (root === null || getScorecardSteps(root).length === 0) {\n return;\n }\n\n if (getSarifUploadSteps(root).length > 0) {\n return;\n }\n\n context.report({\n messageId: \"missingSarifUpload\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.codeScanning\",\n ],\n description:\n \"require workflows using `ossf/scorecard-action` to upload SARIF results to GitHub code scanning.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R104\",\n ruleNumber: 104,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-scorecard-upload-sarif-step\",\n },\n messages: {\n missingSarifUpload:\n \"Scorecard workflows producing SARIF should upload the result with `github/codeql-action/upload-sarif`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Helpers for secret-scanning workflows such as Gitleaks and TruffleHog.\n */\n/* eslint-disable @typescript-eslint/prefer-readonly-parameter-types -- YAML AST nodes come from parser-owned mutable types shared across helper boundaries. */\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport type { WorkflowActionStep } from \"./workflow-action-steps.js\";\n\nimport { getWorkflowActionSteps } from \"./workflow-action-steps.js\";\n\n/** Determine whether a `uses` reference points to the Gitleaks action. */\nexport const isGitleaksActionReference = (usesReference: string): boolean =>\n usesReference.trim().startsWith(\"gitleaks/gitleaks-action@\");\n\n/** Determine whether a `uses` reference points to the TruffleHog action. */\nexport const isTrufflehogActionReference = (usesReference: string): boolean =>\n usesReference.trim().startsWith(\"trufflesecurity/trufflehog@\");\n\n/**\n * Determine whether a `uses` reference points to a supported secret scanning\n * action.\n */\nexport const isSecretScanningActionReference = (\n usesReference: string\n): boolean =>\n isGitleaksActionReference(usesReference) ||\n isTrufflehogActionReference(usesReference);\n\n/** Collect all supported secret scanning action steps in a workflow. */\nexport const getSecretScanningActionSteps = (\n root: AST.YAMLMapping\n): readonly WorkflowActionStep[] =>\n getWorkflowActionSteps(root, isSecretScanningActionReference);\n\n/** Collect all Gitleaks action steps in a workflow. */\nexport const getGitleaksActionSteps = (\n root: AST.YAMLMapping\n): readonly WorkflowActionStep[] =>\n getWorkflowActionSteps(root, isGitleaksActionReference);\n\n/** Collect all TruffleHog action steps in a workflow. */\nexport const getTrufflehogActionSteps = (\n root: AST.YAMLMapping\n): readonly WorkflowActionStep[] =>\n getWorkflowActionSteps(root, isTrufflehogActionReference);\n\n/** Determine whether a workflow uses any supported secret scanning action. */\nexport const hasSecretScanningAction = (root: AST.YAMLMapping): boolean =>\n getSecretScanningActionSteps(root).length > 0;\n\n/* eslint-enable @typescript-eslint/prefer-readonly-parameter-types -- Re-enable readonly-parameter checks outside parser AST helper signatures. */\n", "/**\n * @packageDocumentation\n * Require secret scanning workflows to grant contents read permissions.\n */\nimport type { Rule } from \"eslint\";\n\nimport { getSecretScanningActionSteps } from \"../_internal/secret-scanning-workflow.ts\";\nimport { hasRequiredWorkflowPermission } from \"../_internal/workflow-permissions.ts\";\nimport { getWorkflowRoot } from \"../_internal/workflow-yaml.js\";\n\n/**\n * Rule implementation for secret-scanning contents read permission\n * requirements.\n */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const step of getSecretScanningActionSteps(root)) {\n if (\n hasRequiredWorkflowPermission(\n root,\n step.job,\n \"contents\",\n \"read\"\n )\n ) {\n continue;\n }\n\n context.report({\n data: { jobId: step.job.id },\n messageId: \"missingContentsRead\",\n node: step.job.idNode as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.security\",\n ],\n description:\n \"require secret scanning workflows to grant `contents: read`.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R107\",\n ruleNumber: 107,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-secret-scan-contents-read\",\n },\n messages: {\n missingContentsRead:\n \"Job '{{jobId}}' runs a secret scanner and should grant `contents: read`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require secret scanning workflows to checkout full history.\n */\nimport type { Rule } from \"eslint\";\n\nimport { getSecretScanningActionSteps } from \"../_internal/secret-scanning-workflow.ts\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getMappingValueAsSequence,\n getScalarNumberValue,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\nconst isCheckoutReference = (usesReference: string): boolean =>\n usesReference.trim().startsWith(\"actions/checkout@\");\n\n/** Rule implementation for fetch-depth zero requirements on secret scanners. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const scanStep of getSecretScanningActionSteps(root)) {\n const stepsSequence = getMappingValueAsSequence(\n scanStep.job.mapping,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n continue;\n }\n\n let hasCompliantCheckout = false;\n\n for (const entry of stepsSequence.entries) {\n const stepMapping = unwrapYamlValue(entry);\n\n if (stepMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const usesReference = getScalarStringValue(\n getMappingPair(stepMapping, \"uses\")?.value ?? null\n );\n\n if (\n usesReference === null ||\n !isCheckoutReference(usesReference)\n ) {\n continue;\n }\n\n const withMapping = getMappingValueAsMapping(\n stepMapping,\n \"with\"\n );\n const fetchDepthPair =\n withMapping === null\n ? null\n : getMappingPair(withMapping, \"fetch-depth\");\n const fetchDepthNumber = getScalarNumberValue(\n fetchDepthPair?.value ?? null\n );\n const fetchDepthString = getScalarStringValue(\n fetchDepthPair?.value ?? null\n )?.trim();\n\n if (\n fetchDepthNumber === 0 ||\n fetchDepthString === \"0\"\n ) {\n hasCompliantCheckout = true;\n break;\n }\n }\n\n if (hasCompliantCheckout) {\n continue;\n }\n\n context.report({\n data: { jobId: scanStep.job.id },\n messageId: \"missingFetchDepthZero\",\n node: scanStep.job.idNode as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.security\",\n ],\n description:\n \"require secret scanning workflows to checkout full history with `fetch-depth: 0`.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R105\",\n ruleNumber: 105,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-secret-scan-fetch-depth-zero\",\n },\n messages: {\n missingFetchDepthZero:\n \"Job '{{jobId}}' runs a secret scanner and should checkout repository history with `fetch-depth: 0`.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require secret scanning workflows to run on a schedule.\n */\nimport type { Rule } from \"eslint\";\n\nimport { hasSecretScanningAction } from \"../_internal/secret-scanning-workflow.ts\";\nimport {\n getWorkflowEventNames,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring scheduled secret scanning runs. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n const root = getWorkflowRoot(context);\n\n if (root === null || !hasSecretScanningAction(root)) {\n return;\n }\n\n if (getWorkflowEventNames(root).has(\"schedule\")) {\n return;\n }\n\n context.report({\n messageId: \"missingScheduleTrigger\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.security\",\n ],\n description:\n \"require secret scanning workflows to include a scheduled trigger.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R106\",\n ruleNumber: 106,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-secret-scan-schedule\",\n },\n messages: {\n missingScheduleTrigger:\n \"Secret scanning workflows should include a `schedule` trigger for periodic scanning.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require `categories` in workflow-template properties metadata.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowTemplatePropertiesFile } from \"../_internal/lint-targets.js\";\nimport {\n getWorkflowTemplatePropertiesRoot,\n getWorkflowTemplateStringProperty,\n} from \"../_internal/workflow-template-properties.js\";\nimport { getMappingValueAsSequence } from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring template categories. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowTemplatePropertiesRoot(context);\n\n if (root === null) {\n return;\n }\n\n const categoriesSequence = getMappingValueAsSequence(\n root,\n \"categories\"\n );\n\n if (\n categoriesSequence !== null &&\n categoriesSequence.entries.length > 0\n ) {\n return;\n }\n\n const templateName =\n getWorkflowTemplateStringProperty(root, \"name\") ??\n \"<unnamed-template>\";\n\n context.report({\n data: {\n templateName,\n },\n messageId: \"missingCategories\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"require non-empty `categories` in workflow-template metadata.\",\n dialects: [\"GitHub Actions workflow template metadata\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R057\",\n ruleNumber: 57,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-template-categories\",\n },\n messages: {\n missingCategories:\n \"Workflow template '{{templateName}}' should declare at least one category in `categories`.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require `filePatterns` in workflow-template properties metadata.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowTemplatePropertiesFile } from \"../_internal/lint-targets.js\";\nimport {\n getWorkflowTemplatePropertiesRoot,\n getWorkflowTemplateStringProperty,\n} from \"../_internal/workflow-template-properties.js\";\nimport { getMappingValueAsSequence } from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring non-empty template file patterns. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowTemplatePropertiesRoot(context);\n\n if (root === null) {\n return;\n }\n\n const filePatternsSequence = getMappingValueAsSequence(\n root,\n \"filePatterns\"\n );\n\n if (\n filePatternsSequence !== null &&\n filePatternsSequence.entries.length > 0\n ) {\n return;\n }\n\n const templateName =\n getWorkflowTemplateStringProperty(root, \"name\") ??\n \"<unnamed-template>\";\n\n context.report({\n data: {\n templateName,\n },\n messageId: \"missingFilePatterns\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"require non-empty `filePatterns` in workflow-template metadata.\",\n dialects: [\"GitHub Actions workflow template metadata\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R058\",\n ruleNumber: 58,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-template-file-patterns\",\n },\n messages: {\n missingFilePatterns:\n \"Workflow template '{{templateName}}' should declare `filePatterns` to improve chooser relevance.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require local workflow-template icon files referenced by `iconName` to exist.\n */\nimport type { Rule } from \"eslint\";\n\nimport { existsSync } from \"node:fs\";\nimport { dirname, join } from \"node:path\";\n\nimport { isWorkflowTemplatePropertiesFile } from \"../_internal/lint-targets.js\";\nimport {\n getWorkflowTemplatePropertiesRoot,\n getWorkflowTemplateStringProperty,\n} from \"../_internal/workflow-template-properties.js\";\n\n/** Rule implementation for template icon file existence checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowTemplatePropertiesRoot(context);\n\n if (root === null) {\n return;\n }\n\n const iconName = getWorkflowTemplateStringProperty(\n root,\n \"iconName\"\n );\n\n if (iconName === null || iconName.trim().length === 0) {\n return;\n }\n\n if (iconName.startsWith(\"octicon \")) {\n return;\n }\n\n const iconFilePath = join(\n dirname(context.filename),\n `${iconName}.svg`\n );\n\n if (existsSync(iconFilePath)) {\n return;\n }\n\n context.report({\n data: {\n iconFilePath,\n iconName,\n },\n messageId: \"missingTemplateIconFile\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"require local `iconName` references in workflow-template metadata to point to existing SVG files.\",\n dialects: [\"GitHub Actions workflow template metadata\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R065\",\n ruleNumber: 65,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-template-icon-file-exists\",\n },\n messages: {\n missingTemplateIconFile:\n \"Template `iconName` '{{iconName}}' should resolve to an existing icon file at '{{iconFilePath}}'.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require `iconName` in workflow-template properties.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowTemplatePropertiesFile } from \"../_internal/lint-targets.js\";\nimport {\n getWorkflowTemplatePropertiesRoot,\n getWorkflowTemplateStringProperty,\n} from \"../_internal/workflow-template-properties.js\";\n\n/** Rule implementation for requiring `iconName` in template properties metadata. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowTemplatePropertiesRoot(context);\n\n if (root === null) {\n return;\n }\n\n const iconName = getWorkflowTemplateStringProperty(\n root,\n \"iconName\"\n );\n\n if (iconName !== null && iconName.trim().length > 0) {\n return;\n }\n\n context.report({\n messageId: \"missingIconName\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"require `iconName` in workflow-template `.properties.json` metadata.\",\n dialects: [\"GitHub Actions workflow template metadata\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R056\",\n ruleNumber: 56,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-template-icon-name\",\n },\n messages: {\n missingIconName:\n \"Workflow template metadata should define a non-empty `iconName`.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require template workflow YAML files to declare a non-empty top-level `name`.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowTemplateYamlFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring workflow names in template YAML files. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!isWorkflowTemplateYamlFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const namePair = getMappingPair(root, \"name\");\n const workflowName = getScalarStringValue(namePair?.value);\n\n if (workflowName !== null && workflowName.trim().length > 0) {\n return;\n }\n\n context.report({\n messageId: \"missingTemplateWorkflowName\",\n node: (namePair ?? node) as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"require workflow template YAML files to declare a non-empty top-level `name`.\",\n dialects: [\"GitHub Actions workflow template\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R067\",\n ruleNumber: 67,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-template-workflow-name\",\n },\n messages: {\n missingTemplateWorkflowName:\n \"Workflow template files should declare a non-empty top-level `name`.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require explicit activity `types` for selected multi-activity workflow events.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Events where explicit `types` improve trigger precision. */\nconst eventsRequiringTypes = new Set<string>([\n \"branch_protection_rule\",\n \"check_run\",\n \"check_suite\",\n \"discussion\",\n \"discussion_comment\",\n \"issue_comment\",\n \"issues\",\n \"label\",\n \"merge_group\",\n \"milestone\",\n \"pull_request_review\",\n \"pull_request_review_comment\",\n \"registry_package\",\n \"release\",\n \"repository_dispatch\",\n \"watch\",\n \"workflow_run\",\n]);\n\n/** Determine whether an event `types` node is meaningfully configured. */\nconst hasConfiguredTypes = (\n node: null | Readonly<AST.YAMLPair> | undefined\n): boolean => {\n const valueNode = unwrapYamlValue(node?.value ?? null);\n\n if (valueNode === null) {\n return false;\n }\n\n if (valueNode.type === \"YAMLScalar\") {\n const value = getScalarStringValue(valueNode);\n\n return value !== null && value.trim().length > 0;\n }\n\n if (valueNode.type !== \"YAMLSequence\") {\n return false;\n }\n\n return valueNode.entries.some((entry) => {\n const value = getScalarStringValue(entry);\n\n return value !== null && value.trim().length > 0;\n });\n};\n\n/** Rule implementation for requiring explicit event activity types. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const reportMissingTypes = (\n node: Readonly<AST.YAMLNode>,\n eventName: string\n ): void => {\n context.report({\n data: {\n event: eventName,\n },\n messageId: \"missingTypes\",\n node: node as unknown as Rule.Node,\n });\n };\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const onPair = getMappingPair(root, \"on\");\n const onValue = unwrapYamlValue(onPair?.value ?? null);\n\n if (onValue === null) {\n return;\n }\n\n if (onValue.type === \"YAMLScalar\") {\n const eventName = getScalarStringValue(onValue);\n\n if (\n eventName !== null &&\n eventsRequiringTypes.has(eventName)\n ) {\n reportMissingTypes(onValue, eventName);\n }\n\n return;\n }\n\n if (onValue.type === \"YAMLSequence\") {\n for (const entry of onValue.entries) {\n const eventName = getScalarStringValue(entry);\n\n if (\n entry !== null &&\n eventName !== null &&\n eventsRequiringTypes.has(eventName)\n ) {\n reportMissingTypes(entry, eventName);\n }\n }\n\n return;\n }\n\n const onMapping = getMappingValueAsMapping(root, \"on\");\n\n if (onMapping === null) {\n return;\n }\n\n for (const pair of onMapping.pairs) {\n const eventName = getScalarStringValue(pair.key);\n\n if (\n eventName === null ||\n !eventsRequiringTypes.has(eventName)\n ) {\n continue;\n }\n\n const eventValue = unwrapYamlValue(pair.value);\n\n if (eventValue?.type !== \"YAMLMapping\") {\n reportMissingTypes(\n (pair.value ?? pair.key) as AST.YAMLNode,\n eventName\n );\n\n continue;\n }\n\n if (\n hasConfiguredTypes(getMappingPair(eventValue, \"types\"))\n ) {\n continue;\n }\n\n reportMissingTypes(eventValue, eventName);\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require explicit `types` filters for selected multi-activity workflow events so workflows do not subscribe to every supported activity implicitly.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R031\",\n ruleNumber: 31,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-trigger-types\",\n },\n messages: {\n missingTypes:\n \"`on.{{event}}` should declare a non-empty `types` filter so the workflow is scoped to explicit activity types.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require TruffleHog workflows to scan only verified results by default.\n */\nimport type { Rule } from \"eslint\";\n\nimport { getTrufflehogActionSteps } from \"../_internal/secret-scanning-workflow.ts\";\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\nconst verifiedResultsPattern = /--results(?:=|\\s+)verified\\b/u;\n\n/** Rule implementation for TruffleHog verified-results mode requirements. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n for (const step of getTrufflehogActionSteps(root)) {\n const withMapping = getMappingValueAsMapping(\n step.stepMapping,\n \"with\"\n );\n const extraArgsPair =\n withMapping === null\n ? null\n : getMappingPair(withMapping, \"extra_args\");\n const extraArgsValue = getScalarStringValue(\n extraArgsPair?.value ?? null\n )?.trim();\n\n if (\n extraArgsValue !== undefined &&\n verifiedResultsPattern.test(extraArgsValue)\n ) {\n continue;\n }\n\n context.report({\n data: { jobId: step.job.id },\n messageId: \"missingVerifiedResultsMode\",\n node: (extraArgsPair?.value ??\n extraArgsPair ??\n withMapping ??\n step.usesPair) as unknown as Rule.Node,\n });\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.security\",\n ],\n description:\n \"require TruffleHog workflows to enable verified-results mode explicitly.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R108\",\n ruleNumber: 108,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-trufflehog-verified-results-mode\",\n },\n messages: {\n missingVerifiedResultsMode:\n \"TruffleHog step in job '{{jobId}}' should set `extra_args` to include `--results=verified`.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require explicit types for reusable workflow inputs.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Allowed GitHub reusable workflow input types. */\nconst allowedWorkflowCallInputTypes = [\n \"boolean\",\n \"number\",\n \"string\",\n] as const;\n\n/** Constant-time lookup for supported reusable workflow input types. */\nconst allowedWorkflowCallInputTypeSet: ReadonlySet<string> = new Set(\n allowedWorkflowCallInputTypes\n);\n\n/** Rule implementation for requiring explicit workflow_call input types. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const onMapping = getMappingValueAsMapping(root, \"on\");\n\n if (onMapping === null) {\n return;\n }\n\n const workflowCallMapping = unwrapYamlValue(\n getMappingPair(onMapping, \"workflow_call\")?.value ?? null\n );\n\n if (workflowCallMapping?.type !== \"YAMLMapping\") {\n return;\n }\n\n const inputsMapping = getMappingValueAsMapping(\n workflowCallMapping,\n \"inputs\"\n );\n\n if (inputsMapping === null) {\n return;\n }\n\n for (const pair of inputsMapping.pairs) {\n const inputId = getScalarStringValue(pair.key);\n const inputMapping = unwrapYamlValue(pair.value);\n\n if (\n inputId === null ||\n inputMapping?.type !== \"YAMLMapping\"\n ) {\n continue;\n }\n\n const typePair = getMappingPair(inputMapping, \"type\");\n\n if (typePair === null) {\n context.report({\n data: {\n inputId,\n },\n messageId: \"missingType\",\n node: pair.key as unknown as Rule.Node,\n });\n\n continue;\n }\n\n const typeValue = getScalarStringValue(typePair.value);\n\n if (\n typeValue === null ||\n !allowedWorkflowCallInputTypeSet.has(typeValue)\n ) {\n context.report({\n data: {\n allowedTypes:\n allowedWorkflowCallInputTypes.join(\", \"),\n inputId,\n },\n messageId: \"invalidType\",\n node: (typePair.value ??\n typePair) as unknown as Rule.Node,\n });\n }\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require every `workflow_call` input to declare one of the documented reusable-workflow input types so callers and validators agree on interface semantics.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R034\",\n ruleNumber: 34,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-workflow-call-input-type\",\n },\n messages: {\n invalidType:\n \"`workflow_call` input '{{inputId}}' must set `type` to one of: {{allowedTypes}}.\",\n missingType:\n \"`workflow_call` input '{{inputId}}' should declare `type` explicitly.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require reusable workflow outputs to declare a non-empty `value`.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring explicit reusable-workflow output values. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const onMapping = getMappingValueAsMapping(root, \"on\");\n\n if (onMapping === null) {\n return;\n }\n\n const workflowCallMapping = unwrapYamlValue(\n getMappingPair(onMapping, \"workflow_call\")?.value ?? null\n );\n\n if (workflowCallMapping?.type !== \"YAMLMapping\") {\n return;\n }\n\n const outputsMapping = getMappingValueAsMapping(\n workflowCallMapping,\n \"outputs\"\n );\n\n if (outputsMapping === null) {\n return;\n }\n\n for (const pair of outputsMapping.pairs) {\n const outputId = getScalarStringValue(pair.key);\n const outputMapping = unwrapYamlValue(pair.value);\n\n if (\n outputId === null ||\n outputMapping?.type !== \"YAMLMapping\"\n ) {\n continue;\n }\n\n const valuePair = getMappingPair(outputMapping, \"value\");\n\n if (valuePair === null) {\n context.report({\n data: {\n outputId,\n },\n messageId: \"missingValue\",\n node: pair.key as unknown as Rule.Node,\n });\n\n continue;\n }\n\n const value = getScalarStringValue(valuePair.value);\n\n if (value === null || value.trim().length === 0) {\n context.report({\n data: {\n outputId,\n },\n messageId: \"invalidValue\",\n node: (valuePair.value ??\n valuePair) as unknown as Rule.Node,\n });\n }\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require every `workflow_call` output to declare a non-empty `value` so reusable workflows expose concrete runtime output mappings.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R039\",\n ruleNumber: 39,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-workflow-call-output-value\",\n },\n messages: {\n invalidValue:\n \"`workflow_call` output '{{outputId}}' must set `value` to a non-empty scalar expression.\",\n missingValue:\n \"`workflow_call` output '{{outputId}}' should declare `value` explicitly.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require top-level workflow concurrency controls for relevant workflow triggers.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowEventNames,\n getWorkflowRoot,\n isGithubExpressionScalar,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Default event set that most benefits from workflow-level concurrency. */\nconst DEFAULT_TRIGGER_EVENTS = [\n \"merge_group\",\n \"pull_request\",\n \"pull_request_target\",\n \"push\",\n \"workflow_dispatch\",\n] as const;\n\n/** Rule options for `require-workflow-concurrency`. */\ntype RequireWorkflowConcurrencyOptions = [\n {\n readonly onlyForEvents?: readonly string[];\n readonly requireCancelInProgress?: boolean;\n }?,\n];\n\n/** Rule implementation for requiring workflow-level concurrency controls. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const [options] = context.options as RequireWorkflowConcurrencyOptions;\n const requiredTriggerEvents = new Set<string>(\n options?.onlyForEvents ?? DEFAULT_TRIGGER_EVENTS\n );\n const requireCancelInProgress =\n options?.requireCancelInProgress ?? true;\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const eventNames = getWorkflowEventNames(root);\n const shouldRequireConcurrency = [\n ...requiredTriggerEvents,\n ].some((eventName) => eventNames.has(eventName));\n\n if (!shouldRequireConcurrency) {\n return;\n }\n\n const concurrencyPair = getMappingPair(root, \"concurrency\");\n\n if (concurrencyPair === null) {\n context.report({\n messageId: \"missingConcurrency\",\n node: root,\n });\n\n return;\n }\n\n const concurrencyValue = unwrapYamlValue(concurrencyPair.value);\n\n if (concurrencyValue === null) {\n context.report({\n messageId: \"invalidConcurrency\",\n node: concurrencyPair,\n });\n\n return;\n }\n\n if (concurrencyValue.type === \"YAMLScalar\") {\n const groupValue = getScalarStringValue(concurrencyValue);\n\n if (groupValue === null || groupValue.trim().length === 0) {\n context.report({\n messageId: \"invalidConcurrency\",\n node: concurrencyValue,\n });\n }\n\n return;\n }\n\n if (concurrencyValue.type !== \"YAMLMapping\") {\n context.report({\n messageId: \"invalidConcurrency\",\n node: concurrencyValue,\n });\n\n return;\n }\n\n const groupPair = getMappingPair(concurrencyValue, \"group\");\n const groupValue = getScalarStringValue(\n groupPair?.value ?? null\n );\n\n if (\n groupPair === null ||\n groupValue === null ||\n groupValue.trim() === \"\"\n ) {\n context.report({\n messageId: \"missingGroup\",\n node: groupPair?.key ?? concurrencyValue,\n });\n }\n\n if (!requireCancelInProgress) {\n return;\n }\n\n const cancelInProgressPair = getMappingPair(\n concurrencyValue,\n \"cancel-in-progress\"\n );\n\n if (cancelInProgressPair === null) {\n context.report({\n messageId: \"missingCancelInProgress\",\n node: concurrencyValue,\n });\n\n return;\n }\n\n if (isGithubExpressionScalar(cancelInProgressPair.value)) {\n return;\n }\n\n if (\n unwrapYamlValue(cancelInProgressPair.value)?.type !==\n \"YAMLScalar\"\n ) {\n context.report({\n messageId: \"cancelInProgressDisabled\",\n node:\n cancelInProgressPair.value ?? cancelInProgressPair,\n });\n\n return;\n }\n\n if (cancelInProgressPair.value?.type !== \"YAMLScalar\") {\n context.report({\n messageId: \"cancelInProgressDisabled\",\n node:\n cancelInProgressPair.value ?? cancelInProgressPair,\n });\n\n return;\n }\n\n if (cancelInProgressPair.value.value !== true) {\n context.report({\n messageId: \"cancelInProgressDisabled\",\n node: cancelInProgressPair.value,\n });\n }\n },\n };\n },\n meta: {\n defaultOptions: [{}],\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require workflow-level `concurrency` so redundant runs can be deduplicated predictably.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R004\",\n ruleNumber: 4,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-workflow-concurrency\",\n },\n messages: {\n cancelInProgressDisabled:\n \"Workflow `concurrency.cancel-in-progress` should be `true` or a GitHub expression so stale runs can be cancelled.\",\n invalidConcurrency:\n \"Workflow `concurrency` should be a string/expression or an object containing at least `group`.\",\n missingCancelInProgress:\n \"Workflow `concurrency` should set `cancel-in-progress` to cancel superseded runs.\",\n missingConcurrency:\n \"Add a top-level `concurrency` block so overlapping workflow runs do not pile up.\",\n missingGroup:\n \"Workflow `concurrency` should declare a non-empty `group` value.\",\n },\n schema: [\n {\n additionalProperties: false,\n description:\n \"Optional configuration for which events require workflow-level concurrency and whether cancel-in-progress is mandatory.\",\n properties: {\n onlyForEvents: {\n description:\n \"Event names that should trigger the workflow-level concurrency requirement.\",\n items: {\n minLength: 1,\n type: \"string\",\n },\n type: \"array\",\n uniqueItems: true,\n },\n requireCancelInProgress: {\n description:\n \"Require concurrency.cancel-in-progress so newer runs can cancel superseded work.\",\n type: \"boolean\",\n },\n },\n type: \"object\",\n },\n ],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require explicit types for `workflow_dispatch` inputs.\n */\nimport type { Rule } from \"eslint\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for requiring explicit workflow_dispatch input types. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const onMapping = getMappingValueAsMapping(root, \"on\");\n\n if (onMapping === null) {\n return;\n }\n\n const workflowDispatchMapping = unwrapYamlValue(\n getMappingPair(onMapping, \"workflow_dispatch\")?.value ??\n null\n );\n\n if (workflowDispatchMapping?.type !== \"YAMLMapping\") {\n return;\n }\n\n const inputsMapping = getMappingValueAsMapping(\n workflowDispatchMapping,\n \"inputs\"\n );\n\n if (inputsMapping === null) {\n return;\n }\n\n for (const pair of inputsMapping.pairs) {\n const inputId = getScalarStringValue(pair.key);\n const inputMapping = unwrapYamlValue(pair.value);\n\n if (\n inputId === null ||\n inputMapping?.type !== \"YAMLMapping\"\n ) {\n continue;\n }\n\n const typePair = getMappingPair(inputMapping, \"type\");\n\n if (typePair === null) {\n context.report({\n data: {\n inputId,\n },\n messageId: \"missingType\",\n node: pair.key as unknown as Rule.Node,\n });\n\n continue;\n }\n\n const typeValue = getScalarStringValue(typePair.value);\n\n if (typeValue === null || typeValue.trim().length === 0) {\n context.report({\n data: {\n inputId,\n },\n messageId: \"invalidType\",\n node: (typePair.value ??\n typePair) as unknown as Rule.Node,\n });\n }\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require every `workflow_dispatch` input to declare an explicit `type` so manual runs expose clearer controls and preserve intended value semantics.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R022\",\n ruleNumber: 22,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-workflow-dispatch-input-type\",\n },\n messages: {\n invalidType:\n \"`workflow_dispatch` input '{{inputId}}' must set `type` to a non-empty string.\",\n missingType:\n \"`workflow_dispatch` input '{{inputId}}' should declare `type` explicitly.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require descriptions for manual and reusable workflow interfaces.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Report missing or invalid descriptions across interface mappings. */\nconst checkInterfaceDescriptions = (\n context: Readonly<Rule.RuleContext>,\n mapping: Readonly<AST.YAMLMapping>,\n kind: string\n): void => {\n for (const pair of mapping.pairs) {\n const name = getScalarStringValue(pair.key);\n const entryMapping = unwrapYamlValue(pair.value);\n\n if (name === null || entryMapping?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const descriptionPair = getMappingPair(entryMapping, \"description\");\n\n if (descriptionPair === null) {\n context.report({\n data: {\n kind,\n name,\n },\n messageId: \"missingDescription\",\n node: pair.key as unknown as Rule.Node,\n });\n\n continue;\n }\n\n const descriptionValue = getScalarStringValue(descriptionPair.value);\n\n if (descriptionValue === null || descriptionValue.trim().length === 0) {\n context.report({\n data: {\n kind,\n name,\n },\n messageId: \"invalidDescription\",\n node: (descriptionPair.value ??\n descriptionPair) as unknown as Rule.Node,\n });\n }\n }\n};\n\n/** Rule implementation for requiring workflow interface descriptions. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const onMapping = getMappingValueAsMapping(root, \"on\");\n\n if (onMapping === null) {\n return;\n }\n\n const workflowDispatchMapping = unwrapYamlValue(\n getMappingPair(onMapping, \"workflow_dispatch\")?.value ??\n null\n );\n\n if (workflowDispatchMapping?.type === \"YAMLMapping\") {\n const dispatchInputsMapping = getMappingValueAsMapping(\n workflowDispatchMapping,\n \"inputs\"\n );\n\n if (dispatchInputsMapping !== null) {\n checkInterfaceDescriptions(\n context,\n dispatchInputsMapping,\n \"workflow_dispatch input\"\n );\n }\n }\n\n const workflowCallMapping = unwrapYamlValue(\n getMappingPair(onMapping, \"workflow_call\")?.value ?? null\n );\n\n if (workflowCallMapping?.type !== \"YAMLMapping\") {\n return;\n }\n\n const workflowCallInputsMapping = getMappingValueAsMapping(\n workflowCallMapping,\n \"inputs\"\n );\n\n if (workflowCallInputsMapping !== null) {\n checkInterfaceDescriptions(\n context,\n workflowCallInputsMapping,\n \"workflow_call input\"\n );\n }\n\n const workflowCallSecretsMapping = getMappingValueAsMapping(\n workflowCallMapping,\n \"secrets\"\n );\n\n if (workflowCallSecretsMapping !== null) {\n checkInterfaceDescriptions(\n context,\n workflowCallSecretsMapping,\n \"workflow_call secret\"\n );\n }\n\n const workflowCallOutputsMapping = getMappingValueAsMapping(\n workflowCallMapping,\n \"outputs\"\n );\n\n if (workflowCallOutputsMapping !== null) {\n checkInterfaceDescriptions(\n context,\n workflowCallOutputsMapping,\n \"workflow_call output\"\n );\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require descriptions for `workflow_dispatch` inputs and reusable workflow interfaces so manual forms and callable workflows stay self-documenting.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R024\",\n ruleNumber: 24,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-workflow-interface-description\",\n },\n messages: {\n invalidDescription:\n \"{{kind}} '{{name}}' must set `description` to a non-empty string.\",\n missingDescription:\n \"{{kind}} '{{name}}' should declare `description` explicitly.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require explicit GitHub token permissions at workflow or job scope.\n */\nimport type { Rule } from \"eslint\";\n\nimport { isWorkflowFile } from \"../_internal/lint-targets.js\";\nimport {\n getMappingPair,\n getWorkflowJobs,\n getWorkflowRoot,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule options for `require-workflow-permissions`. */\ntype RequireWorkflowPermissionsOptions = [\n {\n readonly allowJobLevelPermissions?: boolean;\n }?,\n];\n\n/** Rule implementation for requiring explicit workflow or job token permissions. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const [options] = context.options as RequireWorkflowPermissionsOptions;\n const allowJobLevelPermissions =\n options?.allowJobLevelPermissions ?? true;\n\n return {\n Program() {\n if (!isWorkflowFile(context.filename)) {\n return;\n }\n\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n if (getMappingPair(root, \"permissions\") !== null) {\n return;\n }\n\n const jobs = getWorkflowJobs(root);\n\n if (!allowJobLevelPermissions) {\n context.report({\n messageId: \"missingWorkflowPermissions\",\n node: root,\n });\n\n return;\n }\n\n if (jobs.length === 0) {\n context.report({\n messageId: \"missingWorkflowPermissions\",\n node: root,\n });\n\n return;\n }\n\n for (const job of jobs) {\n if (getMappingPair(job.mapping, \"permissions\") !== null) {\n continue;\n }\n\n context.report({\n data: {\n jobId: job.id,\n },\n messageId: \"missingJobPermissions\",\n node: job.idNode,\n });\n }\n },\n };\n },\n meta: {\n defaultOptions: [{}],\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.security\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require explicit `permissions` to avoid relying on GitHub Actions' default token scope.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R001\",\n ruleNumber: 1,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-workflow-permissions\",\n },\n messages: {\n missingJobPermissions:\n \"Job '{{jobId}}' is missing explicit `permissions`. Define workflow-level `permissions` or add `jobs.{{jobId}}.permissions`.\",\n missingWorkflowPermissions:\n \"Define explicit top-level `permissions` for this workflow, or configure job-level `permissions` for every job.\",\n },\n schema: [\n {\n additionalProperties: false,\n description:\n \"Optional configuration for how strictly workflow permissions must be declared.\",\n properties: {\n allowJobLevelPermissions: {\n description:\n \"Allow each job to declare its own permissions when the workflow omits a top-level permissions block.\",\n type: \"boolean\",\n },\n },\n type: \"object\",\n },\n ],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require branch scoping for `workflow_run` triggers.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/**\n * Determine whether a workflow_run branch filter node is meaningfully\n * configured.\n */\nconst hasConfiguredBranchFilter = (\n node: null | Readonly<AST.YAMLPair> | undefined\n): boolean => {\n const valueNode = unwrapYamlValue(node?.value ?? null);\n\n if (valueNode === null) {\n return false;\n }\n\n if (valueNode.type === \"YAMLScalar\") {\n const value = getScalarStringValue(valueNode);\n\n return value !== null && value.trim().length > 0;\n }\n\n if (valueNode.type !== \"YAMLSequence\") {\n return false;\n }\n\n return valueNode.entries.some((entry) => {\n const value = getScalarStringValue(entry);\n\n return value !== null && value.trim().length > 0;\n });\n};\n\n/** Rule implementation for requiring `workflow_run` branch filters. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const onMapping = getMappingValueAsMapping(root, \"on\");\n\n if (onMapping === null) {\n return;\n }\n\n const workflowRunPair = getMappingPair(\n onMapping,\n \"workflow_run\"\n );\n const workflowRunMapping = unwrapYamlValue(\n workflowRunPair?.value ?? null\n );\n\n if (workflowRunPair === null) {\n return;\n }\n\n if (workflowRunMapping?.type !== \"YAMLMapping\") {\n context.report({\n messageId: \"missingBranchFilter\",\n node: (workflowRunPair.value ??\n workflowRunPair) as unknown as Rule.Node,\n });\n\n return;\n }\n\n const branchesPair = getMappingPair(\n workflowRunMapping,\n \"branches\"\n );\n const branchesIgnorePair = getMappingPair(\n workflowRunMapping,\n \"branches-ignore\"\n );\n\n if (\n hasConfiguredBranchFilter(branchesPair) ||\n hasConfiguredBranchFilter(branchesIgnorePair)\n ) {\n return;\n }\n\n context.report({\n messageId: \"missingBranchFilter\",\n node: workflowRunMapping as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.security\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"require `on.workflow_run` triggers to scope upstream branches with `branches` or `branches-ignore` so follow-up workflows do not react to every branch indiscriminately.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: false,\n requiresTypeChecking: false,\n ruleId: \"R028\",\n ruleNumber: 28,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-workflow-run-branches\",\n },\n messages: {\n missingBranchFilter:\n \"`on.workflow_run` should declare a non-empty `branches` or `branches-ignore` filter to scope which upstream branches can trigger this workflow.\",\n },\n schema: [],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require each workflow template YAML file to have a paired `.properties.json` metadata file.\n */\nimport type { Rule } from \"eslint\";\n\nimport { existsSync } from \"node:fs\";\n\nimport { isWorkflowTemplateYamlFile } from \"../_internal/lint-targets.js\";\nimport { getPairedTemplatePropertiesPath } from \"../_internal/workflow-template-properties.js\";\n\n/** Rule implementation for workflow-template YAML pair checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!isWorkflowTemplateYamlFile(context.filename)) {\n return;\n }\n\n const pairedPropertiesPath = getPairedTemplatePropertiesPath(\n context.filename\n );\n\n if (existsSync(pairedPropertiesPath)) {\n return;\n }\n\n context.report({\n data: {\n pairedPropertiesPath,\n },\n messageId: \"missingTemplatePropertiesPair\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"require each workflow template YAML file to have a matching `.properties.json` metadata file.\",\n dialects: [\"GitHub Actions workflow template\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R054\",\n ruleNumber: 54,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-workflow-template-pair\",\n },\n messages: {\n missingTemplatePropertiesPair:\n \"Workflow template file is missing its paired metadata file '{{pairedPropertiesPath}}'.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Require each workflow template properties file to have a paired template YAML file.\n */\nimport type { Rule } from \"eslint\";\n\nimport { existsSync } from \"node:fs\";\n\nimport { isWorkflowTemplatePropertiesFile } from \"../_internal/lint-targets.js\";\nimport { getPairedTemplateYamlPaths } from \"../_internal/workflow-template-properties.js\";\n\n/** Rule implementation for template metadata pair checks. */\nconst rule: Rule.RuleModule = {\n create(context) {\n return {\n Program(node) {\n if (!isWorkflowTemplatePropertiesFile(context.filename)) {\n return;\n }\n\n const [pairedYmlPath, pairedYamlPath] =\n getPairedTemplateYamlPaths(context.filename);\n\n if (existsSync(pairedYmlPath) || existsSync(pairedYamlPath)) {\n return;\n }\n\n context.report({\n data: {\n pairedYamlPath,\n pairedYmlPath,\n },\n messageId: \"missingTemplateYamlPair\",\n node: node as unknown as Rule.Node,\n });\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.workflowTemplateProperties\",\n \"github-actions.configs.workflowTemplates\",\n \"github-actions.configs.all\",\n ],\n description:\n \"require each workflow-template `.properties.json` file to have a matching template YAML file.\",\n dialects: [\"GitHub Actions workflow template metadata\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R055\",\n ruleNumber: 55,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/require-workflow-template-properties-pair\",\n },\n messages: {\n missingTemplateYamlPair:\n \"Workflow template metadata is missing its paired YAML file. Expected '{{pairedYmlPath}}' or '{{pairedYamlPath}}'.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Validate literal job and step timeout-minutes values.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport {\n getMappingPair,\n getMappingValueAsMapping,\n getMappingValueAsSequence,\n getScalarNumberValue,\n getWorkflowRoot,\n isGithubExpressionScalar,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Timeout range accepted by a timeout validator. */\ntype TimeoutRange = {\n readonly max?: number;\n readonly min?: number;\n};\n\n/** Split timeout configuration for jobs and steps. */\ntype TimeoutScopeOptions = {\n readonly job?: number | TimeoutRange;\n readonly step?: number | TimeoutRange;\n};\n\n/** Rule options for `valid-timeout-minutes`. */\ntype ValidTimeoutMinutesOptions = [\n (number | TimeoutRange | TimeoutScopeOptions)?,\n];\n\n/** Default lower bound for literal timeout-minutes values. */\nconst MIN_TIMEOUT_MINUTES = 1;\n\n/** Default upper bound for literal timeout-minutes values. */\nconst MAX_TIMEOUT_MINUTES = 24 * 60;\n\n/** Default recommended upper bound when only a single number is configured. */\nconst DEFAULT_MAX_TIMEOUT_MINUTES = 6 * 60;\n\n/** Normalize timeout range input into concrete min/max bounds. */\nconst normalizeTimeoutRange = (\n value: Readonly<number | TimeoutRange | undefined>,\n fallback: Readonly<{ max: number; min: number }>\n): { max: number; min: number } => {\n if (typeof value === \"number\") {\n return {\n max: value,\n min: fallback.min,\n };\n }\n\n if (value === undefined) {\n return {\n max: fallback.max,\n min: fallback.min,\n };\n }\n\n return {\n max: value.max ?? fallback.max,\n min: value.min ?? fallback.min,\n };\n};\n\n/** Determine whether an options value represents a shared timeout range. */\nconst isTimeoutRange = (value: unknown): value is TimeoutRange =>\n typeof value === \"object\" &&\n value !== null &&\n (\"min\" in value || \"max\" in value);\n\n/** Determine whether an options value represents split job/step timeout config. */\nconst isTimeoutScopeOptions = (value: unknown): value is TimeoutScopeOptions =>\n typeof value === \"object\" &&\n value !== null &&\n (\"job\" in value || \"step\" in value);\n\n/** Rule implementation for validating timeout-minutes ranges. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const [options] = context.options as ValidTimeoutMinutesOptions;\n const defaultRange = {\n max: DEFAULT_MAX_TIMEOUT_MINUTES,\n min: MIN_TIMEOUT_MINUTES,\n };\n const workflowMaximumRange = {\n max: MAX_TIMEOUT_MINUTES,\n };\n\n const jobRange = normalizeTimeoutRange(\n typeof options === \"number\" || isTimeoutRange(options)\n ? options\n : options?.job,\n defaultRange\n );\n const stepRange = normalizeTimeoutRange(\n typeof options === \"number\" || isTimeoutRange(options)\n ? options\n : options?.step,\n defaultRange\n );\n\n if (isTimeoutScopeOptions(options)) {\n jobRange.max = normalizeTimeoutRange(options.job, defaultRange).max;\n jobRange.min = normalizeTimeoutRange(options.job, defaultRange).min;\n stepRange.max = normalizeTimeoutRange(\n options.step,\n defaultRange\n ).max;\n stepRange.min = normalizeTimeoutRange(\n options.step,\n defaultRange\n ).min;\n }\n\n const validateTimeoutPair = (\n timeoutPair: Readonly<AST.YAMLPair>,\n range: Readonly<{ max: number; min: number }>\n ): \"invalidRange\" | \"notInteger\" | null => {\n if (isGithubExpressionScalar(timeoutPair.value)) {\n return null;\n }\n\n const timeoutValue = getScalarNumberValue(timeoutPair.value);\n\n if (\n timeoutValue === null ||\n !Number.isInteger(timeoutValue) ||\n timeoutValue <= 0\n ) {\n return \"notInteger\";\n }\n\n if (\n timeoutValue < range.min ||\n timeoutValue > range.max ||\n timeoutValue > workflowMaximumRange.max\n ) {\n return \"invalidRange\";\n }\n\n return null;\n };\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const jobsMapping = getMappingValueAsMapping(root, \"jobs\");\n\n if (jobsMapping === null) {\n return;\n }\n\n for (const jobPair of jobsMapping.pairs) {\n const jobValue = unwrapYamlValue(jobPair.value);\n\n if (jobValue?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const jobTimeoutPair = getMappingPair(\n jobValue,\n \"timeout-minutes\"\n );\n\n if (jobTimeoutPair !== null) {\n const validationResult = validateTimeoutPair(\n jobTimeoutPair,\n jobRange\n );\n\n if (validationResult !== null) {\n context.report({\n data: {\n max: String(jobRange.max),\n min: String(jobRange.min),\n },\n messageId: validationResult,\n node: (jobTimeoutPair.value ??\n jobTimeoutPair) as unknown as Rule.Node,\n });\n }\n }\n\n const stepsSequence = getMappingValueAsSequence(\n jobValue,\n \"steps\"\n );\n\n if (stepsSequence === null) {\n continue;\n }\n\n for (const stepEntry of stepsSequence.entries) {\n const stepValue = unwrapYamlValue(stepEntry);\n\n if (stepValue?.type !== \"YAMLMapping\") {\n continue;\n }\n\n const stepTimeoutPair = getMappingPair(\n stepValue,\n \"timeout-minutes\"\n );\n\n if (stepTimeoutPair === null) {\n continue;\n }\n\n const validationResult = validateTimeoutPair(\n stepTimeoutPair,\n stepRange\n );\n\n if (validationResult !== null) {\n context.report({\n data: {\n max: String(stepRange.max),\n min: String(stepRange.min),\n },\n messageId: validationResult,\n node: (stepTimeoutPair.value ??\n stepTimeoutPair) as unknown as Rule.Node,\n });\n }\n }\n }\n },\n };\n },\n meta: {\n defaultOptions: [DEFAULT_MAX_TIMEOUT_MINUTES],\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow invalid literal `timeout-minutes` values for jobs and steps.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R017\",\n ruleNumber: 17,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/valid-timeout-minutes\",\n },\n messages: {\n invalidRange:\n \"`timeout-minutes` must stay within the configured range of {{min}}-{{max}}.\",\n notInteger:\n \"`timeout-minutes` must be a positive integer or a GitHub expression.\",\n },\n schema: [\n {\n anyOf: [\n {\n description:\n \"Maximum allowed timeout-minutes value for both jobs and steps.\",\n maximum: MAX_TIMEOUT_MINUTES,\n minimum: MIN_TIMEOUT_MINUTES,\n type: \"integer\",\n },\n {\n additionalProperties: false,\n description:\n \"Shared min/max range for literal job and step timeout-minutes values.\",\n properties: {\n max: {\n description:\n \"Maximum allowed timeout-minutes value.\",\n maximum: MAX_TIMEOUT_MINUTES,\n minimum: MIN_TIMEOUT_MINUTES,\n type: \"integer\",\n },\n min: {\n description:\n \"Minimum allowed timeout-minutes value.\",\n maximum: MAX_TIMEOUT_MINUTES,\n minimum: MIN_TIMEOUT_MINUTES,\n type: \"integer\",\n },\n },\n type: \"object\",\n },\n {\n additionalProperties: false,\n description:\n \"Separate timeout-minutes limits for jobs and steps.\",\n properties: {\n job: {\n anyOf: [\n {\n description:\n \"Maximum allowed timeout-minutes value for jobs.\",\n maximum: MAX_TIMEOUT_MINUTES,\n minimum: MIN_TIMEOUT_MINUTES,\n type: \"integer\",\n },\n {\n additionalProperties: false,\n description:\n \"Min/max range for literal job timeout-minutes values.\",\n properties: {\n max: {\n description:\n \"Maximum allowed job timeout-minutes value.\",\n maximum: MAX_TIMEOUT_MINUTES,\n minimum: MIN_TIMEOUT_MINUTES,\n type: \"integer\",\n },\n min: {\n description:\n \"Minimum allowed job timeout-minutes value.\",\n maximum: MAX_TIMEOUT_MINUTES,\n minimum: MIN_TIMEOUT_MINUTES,\n type: \"integer\",\n },\n },\n type: \"object\",\n },\n ],\n },\n step: {\n anyOf: [\n {\n description:\n \"Maximum allowed timeout-minutes value for steps.\",\n maximum: MAX_TIMEOUT_MINUTES,\n minimum: MIN_TIMEOUT_MINUTES,\n type: \"integer\",\n },\n {\n additionalProperties: false,\n description:\n \"Min/max range for literal step timeout-minutes values.\",\n properties: {\n max: {\n description:\n \"Maximum allowed step timeout-minutes value.\",\n maximum: MAX_TIMEOUT_MINUTES,\n minimum: MIN_TIMEOUT_MINUTES,\n type: \"integer\",\n },\n min: {\n description:\n \"Minimum allowed step timeout-minutes value.\",\n maximum: MAX_TIMEOUT_MINUTES,\n minimum: MIN_TIMEOUT_MINUTES,\n type: \"integer\",\n },\n },\n type: \"object\",\n },\n ],\n },\n },\n type: \"object\",\n },\n ],\n description:\n \"Configure literal timeout-minutes validation for jobs and steps.\",\n },\n ],\n type: \"suggestion\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Current GitHub Actions workflow trigger events from the public docs.\n */\n\n/**\n * Valid workflow trigger events documented by GitHub.\n *\n * @see https://docs.github.com/en/actions/reference/events-that-trigger-workflows\n */\nexport const githubActionsTriggerEvents = [\n \"branch_protection_rule\",\n \"check_run\",\n \"check_suite\",\n \"create\",\n \"delete\",\n \"deployment\",\n \"deployment_status\",\n \"discussion\",\n \"discussion_comment\",\n \"fork\",\n \"gollum\",\n \"image_version\",\n \"issue_comment\",\n \"issues\",\n \"label\",\n \"merge_group\",\n \"milestone\",\n \"page_build\",\n \"public\",\n \"pull_request\",\n \"pull_request_review\",\n \"pull_request_review_comment\",\n \"pull_request_target\",\n \"push\",\n \"registry_package\",\n \"release\",\n \"repository_dispatch\",\n \"schedule\",\n \"status\",\n \"watch\",\n \"workflow_call\",\n \"workflow_dispatch\",\n \"workflow_run\",\n] as const;\n\n/** Constant-time lookup set for validating trigger-event names. */\nexport const githubActionsTriggerEventSet: ReadonlySet<string> = new Set(\n githubActionsTriggerEvents\n);\n", "/**\n * @packageDocumentation\n * Validate GitHub Actions workflow trigger event names.\n */\nimport type { Rule } from \"eslint\";\nimport type { AST } from \"yaml-eslint-parser\";\n\nimport { githubActionsTriggerEventSet } from \"../_internal/github-actions-trigger-events.js\";\nimport {\n getMappingPair,\n getScalarStringValue,\n getWorkflowRoot,\n unwrapYamlValue,\n} from \"../_internal/workflow-yaml.js\";\n\n/** Rule implementation for validating `on:` trigger event names. */\nconst rule: Rule.RuleModule = {\n create(context) {\n const reportInvalidEvent = (\n node: Readonly<AST.YAMLNode>,\n eventName: string\n ): void => {\n context.report({\n data: {\n event: eventName,\n },\n messageId: \"invalidEvent\",\n node: node as unknown as Rule.Node,\n });\n };\n\n return {\n Program() {\n const root = getWorkflowRoot(context);\n\n if (root === null) {\n return;\n }\n\n const onPair = getMappingPair(root, \"on\");\n const onValue = unwrapYamlValue(onPair?.value ?? null);\n\n if (onValue === null) {\n return;\n }\n\n if (onValue.type === \"YAMLScalar\") {\n const eventName = getScalarStringValue(onValue);\n\n if (\n eventName !== null &&\n !githubActionsTriggerEventSet.has(eventName)\n ) {\n reportInvalidEvent(onValue, eventName);\n }\n\n return;\n }\n\n if (onValue.type === \"YAMLSequence\") {\n for (const entry of onValue.entries) {\n const unwrappedEntry = unwrapYamlValue(entry);\n const eventName = getScalarStringValue(unwrappedEntry);\n\n if (\n unwrappedEntry !== null &&\n (eventName === null ||\n !githubActionsTriggerEventSet.has(eventName))\n ) {\n context.report({\n data: {\n event: eventName ?? \"<unknown>\",\n },\n messageId:\n eventName === null\n ? \"invalidEventEntry\"\n : \"invalidEvent\",\n node: unwrappedEntry as unknown as Rule.Node,\n });\n }\n }\n\n return;\n }\n\n if (onValue.type !== \"YAMLMapping\") {\n context.report({\n messageId: \"invalidEventEntry\",\n node: onValue as unknown as Rule.Node,\n });\n\n return;\n }\n\n for (const pair of onValue.pairs) {\n const eventName = getScalarStringValue(pair.key);\n\n if (eventName === null) {\n context.report({\n messageId: \"invalidEventEntry\",\n node: pair as unknown as Rule.Node,\n });\n\n continue;\n }\n\n if (!githubActionsTriggerEventSet.has(eventName)) {\n reportInvalidEvent(pair.key as AST.YAMLNode, eventName);\n }\n }\n },\n };\n },\n meta: {\n deprecated: false,\n docs: {\n configs: [\n \"github-actions.configs.all\",\n \"github-actions.configs.recommended\",\n \"github-actions.configs.strict\",\n ],\n description:\n \"disallow invalid GitHub Actions trigger events under the workflow `on` key.\",\n dialects: [\"GitHub Actions workflow\"],\n frozen: false,\n recommended: true,\n requiresTypeChecking: false,\n ruleId: \"R018\",\n ruleNumber: 18,\n url: \"https://nick2bad4u.github.io/eslint-plugin-github-actions-2/docs/rules/valid-trigger-events\",\n },\n messages: {\n invalidEvent:\n \"`{{event}}` is not a documented GitHub Actions workflow trigger event.\",\n invalidEventEntry:\n \"Workflow `on` entries must use string event names.\",\n },\n schema: [],\n type: \"problem\",\n } as Rule.RuleMetaData,\n};\n\nexport default rule;\n", "/**\n * @packageDocumentation\n * Central rule registry for eslint-plugin-github-actions-2.\n */\nimport type { Rule } from \"eslint\";\n\nimport actionNameCasing from \"../rules/action-name-casing.js\";\nimport jobIdCasing from \"../rules/job-id-casing.js\";\nimport maxJobsPerAction from \"../rules/max-jobs-per-action.js\";\nimport noCaseInsensitiveInputIdCollision from \"../rules/no-case-insensitive-input-id-collision.js\";\nimport noCodeqlAutobuildForJavaScriptTypeScript from \"../rules/no-codeql-autobuild-for-javascript-typescript.js\";\nimport noCodeqlJavascriptTypeScriptSplitLanguageMatrix from \"../rules/no-codeql-javascript-typescript-split-language-matrix.js\";\nimport noCompositeInputEnvAccess from \"../rules/no-composite-input-env-access.js\";\nimport noDeprecatedNodeRuntime from \"../rules/no-deprecated-node-runtime.js\";\nimport noDuplicateCompositeStepId from \"../rules/no-duplicate-composite-step-id.js\";\nimport noEmptyTemplateFilePattern from \"../rules/no-empty-template-file-pattern.js\";\nimport noExternalJob from \"../rules/no-external-job.js\";\nimport noHardcodedDefaultBranchInTemplate from \"../rules/no-hardcoded-default-branch-in-template.js\";\nimport noIconFileExtensionInTemplateIconName from \"../rules/no-icon-file-extension-in-template-icon-name.js\";\nimport noInheritSecrets from \"../rules/no-inherit-secrets.js\";\nimport noInvalidConcurrencyContext from \"../rules/no-invalid-concurrency-context.js\";\nimport noInvalidKey from \"../rules/no-invalid-key.js\";\nimport noInvalidReusableWorkflowJobKey from \"../rules/no-invalid-reusable-workflow-job-key.js\";\nimport noInvalidTemplateFilePatternRegex from \"../rules/no-invalid-template-file-pattern-regex.js\";\nimport noInvalidWorkflowCallOutputValue from \"../rules/no-invalid-workflow-call-output-value.js\";\nimport noOverlappingDependabotDirectories from \"../rules/no-overlapping-dependabot-directories.js\";\nimport noPathSeparatorsInTemplateIconName from \"../rules/no-path-separators-in-template-icon-name.js\";\nimport noPostIfWithoutPost from \"../rules/no-post-if-without-post.js\";\nimport noPrHeadCheckoutInPullRequestTarget from \"../rules/no-pr-head-checkout-in-pull-request-target.js\";\nimport noPreIfWithoutPre from \"../rules/no-pre-if-without-pre.js\";\nimport noRequiredInputWithDefault from \"../rules/no-required-input-with-default.js\";\nimport noSecretsInIf from \"../rules/no-secrets-in-if.js\";\nimport noSelfHostedRunnerOnForkPrEvents from \"../rules/no-self-hosted-runner-on-fork-pr-events.js\";\nimport noSubdirectoryTemplateFilePattern from \"../rules/no-subdirectory-template-file-pattern.js\";\nimport noTemplatePlaceholderInNonTemplateWorkflow from \"../rules/no-template-placeholder-in-non-template-workflow.js\";\nimport noTopLevelEnv from \"../rules/no-top-level-env.js\";\nimport noTopLevelPermissions from \"../rules/no-top-level-permissions.js\";\nimport noUniversalTemplateFilePattern from \"../rules/no-universal-template-file-pattern.js\";\nimport noUnknownDependabotMultiEcosystemGroup from \"../rules/no-unknown-dependabot-multi-ecosystem-group.js\";\nimport noUnknownInputReferenceInComposite from \"../rules/no-unknown-input-reference-in-composite.js\";\nimport noUnknownJobOutputReference from \"../rules/no-unknown-job-output-reference.js\";\nimport noUnknownStepReference from \"../rules/no-unknown-step-reference.js\";\nimport noUntrustedInputInRun from \"../rules/no-untrusted-input-in-run.js\";\nimport noUnusedDependabotEnableBetaEcosystems from \"../rules/no-unused-dependabot-enable-beta-ecosystems.js\";\nimport noUnusedInputInComposite from \"../rules/no-unused-input-in-composite.js\";\nimport noWriteAllPermissions from \"../rules/no-write-all-permissions.js\";\nimport pinActionShas from \"../rules/pin-action-shas.js\";\nimport preferActionYml from \"../rules/prefer-action-yml.js\";\nimport preferFailFast from \"../rules/prefer-fail-fast.js\";\nimport preferFileExtension from \"../rules/prefer-file-extension.js\";\nimport preferInputsContext from \"../rules/prefer-inputs-context.js\";\nimport preferStepUsesStyle from \"../rules/prefer-step-uses-style.js\";\nimport preferTemplateYmlExtension from \"../rules/prefer-template-yml-extension.js\";\nimport requireActionName from \"../rules/require-action-name.js\";\nimport requireActionRunName from \"../rules/require-action-run-name.js\";\nimport requireCheckoutBeforeLocalAction from \"../rules/require-checkout-before-local-action.js\";\nimport requireCodeqlActionsRead from \"../rules/require-codeql-actions-read.js\";\nimport requireCodeqlBranchFilters from \"../rules/require-codeql-branch-filters.js\";\nimport requireCodeqlCategoryWhenLanguageMatrix from \"../rules/require-codeql-category-when-language-matrix.js\";\nimport requireCodeqlPullRequestTrigger from \"../rules/require-codeql-pull-request-trigger.js\";\nimport requireCodeqlSchedule from \"../rules/require-codeql-schedule.js\";\nimport requireCodeqlSecurityEventsWrite from \"../rules/require-codeql-security-events-write.js\";\nimport requireCompositeStepName from \"../rules/require-composite-step-name.js\";\nimport requireDependabotAssignees from \"../rules/require-dependabot-assignees.js\";\nimport requireDependabotAutomationPermissions from \"../rules/require-dependabot-automation-permissions.js\";\nimport requireDependabotAutomationPullRequestTrigger from \"../rules/require-dependabot-automation-pull-request-trigger.js\";\nimport requireDependabotBotActorGuard from \"../rules/require-dependabot-bot-actor-guard.js\";\nimport requireDependabotCommitMessageIncludeScope from \"../rules/require-dependabot-commit-message-include-scope.js\";\nimport requireDependabotCommitMessagePrefixDevelopment from \"../rules/require-dependabot-commit-message-prefix-development.js\";\nimport requireDependabotCommitMessagePrefix from \"../rules/require-dependabot-commit-message-prefix.js\";\nimport requireDependabotCooldown from \"../rules/require-dependabot-cooldown.js\";\nimport requireDependabotDirectory from \"../rules/require-dependabot-directory.js\";\nimport requireDependabotGithubActionsDirectoryRoot from \"../rules/require-dependabot-github-actions-directory-root.js\";\nimport requireDependabotLabels from \"../rules/require-dependabot-labels.js\";\nimport requireDependabotOpenPullRequestsLimit from \"../rules/require-dependabot-open-pull-requests-limit.js\";\nimport requireDependabotPackageEcosystem from \"../rules/require-dependabot-package-ecosystem.js\";\nimport requireDependabotPatternsForMultiEcosystemGroup from \"../rules/require-dependabot-patterns-for-multi-ecosystem-group.js\";\nimport requireDependabotScheduleCronjob from \"../rules/require-dependabot-schedule-cronjob.js\";\nimport requireDependabotScheduleInterval from \"../rules/require-dependabot-schedule-interval.js\";\nimport requireDependabotScheduleTime from \"../rules/require-dependabot-schedule-time.js\";\nimport requireDependabotScheduleTimezone from \"../rules/require-dependabot-schedule-timezone.js\";\nimport requireDependabotTargetBranch from \"../rules/require-dependabot-target-branch.js\";\nimport requireDependabotUpdates from \"../rules/require-dependabot-updates.js\";\nimport requireDependabotVersion from \"../rules/require-dependabot-version.js\";\nimport requireDependabotVersioningStrategyForNpm from \"../rules/require-dependabot-versioning-strategy-for-npm.js\";\nimport requireDependencyReviewAction from \"../rules/require-dependency-review-action.js\";\nimport requireDependencyReviewFailOnSeverity from \"../rules/require-dependency-review-fail-on-severity.js\";\nimport requireDependencyReviewPermissionsContentsRead from \"../rules/require-dependency-review-permissions-contents-read.js\";\nimport requireDependencyReviewPullRequestTrigger from \"../rules/require-dependency-review-pull-request-trigger.js\";\nimport requireFetchMetadataGithubToken from \"../rules/require-fetch-metadata-github-token.js\";\nimport requireJobName from \"../rules/require-job-name.js\";\nimport requireJobStepName from \"../rules/require-job-step-name.js\";\nimport requireJobTimeoutMinutes from \"../rules/require-job-timeout-minutes.js\";\nimport requireMergeGroupTrigger from \"../rules/require-merge-group-trigger.js\";\nimport requirePullRequestTargetBranches from \"../rules/require-pull-request-target-branches.js\";\nimport requireRunStepShell from \"../rules/require-run-step-shell.js\";\nimport requireSarifUploadSecurityEventsWrite from \"../rules/require-sarif-upload-security-events-write.js\";\nimport requireScorecardResultsFormatSarif from \"../rules/require-scorecard-results-format-sarif.js\";\nimport requireScorecardUploadSarifStep from \"../rules/require-scorecard-upload-sarif-step.js\";\nimport requireSecretScanContentsRead from \"../rules/require-secret-scan-contents-read.js\";\nimport requireSecretScanFetchDepthZero from \"../rules/require-secret-scan-fetch-depth-zero.js\";\nimport requireSecretScanSchedule from \"../rules/require-secret-scan-schedule.js\";\nimport requireTemplateCategories from \"../rules/require-template-categories.js\";\nimport requireTemplateFilePatterns from \"../rules/require-template-file-patterns.js\";\nimport requireTemplateIconFileExists from \"../rules/require-template-icon-file-exists.js\";\nimport requireTemplateIconName from \"../rules/require-template-icon-name.js\";\nimport requireTemplateWorkflowName from \"../rules/require-template-workflow-name.js\";\nimport requireTriggerTypes from \"../rules/require-trigger-types.js\";\nimport requireTrufflehogVerifiedResultsMode from \"../rules/require-trufflehog-verified-results-mode.js\";\nimport requireWorkflowCallInputType from \"../rules/require-workflow-call-input-type.js\";\nimport requireWorkflowCallOutputValue from \"../rules/require-workflow-call-output-value.js\";\nimport requireWorkflowConcurrency from \"../rules/require-workflow-concurrency.js\";\nimport requireWorkflowDispatchInputType from \"../rules/require-workflow-dispatch-input-type.js\";\nimport requireWorkflowInterfaceDescription from \"../rules/require-workflow-interface-description.js\";\nimport requireWorkflowPermissions from \"../rules/require-workflow-permissions.js\";\nimport requireWorkflowRunBranches from \"../rules/require-workflow-run-branches.js\";\nimport requireWorkflowTemplatePair from \"../rules/require-workflow-template-pair.js\";\nimport requireWorkflowTemplatePropertiesPair from \"../rules/require-workflow-template-properties-pair.js\";\nimport validTimeoutMinutes from \"../rules/valid-timeout-minutes.js\";\nimport validTriggerEvents from \"../rules/valid-trigger-events.js\";\n\n/** Strongly typed plugin rule registry keyed by unqualified rule name. */\nconst githubActionsRulesDefinition: {\n readonly \"action-name-casing\": typeof actionNameCasing;\n readonly \"job-id-casing\": typeof jobIdCasing;\n readonly \"max-jobs-per-action\": typeof maxJobsPerAction;\n readonly \"no-case-insensitive-input-id-collision\": typeof noCaseInsensitiveInputIdCollision;\n readonly \"no-codeql-autobuild-for-javascript-typescript\": typeof noCodeqlAutobuildForJavaScriptTypeScript;\n readonly \"no-codeql-javascript-typescript-split-language-matrix\": typeof noCodeqlJavascriptTypeScriptSplitLanguageMatrix;\n readonly \"no-composite-input-env-access\": typeof noCompositeInputEnvAccess;\n readonly \"no-deprecated-node-runtime\": typeof noDeprecatedNodeRuntime;\n readonly \"no-duplicate-composite-step-id\": typeof noDuplicateCompositeStepId;\n readonly \"no-empty-template-file-pattern\": typeof noEmptyTemplateFilePattern;\n readonly \"no-external-job\": typeof noExternalJob;\n readonly \"no-hardcoded-default-branch-in-template\": typeof noHardcodedDefaultBranchInTemplate;\n readonly \"no-icon-file-extension-in-template-icon-name\": typeof noIconFileExtensionInTemplateIconName;\n readonly \"no-inherit-secrets\": typeof noInheritSecrets;\n readonly \"no-invalid-concurrency-context\": typeof noInvalidConcurrencyContext;\n readonly \"no-invalid-key\": typeof noInvalidKey;\n readonly \"no-invalid-reusable-workflow-job-key\": typeof noInvalidReusableWorkflowJobKey;\n readonly \"no-invalid-template-file-pattern-regex\": typeof noInvalidTemplateFilePatternRegex;\n readonly \"no-invalid-workflow-call-output-value\": typeof noInvalidWorkflowCallOutputValue;\n readonly \"no-overlapping-dependabot-directories\": typeof noOverlappingDependabotDirectories;\n readonly \"no-path-separators-in-template-icon-name\": typeof noPathSeparatorsInTemplateIconName;\n readonly \"no-post-if-without-post\": typeof noPostIfWithoutPost;\n readonly \"no-pr-head-checkout-in-pull-request-target\": typeof noPrHeadCheckoutInPullRequestTarget;\n readonly \"no-pre-if-without-pre\": typeof noPreIfWithoutPre;\n readonly \"no-required-input-with-default\": typeof noRequiredInputWithDefault;\n readonly \"no-secrets-in-if\": typeof noSecretsInIf;\n readonly \"no-self-hosted-runner-on-fork-pr-events\": typeof noSelfHostedRunnerOnForkPrEvents;\n readonly \"no-subdirectory-template-file-pattern\": typeof noSubdirectoryTemplateFilePattern;\n readonly \"no-template-placeholder-in-non-template-workflow\": typeof noTemplatePlaceholderInNonTemplateWorkflow;\n readonly \"no-top-level-env\": typeof noTopLevelEnv;\n readonly \"no-top-level-permissions\": typeof noTopLevelPermissions;\n readonly \"no-universal-template-file-pattern\": typeof noUniversalTemplateFilePattern;\n readonly \"no-unknown-dependabot-multi-ecosystem-group\": typeof noUnknownDependabotMultiEcosystemGroup;\n readonly \"no-unknown-input-reference-in-composite\": typeof noUnknownInputReferenceInComposite;\n readonly \"no-unknown-job-output-reference\": typeof noUnknownJobOutputReference;\n readonly \"no-unknown-step-reference\": typeof noUnknownStepReference;\n readonly \"no-untrusted-input-in-run\": typeof noUntrustedInputInRun;\n readonly \"no-unused-dependabot-enable-beta-ecosystems\": typeof noUnusedDependabotEnableBetaEcosystems;\n readonly \"no-unused-input-in-composite\": typeof noUnusedInputInComposite;\n readonly \"no-write-all-permissions\": typeof noWriteAllPermissions;\n readonly \"pin-action-shas\": typeof pinActionShas;\n readonly \"prefer-action-yml\": typeof preferActionYml;\n readonly \"prefer-fail-fast\": typeof preferFailFast;\n readonly \"prefer-file-extension\": typeof preferFileExtension;\n readonly \"prefer-inputs-context\": typeof preferInputsContext;\n readonly \"prefer-step-uses-style\": typeof preferStepUsesStyle;\n readonly \"prefer-template-yml-extension\": typeof preferTemplateYmlExtension;\n readonly \"require-action-name\": typeof requireActionName;\n readonly \"require-action-run-name\": typeof requireActionRunName;\n readonly \"require-checkout-before-local-action\": typeof requireCheckoutBeforeLocalAction;\n readonly \"require-codeql-actions-read\": typeof requireCodeqlActionsRead;\n readonly \"require-codeql-branch-filters\": typeof requireCodeqlBranchFilters;\n readonly \"require-codeql-category-when-language-matrix\": typeof requireCodeqlCategoryWhenLanguageMatrix;\n readonly \"require-codeql-pull-request-trigger\": typeof requireCodeqlPullRequestTrigger;\n readonly \"require-codeql-schedule\": typeof requireCodeqlSchedule;\n readonly \"require-codeql-security-events-write\": typeof requireCodeqlSecurityEventsWrite;\n readonly \"require-composite-step-name\": typeof requireCompositeStepName;\n readonly \"require-dependabot-assignees\": typeof requireDependabotAssignees;\n readonly \"require-dependabot-automation-permissions\": typeof requireDependabotAutomationPermissions;\n readonly \"require-dependabot-automation-pull-request-trigger\": typeof requireDependabotAutomationPullRequestTrigger;\n readonly \"require-dependabot-bot-actor-guard\": typeof requireDependabotBotActorGuard;\n readonly \"require-dependabot-commit-message-include-scope\": typeof requireDependabotCommitMessageIncludeScope;\n readonly \"require-dependabot-commit-message-prefix\": typeof requireDependabotCommitMessagePrefix;\n readonly \"require-dependabot-commit-message-prefix-development\": typeof requireDependabotCommitMessagePrefixDevelopment;\n readonly \"require-dependabot-cooldown\": typeof requireDependabotCooldown;\n readonly \"require-dependabot-directory\": typeof requireDependabotDirectory;\n readonly \"require-dependabot-github-actions-directory-root\": typeof requireDependabotGithubActionsDirectoryRoot;\n readonly \"require-dependabot-labels\": typeof requireDependabotLabels;\n readonly \"require-dependabot-open-pull-requests-limit\": typeof requireDependabotOpenPullRequestsLimit;\n readonly \"require-dependabot-package-ecosystem\": typeof requireDependabotPackageEcosystem;\n readonly \"require-dependabot-patterns-for-multi-ecosystem-group\": typeof requireDependabotPatternsForMultiEcosystemGroup;\n readonly \"require-dependabot-schedule-cronjob\": typeof requireDependabotScheduleCronjob;\n readonly \"require-dependabot-schedule-interval\": typeof requireDependabotScheduleInterval;\n readonly \"require-dependabot-schedule-time\": typeof requireDependabotScheduleTime;\n readonly \"require-dependabot-schedule-timezone\": typeof requireDependabotScheduleTimezone;\n readonly \"require-dependabot-target-branch\": typeof requireDependabotTargetBranch;\n readonly \"require-dependabot-updates\": typeof requireDependabotUpdates;\n readonly \"require-dependabot-version\": typeof requireDependabotVersion;\n readonly \"require-dependabot-versioning-strategy-for-npm\": typeof requireDependabotVersioningStrategyForNpm;\n readonly \"require-dependency-review-action\": typeof requireDependencyReviewAction;\n readonly \"require-dependency-review-fail-on-severity\": typeof requireDependencyReviewFailOnSeverity;\n readonly \"require-dependency-review-permissions-contents-read\": typeof requireDependencyReviewPermissionsContentsRead;\n readonly \"require-dependency-review-pull-request-trigger\": typeof requireDependencyReviewPullRequestTrigger;\n readonly \"require-fetch-metadata-github-token\": typeof requireFetchMetadataGithubToken;\n readonly \"require-job-name\": typeof requireJobName;\n readonly \"require-job-step-name\": typeof requireJobStepName;\n readonly \"require-job-timeout-minutes\": typeof requireJobTimeoutMinutes;\n readonly \"require-merge-group-trigger\": typeof requireMergeGroupTrigger;\n readonly \"require-pull-request-target-branches\": typeof requirePullRequestTargetBranches;\n readonly \"require-run-step-shell\": typeof requireRunStepShell;\n readonly \"require-sarif-upload-security-events-write\": typeof requireSarifUploadSecurityEventsWrite;\n readonly \"require-scorecard-results-format-sarif\": typeof requireScorecardResultsFormatSarif;\n readonly \"require-scorecard-upload-sarif-step\": typeof requireScorecardUploadSarifStep;\n readonly \"require-secret-scan-contents-read\": typeof requireSecretScanContentsRead;\n readonly \"require-secret-scan-fetch-depth-zero\": typeof requireSecretScanFetchDepthZero;\n readonly \"require-secret-scan-schedule\": typeof requireSecretScanSchedule;\n readonly \"require-template-categories\": typeof requireTemplateCategories;\n readonly \"require-template-file-patterns\": typeof requireTemplateFilePatterns;\n readonly \"require-template-icon-file-exists\": typeof requireTemplateIconFileExists;\n readonly \"require-template-icon-name\": typeof requireTemplateIconName;\n readonly \"require-template-workflow-name\": typeof requireTemplateWorkflowName;\n readonly \"require-trigger-types\": typeof requireTriggerTypes;\n readonly \"require-trufflehog-verified-results-mode\": typeof requireTrufflehogVerifiedResultsMode;\n readonly \"require-workflow-call-input-type\": typeof requireWorkflowCallInputType;\n readonly \"require-workflow-call-output-value\": typeof requireWorkflowCallOutputValue;\n readonly \"require-workflow-concurrency\": typeof requireWorkflowConcurrency;\n readonly \"require-workflow-dispatch-input-type\": typeof requireWorkflowDispatchInputType;\n readonly \"require-workflow-interface-description\": typeof requireWorkflowInterfaceDescription;\n readonly \"require-workflow-permissions\": typeof requireWorkflowPermissions;\n readonly \"require-workflow-run-branches\": typeof requireWorkflowRunBranches;\n readonly \"require-workflow-template-pair\": typeof requireWorkflowTemplatePair;\n readonly \"require-workflow-template-properties-pair\": typeof requireWorkflowTemplatePropertiesPair;\n readonly \"valid-timeout-minutes\": typeof validTimeoutMinutes;\n readonly \"valid-trigger-events\": typeof validTriggerEvents;\n} = {\n \"action-name-casing\": actionNameCasing,\n \"job-id-casing\": jobIdCasing,\n \"max-jobs-per-action\": maxJobsPerAction,\n \"no-case-insensitive-input-id-collision\": noCaseInsensitiveInputIdCollision,\n \"no-codeql-autobuild-for-javascript-typescript\":\n noCodeqlAutobuildForJavaScriptTypeScript,\n \"no-codeql-javascript-typescript-split-language-matrix\":\n noCodeqlJavascriptTypeScriptSplitLanguageMatrix,\n \"no-composite-input-env-access\": noCompositeInputEnvAccess,\n \"no-deprecated-node-runtime\": noDeprecatedNodeRuntime,\n \"no-duplicate-composite-step-id\": noDuplicateCompositeStepId,\n \"no-empty-template-file-pattern\": noEmptyTemplateFilePattern,\n \"no-external-job\": noExternalJob,\n \"no-hardcoded-default-branch-in-template\":\n noHardcodedDefaultBranchInTemplate,\n \"no-icon-file-extension-in-template-icon-name\":\n noIconFileExtensionInTemplateIconName,\n \"no-inherit-secrets\": noInheritSecrets,\n \"no-invalid-concurrency-context\": noInvalidConcurrencyContext,\n \"no-invalid-key\": noInvalidKey,\n \"no-invalid-reusable-workflow-job-key\": noInvalidReusableWorkflowJobKey,\n \"no-invalid-template-file-pattern-regex\": noInvalidTemplateFilePatternRegex,\n \"no-invalid-workflow-call-output-value\": noInvalidWorkflowCallOutputValue,\n \"no-overlapping-dependabot-directories\": noOverlappingDependabotDirectories,\n \"no-path-separators-in-template-icon-name\":\n noPathSeparatorsInTemplateIconName,\n \"no-post-if-without-post\": noPostIfWithoutPost,\n \"no-pr-head-checkout-in-pull-request-target\":\n noPrHeadCheckoutInPullRequestTarget,\n \"no-pre-if-without-pre\": noPreIfWithoutPre,\n \"no-required-input-with-default\": noRequiredInputWithDefault,\n \"no-secrets-in-if\": noSecretsInIf,\n \"no-self-hosted-runner-on-fork-pr-events\": noSelfHostedRunnerOnForkPrEvents,\n \"no-subdirectory-template-file-pattern\": noSubdirectoryTemplateFilePattern,\n \"no-template-placeholder-in-non-template-workflow\":\n noTemplatePlaceholderInNonTemplateWorkflow,\n \"no-top-level-env\": noTopLevelEnv,\n \"no-top-level-permissions\": noTopLevelPermissions,\n \"no-universal-template-file-pattern\": noUniversalTemplateFilePattern,\n \"no-unknown-dependabot-multi-ecosystem-group\":\n noUnknownDependabotMultiEcosystemGroup,\n \"no-unknown-input-reference-in-composite\":\n noUnknownInputReferenceInComposite,\n \"no-unknown-job-output-reference\": noUnknownJobOutputReference,\n \"no-unknown-step-reference\": noUnknownStepReference,\n \"no-untrusted-input-in-run\": noUntrustedInputInRun,\n \"no-unused-dependabot-enable-beta-ecosystems\":\n noUnusedDependabotEnableBetaEcosystems,\n \"no-unused-input-in-composite\": noUnusedInputInComposite,\n \"no-write-all-permissions\": noWriteAllPermissions,\n \"pin-action-shas\": pinActionShas,\n \"prefer-action-yml\": preferActionYml,\n \"prefer-fail-fast\": preferFailFast,\n \"prefer-file-extension\": preferFileExtension,\n \"prefer-inputs-context\": preferInputsContext,\n \"prefer-step-uses-style\": preferStepUsesStyle,\n \"prefer-template-yml-extension\": preferTemplateYmlExtension,\n \"require-action-name\": requireActionName,\n \"require-action-run-name\": requireActionRunName,\n \"require-checkout-before-local-action\": requireCheckoutBeforeLocalAction,\n \"require-codeql-actions-read\": requireCodeqlActionsRead,\n \"require-codeql-branch-filters\": requireCodeqlBranchFilters,\n \"require-codeql-category-when-language-matrix\":\n requireCodeqlCategoryWhenLanguageMatrix,\n \"require-codeql-pull-request-trigger\": requireCodeqlPullRequestTrigger,\n \"require-codeql-schedule\": requireCodeqlSchedule,\n \"require-codeql-security-events-write\": requireCodeqlSecurityEventsWrite,\n \"require-composite-step-name\": requireCompositeStepName,\n \"require-dependabot-assignees\": requireDependabotAssignees,\n \"require-dependabot-automation-permissions\":\n requireDependabotAutomationPermissions,\n \"require-dependabot-automation-pull-request-trigger\":\n requireDependabotAutomationPullRequestTrigger,\n \"require-dependabot-bot-actor-guard\": requireDependabotBotActorGuard,\n \"require-dependabot-commit-message-include-scope\":\n requireDependabotCommitMessageIncludeScope,\n \"require-dependabot-commit-message-prefix\":\n requireDependabotCommitMessagePrefix,\n \"require-dependabot-commit-message-prefix-development\":\n requireDependabotCommitMessagePrefixDevelopment,\n \"require-dependabot-cooldown\": requireDependabotCooldown,\n \"require-dependabot-directory\": requireDependabotDirectory,\n \"require-dependabot-github-actions-directory-root\":\n requireDependabotGithubActionsDirectoryRoot,\n \"require-dependabot-labels\": requireDependabotLabels,\n \"require-dependabot-open-pull-requests-limit\":\n requireDependabotOpenPullRequestsLimit,\n \"require-dependabot-package-ecosystem\": requireDependabotPackageEcosystem,\n \"require-dependabot-patterns-for-multi-ecosystem-group\":\n requireDependabotPatternsForMultiEcosystemGroup,\n \"require-dependabot-schedule-cronjob\": requireDependabotScheduleCronjob,\n \"require-dependabot-schedule-interval\": requireDependabotScheduleInterval,\n \"require-dependabot-schedule-time\": requireDependabotScheduleTime,\n \"require-dependabot-schedule-timezone\": requireDependabotScheduleTimezone,\n \"require-dependabot-target-branch\": requireDependabotTargetBranch,\n \"require-dependabot-updates\": requireDependabotUpdates,\n \"require-dependabot-version\": requireDependabotVersion,\n \"require-dependabot-versioning-strategy-for-npm\":\n requireDependabotVersioningStrategyForNpm,\n \"require-dependency-review-action\": requireDependencyReviewAction,\n \"require-dependency-review-fail-on-severity\":\n requireDependencyReviewFailOnSeverity,\n \"require-dependency-review-permissions-contents-read\":\n requireDependencyReviewPermissionsContentsRead,\n \"require-dependency-review-pull-request-trigger\":\n requireDependencyReviewPullRequestTrigger,\n \"require-fetch-metadata-github-token\": requireFetchMetadataGithubToken,\n \"require-job-name\": requireJobName,\n \"require-job-step-name\": requireJobStepName,\n \"require-job-timeout-minutes\": requireJobTimeoutMinutes,\n \"require-merge-group-trigger\": requireMergeGroupTrigger,\n \"require-pull-request-target-branches\": requirePullRequestTargetBranches,\n \"require-run-step-shell\": requireRunStepShell,\n \"require-sarif-upload-security-events-write\":\n requireSarifUploadSecurityEventsWrite,\n \"require-scorecard-results-format-sarif\":\n requireScorecardResultsFormatSarif,\n \"require-scorecard-upload-sarif-step\": requireScorecardUploadSarifStep,\n \"require-secret-scan-contents-read\": requireSecretScanContentsRead,\n \"require-secret-scan-fetch-depth-zero\": requireSecretScanFetchDepthZero,\n \"require-secret-scan-schedule\": requireSecretScanSchedule,\n \"require-template-categories\": requireTemplateCategories,\n \"require-template-file-patterns\": requireTemplateFilePatterns,\n \"require-template-icon-file-exists\": requireTemplateIconFileExists,\n \"require-template-icon-name\": requireTemplateIconName,\n \"require-template-workflow-name\": requireTemplateWorkflowName,\n \"require-trigger-types\": requireTriggerTypes,\n \"require-trufflehog-verified-results-mode\":\n requireTrufflehogVerifiedResultsMode,\n \"require-workflow-call-input-type\": requireWorkflowCallInputType,\n \"require-workflow-call-output-value\": requireWorkflowCallOutputValue,\n \"require-workflow-concurrency\": requireWorkflowConcurrency,\n \"require-workflow-dispatch-input-type\": requireWorkflowDispatchInputType,\n \"require-workflow-interface-description\":\n requireWorkflowInterfaceDescription,\n \"require-workflow-permissions\": requireWorkflowPermissions,\n \"require-workflow-run-branches\": requireWorkflowRunBranches,\n \"require-workflow-template-pair\": requireWorkflowTemplatePair,\n \"require-workflow-template-properties-pair\":\n requireWorkflowTemplatePropertiesPair,\n \"valid-timeout-minutes\": validTimeoutMinutes,\n \"valid-trigger-events\": validTriggerEvents,\n} satisfies Record<string, Rule.RuleModule>;\n\n/** Strongly typed plugin rule registry keyed by unqualified rule name. */\nexport const githubActionsRules: typeof githubActionsRulesDefinition =\n githubActionsRulesDefinition;\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAMA;;;;;iBAA4B;;;ACN5B;AAAA,EACI,SAAW;AAAA,EACX,MAAQ;AAAA,EACR,SAAW;AAAA,EACX,SAAW;AAAA,EACX,aAAe;AAAA,EACf,UAAY;AAAA,IACR;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACJ;AAAA,EACA,UAAY;AAAA,EACZ,MAAQ;AAAA,IACJ,KAAO;AAAA,IACP,OAAS;AAAA,EACb;AAAA,EACA,YAAc;AAAA,IACV,MAAQ;AAAA,IACR,KAAO;AAAA,EACX;AAAA,EACA,SAAW;AAAA,EACX,QAAU;AAAA,EACV,cAAgB;AAAA,IACZ;AAAA,MACI,MAAQ;AAAA,MACR,OAAS;AAAA,MACT,KAAO;AAAA,IACX;AAAA,EACJ;AAAA,EACA,aAAe;AAAA,EACf,MAAQ;AAAA,EACR,SAAW;AAAA,IACP,KAAK;AAAA,MACD,QAAU;AAAA,QACN,OAAS;AAAA,QACT,SAAW;AAAA,MACf;AAAA,MACA,SAAW;AAAA,QACP,OAAS;AAAA,QACT,SAAW;AAAA,MACf;AAAA,MACA,SAAW;AAAA,IACf;AAAA,IACA,kBAAkB;AAAA,EACtB;AAAA,EACA,MAAQ;AAAA,EACR,OAAS;AAAA,EACT,OAAS;AAAA,IACL;AAAA,IACA;AAAA,IACA;AAAA,EACJ;AAAA,EACA,YAAc;AAAA,IACV;AAAA,EACJ;AAAA,EACA,SAAW;AAAA,IACP,OAAS;AAAA,IACT,aAAa;AAAA,IACb,eAAe;AAAA,IACf,0BAA0B;AAAA,IAC1B,gCAAgC;AAAA,IAChC,6BAA6B;AAAA,IAC7B,mCAAmC;AAAA,IACnC,mBAAmB;AAAA,IACnB,2BAA2B;AAAA,I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QAAM,UAAU,CAAA;AAEhB,aAAW,cAAc,0BAA0B;AAC/C,UAAM,WAAW,kCAAkC,UAAU;AAE7D,YAAQ,UAAU,IAAI,wBAClB;MACI,OAAO,CAAC,GAAG,SAAS,KAAK;MACzB,MAAM,SAAS;MACf,OAAO,cAAc,wBAAwB,UAAU,CAAC;OAE5D,gBAAgB;EAExB;AAEA,SAAO;AACX;AAGA,IAAM,uBACF,qCAAoC;AAGxC,IAAM,sBAAmD;EACrD,SAAS;EACT,MAAM;IACF,MAAM;IACN,WAAW;IACX,SAAS,kBAAkB,eAAW;;EAE1C,YAAY,CAAA;EACZ,OAAO;;AAOX,IAAA,iBAAe;",
|
|
6
|
+
"names": ["rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "import_node_path", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "isReusableWorkflowJob", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "jobsOutputReferencePattern", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "import_node_path", "rule", "visitStringScalars", "rule", "rule", "rule", "rule", "rule", "isCheckoutActionReference", "isLocalActionReference", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "hasConfiguredBranchFilter", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "import_node_path", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "rule", "groupValue", "rule", "rule", "rule", "hasConfiguredBranchFilter", "rule", "import_node_fs", "rule", "import_node_fs", "rule", "rule", "rule", "rule", "presetRuleNamesByConfig"]
|
|
7
7
|
}
|