-
Notifications
You must be signed in to change notification settings - Fork 21
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
Support c extension for cpplint.py #29
Comments
I didn't know this option, thanks for the hint! However, even with adding Also, having to modify this list of file extensions manually for every single checker (there are around 60!) is more than cumbersome... You are right, cpplint.py is meant for C++, as is the Google C++ Style Guide. We use the Google Style Guide for our C++ projects, but we also have a fair amount of C projects and don't want to introduce a new coding style for those. Since C is (more or less) a subset of C++, the rules of the Google Style Guide can also be applied fairly well to C code. All we need is a style checker tool, because without it any rule is useless. It would be a pity if we can't use cpplint.py, just because of the file extension... |
The same is true for .hpp file. cpplint is not called.
There is some hard codded extension restriction, even if the documentation say that EVERY file save is pass to cpplint. The correct way is to remove any existing restriction, has cpplint olready have a configurations file for this. |
It doesn't seem to be possible to run cpplint.py on *.c files with this plugin. On the command line I can run
cpplint.py --extensions=c,h foo.c
, but I can't give an argument to cpplint.py in the CppStyle settings dialog.I even tried to make cpplint.py natively support the c extension, by amending the variable
_valid_extensions
in the Python code. Then it works on the command line even without the--extensions=
argument. But strangely, CppStyle still doesn't work with *.c files.Are there any plans to support this, or is there any possible workaround?
The text was updated successfully, but these errors were encountered: