Skip to content

w00tzenheimer/pythonformatter

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

91 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Python Formatter

Python Formatter is a Python library for reformatting Python code. Python Formatter works with Python 3.8 and under the guidelines of PEP8, but can be customized to the developer needs.

Installation and dependencies

  1. Clone the repository:

    git clone https://github.com/waadnakhleh/pythonformatter.git

  2. Install the dependencies: pip install -r requirements.txt

Usage

import _rewrite

_rewrite.rewrite(file_name)

Contributing

To contribute:

  1. Choose an issue from our issues list.
  2. Make sure you have the latest version.
  3. Make the changes.
  4. Run black.
  5. git add <changed_file>
  6. git commit -m "good commit message"
  7. git push origin <branch_name>

Coding guidelines.

We follow the set of rules provided by PEP8. But since we run black on the code just make sure to:

  1. Variable and function names should be in snake_case format.
  2. Class names should be in CamelCase format.
  3. Clear variable names (no ugly shortcuts).
  4. Document your code clearly using docstrings.

Useful links for contributors

  1. Python documentation for ast module
  2. Unofficial expanded documentation
  3. Useful article about Python ast module

License

We don't really have a license. If we ever compete with other code formatters it will be MIT.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%