Pep8ify: Clean your code with ease
Pep8ify is a library that modifies python source code to conform to pep8.
Installation
This library currently works with python 2.7, 3.2, and 3.3.
To install pep8ify, simply:
$ pip install pep8ify
Usage
To print a diff of changes that pep8ify will make against a particular source file or directory:
$ pep8ify source_folder
To have those changes written to the files:
$ pep8ify -w source_folder
By default, this will create backup files for each file that will be changed. You can add the -n option to not create the backups. Please do not do this if you are not using a version control system. Although this code is well-tested, there are most likely bugs still.
For more options about running particular fixers, read the lib2to3 documentation. This library is built on top of that one.
Fixes
A list of the available fixers can be found with the following:
$ pep8ify -l Available transformations for the -f/--fix option: blank_lines compound_statements extraneous_whitespace imports_on_separate_lines indentation maximum_line_length missing_newline missing_whitespace tabs trailing_blank_lines trailing_whitespace whitespace_around_operator whitespace_before_inline_comment whitespace_before_parameters
All of these are set to run by default except for ‘maximum_line_length’. To run all fixes including ‘maximum_line_length’, run:
$ pep8ify -f all -f maximum_line_length example.py
Metadata
Release files for pep8ify 0.0.13
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| pep8ify-0.0.13.tar.gz | 14.8 kB | Without provenance | Details for pep8ify-0.0.13.tar.gz |
Release files / pep8ify-0.0.13.tar.gz
| Download URL | pep8ify-0.0.13.tar.gz |
|---|---|
| Size | 14.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
5c43b593af4ccbe2514f30f6714beb6e0a6f10dac0d5e14cdd536aeaf667832c
|
|
BLAKE2b-256 checksum How to use checksums |
557f654b4d1ecfe16e17329260058e87dad5ba1ecc4a7dd2aa2d71177fef1a32
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for pep8ify 0.0.13
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.