I use SonarQube for a Java project.
I want to have a violation when a given static method from a library is used.
Is there a way to do that in the UI, or shall I resort to custom java code as described in https://github.com/SonarSource/sonar-custom-rules-examples/ ?
You can use squid:S2253, which is a template rule, to set up a rule that raises an issue when your method is called.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With