Skip to content

Update intro.mdx to use setFrom() on detekt config #6010

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

Merged
merged 2 commits into from
Apr 18, 2023
Merged

Update intro.mdx to use setFrom() on detekt config #6010

merged 2 commits into from
Apr 18, 2023

Conversation

mjovanc
Copy link
Contributor

@mjovanc mjovanc commented Apr 18, 2023

Setting the value of files() directly on config is deprecated.

Setting the value of files() directly on config is deprecated.
Copy link
Member

@3flex 3flex left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for this - please update to working syntax and we can merge.

@@ -48,7 +48,7 @@ slim down the configuration file to only the changes from the default configurat
```kotlin
detekt {
toolVersion = "[detekt_version]"
config = files("config/detekt/detekt.yml")
config = setFrom(files("config/detekt/detekt.yml"))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
config = setFrom(files("config/detekt/detekt.yml"))
config.setFrom(file("config/detekt/detekt.yml"))

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed!

@codecov
Copy link

codecov bot commented Apr 18, 2023

Codecov Report

Merging #6010 (da0ebe6) into main (bd44c2d) will not change coverage.
The diff coverage is n/a.

@@            Coverage Diff            @@
##               main    #6010   +/-   ##
=========================================
  Coverage     84.66%   84.66%           
  Complexity     3840     3840           
=========================================
  Files           549      549           
  Lines         13071    13071           
  Branches       2305     2305           
=========================================
  Hits          11066    11066           
  Misses          868      868           
  Partials       1137     1137           

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@3flex 3flex merged commit dbf0f4f into detekt:main Apr 18, 2023
@3flex 3flex added this to the 1.23.0 milestone Apr 18, 2023
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.

2 participants