> ## Documentation Index
> Fetch the complete documentation index at: https://docs.qlty.sh/llms.txt
> Use this file to discover all available pages before exploring further.

# Swift Language Support

## Summary

<table>
  <thead>
    <tr>
      <th>Feature</th>
      <th>Status</th>
      <th>Notes</th>
    </tr>
  </thead>

  <tbody>
    <tr>
      <td>[Maintainability](https://docs.qlty.sh/cloud/maintainability/metrics.md)</td>
      <td>✔</td>
      <td>Complexity, duplication, code smells</td>
    </tr>

    <tr>
      <td>[Linting](https://docs.qlty.sh/linting.md)</td>
      <td>✔</td>

      <td />
    </tr>

    <tr>
      <td>[Auto-formatting](https://docs.qlty.sh/auto-formatting.md)</td>
      <td>✔</td>

      <td />
    </tr>

    <tr>
      <td>[Custom checks](https://docs.qlty.sh/custom-checks.md)</td>
      <td>✔</td>

      <td />
    </tr>

    <tr>
      <td>[Security scanning](https://docs.qlty.sh/cloud/security/framework.md)</td>
      <td>✔</td>
      <td>AppSec, dependencies, and secrets</td>
    </tr>

    <tr>
      <td>[Code metrics](https://docs.qlty.sh/cloud/maintainability/metrics.md)</td>
      <td>✔</td>

      <td />
    </tr>

    <tr>
      <td>[Code coverage](https://docs.qlty.sh/coverage.md)</td>
      <td>✔</td>

      <td />
    </tr>
  </tbody>
</table>

## Details

<table>
  <tbody>
    <tr>
      <td>Maintainability</td>

      <td />

      <td />
    </tr>

    <tr>
      <td>[Complexity](https://docs.qlty.sh/complexity.md)</td>
      <td>✔</td>
      <td>Aka cognitive complexity</td>
    </tr>

    <tr>
      <td>[Cyclomatic complexity](https://docs.qlty.sh/complexity.md#difference-from-cyclomatic-complexity)</td>
      <td>✔</td>

      <td />
    </tr>

    <tr>
      <td>[Identical code duplication](https://docs.qlty.sh/duplication.md)</td>
      <td>✔</td>

      <td />
    </tr>

    <tr>
      <td>[Similar code duplication](https://docs.qlty.sh/duplication.md)</td>
      <td>✔</td>

      <td />
    </tr>

    <tr>
      <td>[Code smells](https://docs.qlty.sh/code-smells.md)</td>
      <td>✔</td>

      <td />
    </tr>

    <tr>
      <td>Linters</td>

      <td />

      <td />
    </tr>

    <tr>
      <td>[SwiftLint](https://github.com/realm/SwiftLint)\*</td>
      <td>✔</td>
      <td>Tool to enforce Swift style and conventions.</td>
    </tr>

    <tr>
      <td>[StringsLint](https://github.com/dral3x/StringsLint)\*</td>
      <td>✔</td>
      <td>Ensures localized strings are complete and not unused</td>
    </tr>

    <tr>
      <td>Auto-formatters</td>

      <td />

      <td />
    </tr>

    <tr>
      <td>[SwiftFormat](https://github.com/nicklockwood/SwiftFormat)\*</td>
      <td>✔</td>
      <td>CLI (and Xcode Extension) for formatting Swift code</td>
    </tr>

    <tr>
      <td>Custom checks</td>

      <td />

      <td />
    </tr>

    <tr>
      <td>[Semgrep](https://semgrep.dev)</td>
      <td>✔</td>

      <td />
    </tr>

    <tr>
      <td>[ripgrep](https://github.com/BurntSushi/ripgrep)</td>
      <td>✔</td>

      <td />
    </tr>

    <tr>
      <td>Security scanning</td>

      <td />

      <td />
    </tr>

    <tr>
      <td>[Gitleaks](https://gitleaks.io/)</td>
      <td>✔</td>
      <td>Secrets scanning</td>
    </tr>

    <tr>
      <td>[Semgrep](https://semgrep.dev)</td>
      <td>✔</td>
      <td>AppSec (SAST)</td>
    </tr>

    <tr>
      <td>[Trivy](https://trivy.dev)</td>
      <td>✔</td>
      <td>Dependency scanning (SCA) for CocoaPods and Swift package managers</td>
    </tr>

    <tr>
      <td>[TruffleHog](https://trufflesecurity.com/trufflehog)</td>
      <td>✔</td>
      <td>Secrets scanning</td>
    </tr>

    <tr>
      <td>Code coverage</td>

      <td />

      <td />
    </tr>

    <tr>
      <td>[slather](https://github.com/SlatherOrg/slather)</td>
      <td>✔</td>

      <td />
    </tr>

    <tr>
      <td>Cobertura coverage format</td>
      <td>✔</td>

      <td />
    </tr>
  </tbody>
</table>

> [!NOTE]
>
> * These plugins only run on macOS and are available via the Qlty CLI. They are not available on
>   Qlty Cloud which runs on Linux.

## File extensions

By default, Swift files are defined as:

```
[file_types.swift]
globs = ["*.swift"]
```

These patterns can be overridden from `qlty.toml`.

## Supported Swift versions

We officially support Swift 6+ and later for maintainability checks and code coverage. Each plugin may have its own version requirements.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.