-
Notifications
You must be signed in to change notification settings - Fork 24
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
Rules from Compose ruleset are not (properly) executed #425
Comments
Rule id So try |
it's actually a config from ktlint https://github.com/pinterest/ktlint/blob/master/CHANGELOG.md#-features-1 and it works when running ktlint from the command line. it was your PR 🙂 pinterest/ktlint#2275 |
Lol, I totally forgot about that already. Could it be that you still are running version '0.13.0' of the plugin? That one uses an old ktlint version (0.48). New version of plugin is on its way. |
no, I downloaded the 0.20.0-beta-6 from the beta channel. |
And after updating to 0.20.0 I don't see any "warnings"/"errors" for a custom rule set in the IDE. formatting works fine but it does not show any Also the idea.log does not show any outputs anymore - are they disabled in this release? |
As user of the beta version you might need to re-enable the plugin in the preferences page of ktlint. Logging has indeed been disabled, but can be enabled again by setting environment variable Please also post the code snippet as code (jnstead of image) as well as your |
|
I have located a bug that might explain above. After adding or modifying the external ruleset that have to be run, the internal state of the plugin is not updated correctly. Can you restart you IDEA to see whether this resolves the problem? |
Did that couple of times already. Re-install, disable, changing config - all if these don't show any changes.
started it from the command line. it shows logs now. |
looks like the custom rule is at least loaded:
but no lint erros are showing up.
|
I can confirm that the Compose rules do not work in the plugin. The rules are properly provided to the KtLintRuleEngine, which also calls the specific rule. Unfortunately, I loose track when debuging the actual call to the Compose rule. To verify that custom ruleset work in the plugin, I have created a new custom ruleset with the
|
.editorconfig
custom config for custom ktlint rules
With |
Problem needs another fix in compose rules. See mrmans0n/compose-rules#190 |
When applying a custom lint rule via a jar from the settings, the plugin does not apply custom config from
.editconfig
.Use case:
Applying the custom Compose rules from
https://github.com/mrmans0n/compose-rules
and then enablingktlint_function_naming_ignore_when_annotated_with=Composable
from the local.editorconfig
does not disable the"ktlint:standard:function-naming"
"error" in the IDE.The text was updated successfully, but these errors were encountered: