question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Automatic Android support without specifying target "src/*/java/**/*.java"

See original GitHub issue

Does this support Android?


EDIT BY @nedtwigg, TOP COMMENT FOR VISIBILITY

On Android, your config file needs to look like this:

spotless {
  java {
    target "src/*/java/**/*.java"  // this line is needed
  }
}

We’d love a PR which fixes this, see this comment and this comment for what needs to be done.

Issue Analytics

  • State:open
  • Created 6 years ago
  • Reactions:2
  • Comments:22 (12 by maintainers)

github_iconTop GitHub Comments

2reactions
JLLeitschuhcommented, Nov 27, 2017

The target "**/*.java" is currently the cleanest solution without adding a dependency upon the gradle android plugin inside of spotless.

When you start having plugins dependent upon other plugins you end up tied to their breaking changes version bumping.

I’ve had to deal with this in my own plugin. https://github.com/JLLeitschuh/ktlint-gradle/pull/32

1reaction
nedtwiggcommented, Jun 30, 2020

Just a bump that src/*/java/**/*.java will perform far better than **/*.java. We heavily discourage **/blah wildcards.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Automatic Android support without specifying target "src/*/java ...
Automatic Android support without specifying target "src/*/java/**/*.java"
Read more >
MediaBrowserCompat.java - Google Git
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ... Creates a media browser for the specified media browse service.
Read more >
Enforcing Product Partition Interfaces | Android Open Source ...
To enable the Java interface enforcement, set PRODUCT_ENFORCE_PRODUCT_PARTITION_INTERFACE to true . (The value is automatically set to true when ...
Read more >
Error in fail: Auto-Configuration Error: Cannot find Java binary
... ERROR: Analysis of target '//mediapipe/examples/android/src/java/com/google/mediapipe/apps/handtrackinggpu:handtrackinggpu' failed; ...
Read more >
The Java Plugin - Gradle User Manual
Instead of applying it directly to your project, you should look into the java-library or application plugins or one of the supported alternative...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found