Skip to content
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

Cannot find ktlint-cli #2388

Closed
6 tasks
tobiasKaminsky opened this issue Jan 8, 2025 · 2 comments
Closed
6 tasks

Cannot find ktlint-cli #2388

tobiasKaminsky opened this issue Jan 8, 2025 · 2 comments

Comments

@tobiasKaminsky
Copy link

Similar to #993 our Android repo fails with:

 * What went wrong:
Execution failed for task ':library:spotlessKotlin'.
> You need to add a repository containing the '[com.pinterest.ktlint:ktlint-cli:1.5.0]' artifact in 'library/build.gradle'.
  E.g.: 'repositories { mavenCentral() }'

Repo: https://github.com/nextcloud/android-library/blob/master/library/build.gradle#L226
Spotless: 7.0.0

If you are submitting a bug, please include the following:

  • summary of problem
  • Gradle or Maven version
  • spotless version
  • operating system and version
  • copy-paste your full Spotless configuration block(s), and a link to a public git repo that reproduces the problem if possible
  • copy-paste the full content of any console errors emitted by gradlew spotless[Apply/Check] --stacktrace

If you're just submitting a feature request or question, no need for the above.

@nedtwigg
Copy link
Member

nedtwigg commented Jan 8, 2025

I cloned the project, ran spotlessApply, and it worked. Any hints on how I can reproduce?

@tobiasKaminsky
Copy link
Author

In the meantime I found out, that I need to run
./gradlew --console=plain --dependency-verification lenient -q --write-verification-metadata sha256,pgp spotlessCheck
so that the dependencies are correctly written down.

I think this was the problem, but as the error message was leading into another direction, I asked for help.

Thank you for your help!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants