# Autopep8

[**Autopep8**](https://github.com/hhatto/autopep8#readme) is a formatter for Python.

You can enable the Autopep8 formatter with:

```shell
trunk check enable autopep8
```

![autopep8 example output](https://577236045-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F61Ep9MrYBkJa0Yq3zS1s%2Fuploads%2Fgit-blob-561209d63d53d04b8eebe0088c35c2cfa2324dd7%2Fautopep8.gif?alt=media)

## Auto Enabling

Autopep8 will be auto-enabled if a `.pep8` config file is present.

## Settings

Autopep8 supports the following config files:

* `.pep8`

You can move these files to `.trunk/configs` and `trunk check` will still find them. See [Moving Linters](https://docs.trunk.io/code-quality/overview/configure-linters#moving-linters) for more info.

## Links

* [Autopep8 site](https://github.com/hhatto/autopep8#readme)
* Autopep8 Trunk Code Quality [integration source](https://github.com/trunk-io/plugins/tree/main/linters/autopep8)
* Trunk Code Quality's [open source plugins repo](https://github.com/trunk-io/plugins/tree/main)
