diff --git a/extension-verifier/README.md b/extension-verifier/README.md index db03163..1313d64 100644 --- a/extension-verifier/README.md +++ b/extension-verifier/README.md @@ -15,6 +15,7 @@ Validates and formats Shopware extensions using shopware-cli. | `version` | The extension verifier version to use | No | `latest` | | `action` | The action to run (`check` or `format`) | Yes | `check` | | `check-against` | The version to check against | No | `highest` | +| `exclude` | Comma-separated list of tools to exclude from the check (e.g. `phpstan,eslint`) | No | *(none)* | ## Usage @@ -39,6 +40,17 @@ jobs: check-against: v6.6.0.0 ``` +### Exclude specific tools + +```yaml +jobs: + verify: + uses: shopware/github-actions/extension-verifier@main + with: + action: check + exclude: phpstan,eslint +``` + ### Format extension (dry-run) ```yaml diff --git a/extension-verifier/action.yml b/extension-verifier/action.yml index 095beb9..146315a 100644 --- a/extension-verifier/action.yml +++ b/extension-verifier/action.yml @@ -17,6 +17,10 @@ inputs: description: "The version to check against" required: false default: "highest" + exclude: + description: "Comma-separated list of tools to exclude from the check (e.g. phpstan,eslint)" + required: false + default: "" runs: using: "composite" @@ -26,7 +30,15 @@ runs: - name: Run verifier if: inputs.action == 'check' shell: bash - run: shopware-cli extension validate --full --check-against ${{ inputs.check-against }} . + env: + CHECK_AGAINST: ${{ inputs.check-against }} + EXCLUDE: ${{ inputs.exclude }} + run: | + ARGS=(--full --check-against "${CHECK_AGAINST}") + if [[ -n "${EXCLUDE}" ]]; then + ARGS+=("--exclude=${EXCLUDE}") + fi + shopware-cli extension validate "${ARGS[@]}" . - name: Run formatter if: inputs.action == 'format' shell: bash