-
Notifications
You must be signed in to change notification settings - Fork 453
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
YAPF configuration files are ignored #786
Comments
Atom Beautify has its own configuration system in order to be ubiquitous given that it supports a great many beautifiers for a plurality of languages. A specific particular configuration system, such as this or a .toolrc file, would be an enhancement. |
I understand. My particular problem was that |
@Glavin001 Does #671 address this issue or is it related? |
#671 fixes a bug, #669, in the YAPF beautifier within Atom Beautify caused by the return code from yapf being unexpected and Atom Beautify thinking it was an error return code, therefore throwing an error instead of beautifying. Currently it looks like there are no options officially supported by YAPF: https://github.com/Glavin001/atom-beautify/blob/master/src/beautifiers/yapf.coffee#L13 Here's the YAPF formatting stlye: https://github.com/google/yapf#formatting-style |
So the user would configure YAPF behavior through Atom Beautify and it would generate the configuration file for YAPF to read, nice. There are also some options that are common to both YAPF and autopep8, so they could be configured together. Here is a list of all the other options an YAPF configuration file accepts and here is an example file from my own project, since I did not find any other complete examples out there. |
Is this supposed to work now? Im an atom newb, just installed 1.11.2 with atom-beautify and set it to use yapf for python
I have a config file for yapf (~/.config/yapf/style):
But even simple things are not reformatted when I run beautify (e.g. max line length exceeded). No errors on the console either. |
You might want to checkout https://atom.io/packages/python-yapf |
@scubahub if you're having issues please provide your debugging information and we can try to help 😃 .
|
Any supported by For example
|
Is there any chance that custom config file could be provided, or there could be an option to allow |
Bumping again and pointing out that standard styles are most useful when on teams of people and you don't want to manually coordinate styles. |
Hey! I'm a little confused with the state of this feature. I tried using yapf within Atom today, but it seems to ignore the |
YAPF looks for certain configuration files containing user preferences regarding coding formatting. I have these configuration files in two places:
~/.config/yapf/style
and a.style.yapf
file in my project directory. However, when I run Atom Beautify in a Python file, using YAPF as my default formatting engine, it seems to ignore these files. I tried to setup YAPF from Atom Beautify settings page from inside Atom, but it only has settings forautopep8
, apparently.Here's my debug info. I configured YAPF to only break lines with more than 150 characters, but it is stilll breaking lines with ore than 79 characters, as it is its default.
The text was updated successfully, but these errors were encountered: