Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Integration with pyproject.toml for Formatting style #708

Closed
samypr100 opened this issue Apr 15, 2019 · 8 comments
Closed

Integration with pyproject.toml for Formatting style #708

samypr100 opened this issue Apr 15, 2019 · 8 comments

Comments

@samypr100
Copy link

PEP 518 defines pyproject.toml as a configuration file for software packages to use to specify their build dependencies.

Particularly, it provides an alternative to setup.cfg.

For example, a section in pyproject.toml could look like:

[tool.yapf]
based_on_style = "pep8"
spaces_before_comment = 4
split_before_logical_operator = true

Initially, yapf could look for a pyproject.toml on the project and determine formatting style settings from that similar to how it does with setup.cfg.

This request would be an additional method to the currently supported methods of specifying yapf settings. Any chance we could see this in yapf?

@JohnMoutafis
Copy link

Is this going to be implemented?
If yes, what is the process state atm?

@dclong
Copy link

dclong commented Dec 31, 2020

Looking forward to this feature.

@bwendling
Copy link
Member

I don't see an issue with doing this. I don't have any knowledge about pyproject.toml, but I'll look into it. If someone wanted to submit a PR, we would accept it :)

@dclong
Copy link

dclong commented Mar 15, 2021

Does yapf support configure .yapfignore in pyproject.toml too?

@hirosassa
Copy link
Contributor

@dclong No, I implemented only formatting style configuration in the PR above.

@dclong
Copy link

dclong commented Mar 15, 2021

@hirosassa Thank you for the info! I've opened an issue #904 requesting support yapf ignore configuration in pyproject.toml.

@KuSi833
Copy link

KuSi833 commented Jul 9, 2021

I believe this issue can be closed since it was solved with PR #893?

@hirosassa
Copy link
Contributor

@KuSi833 Thanks!

@gwelymernans Would you close this issue?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants