Skip to content

Loader of Black to ensure Athenian's code formatting conventions.

License

Notifications You must be signed in to change notification settings

athenianco/chorny

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

33 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

chorny

Chorny (russian: чёрный) is a loader of Black that patches code on the fly to change the formatting to satisfy Athenian's conventions.

So far, the only difference with the original rules is how magic trailing commas work. Chorny prevents new line expansion by the magic trailing comma for parentheses unless the code is a function signature. Example:

async def foo(self, arg, other,):
    pass

becomes

async def foo(
    self,
    arg,
    other,
):
    pass

However,

foo(
    1, "one,
)

stays intact.

Installation

pip install chorny

Usage

chorny patches and launches black and should be used the same way.

License

MIT, see LICENSE.

About

Loader of Black to ensure Athenian's code formatting conventions.

Resources

License

Stars

Watchers

Forks

Contributors 4

  •  
  •  
  •  
  •  

Languages