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

Introduce configFile property on DetektGenerateTask #5308

Merged
merged 1 commit into from
Sep 17, 2022

Conversation

3flex
Copy link
Member

@3flex 3flex commented Sep 17, 2022

This corrects a few issues:

  1. The config file parameter should refer to a single file, but it's currently a ConfigurableFileCollection. Replacing with RegularFileProperty is more correct as the task only generates a single file, not a collection of files.
  2. The config parameter is incorrectly annotated with @InputFiles, but task generates a file and doesn't use the values as an input at all.
  3. The config parameter is annotated @Optional. This doesn't make sense - if the task is run, it should generate a file, and the config file parameter must have a value to achieve this.

This deprecation is backwards compatible. When the config parameter is removed from the task there will be a small code clean up required.

@schalkms schalkms added this to the 1.22.0 milestone Sep 17, 2022
@schalkms schalkms merged commit f5be0d8 into detekt:main Sep 17, 2022
@3flex 3flex deleted the generate-right-prop branch September 17, 2022 22:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants