Android Lint: Is it possible to publish a lint check in a jar file (not aar) on Maven

446 Views Asked by At

I've made a lint check, simple java-only (kotlin) module, put it in a jar file and I plan to upload it to Maven Central as a jar. I started with publishing to maven local for test.

I put the required Lint-Registry-v2 in jar's manifest and I'm confident it's there. Lint check itself is there and working in tests, IssueRegistry is there. Then I mention this library in my Android project's build.gradle, in implementation clause, so it is on the classpath, and it is seen by Android Studio.

But still lint check doesn't work and isn't being seen by the lint tool: I try to find it with Run Inspection By Name... action and it's not there.

I even tried doing lintChecks 'my.lint.check:version' but it didn't work too.

Is it simply not possible? Do I have to distribute it through aar on Maven and is this the only option?

0

There are 0 best solutions below