osl-incubator / scicookie

Cookiecutter template for a Python package.
https://osl-incubator.github.io/scicookie
Other
11 stars 18 forks source link

template: add ruff as auto-formatter tool #220

Closed xmnlab closed 3 weeks ago

xmnlab commented 4 months ago

It would be great to have ruff as a auto-formatter tool as an option (and maybe the default/first option as well) although black is more popular than ruff, ruff is much more complete, faster, and it is less opinionated (more flexible) than black

abhijeetSaroha commented 3 months ago

@xmnlab , Can you explain this issue more?

As of my understanding, ruff should be default option as auto-formatter tools.

It means, like in this image ruff should be automatically selected when this option comes.

Am i right?? or is it something else?

image

xmnlab commented 3 months ago

we should have two options for ruff: ruff (linter) and ruff (auto-formatter).

for OSL profile I am totally fine to remove black and keep just ruff (both ones) as default.

but for the base profile, we need to have all the options (black and both ruff options)

does it make sense?