-
Notifications
You must be signed in to change notification settings - Fork 39
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
Remove ignoreFolders option from FileSize rule #981
Conversation
### What's done: * Removed code * Fixed docs
### What's done: * Removed code * Fixed docs
### What's done: * Removed code * Fixed docs
Codecov Report
@@ Coverage Diff @@
## master #981 +/- ##
============================================
- Coverage 83.81% 83.81% -0.01%
+ Complexity 2410 2407 -3
============================================
Files 101 102 +1
Lines 6087 6079 -8
Branches 1801 1797 -4
============================================
- Hits 5102 5095 -7
Misses 269 269
+ Partials 716 715 -1
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
@@ -276,7 +276,7 @@ class PackageNaming(configRules: List<RulesConfig>) : DiktatRule( | |||
/** | |||
* Directory which is considered the start of sources file tree | |||
*/ | |||
const val PACKAGE_PATH_ANCHOR = "src" | |||
const val PACKAGE_PATH_ANCHOR = SRC_DIRECTORY_NAME |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe also move SRC_DIRECTORY_NAME
into FileUtils.kt
file?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But it's already in there
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, confused)
/** | ||
* List of folders, files from which are ignored during the check. For example, for tests. | ||
*/ | ||
val ignoreFolders = config["ignoreFolders"]?.replace("\\s+".toRegex(), "")?.split(IGNORE_FOLDERS_SEPARATOR) ?: ignoreFolder |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why now we don't have this parameter?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We have decided that we no longer need it. It was originally introduced at the time when we didn't have exclusion mechanism, but now we can add excludes into plugin config or add file-level suppress for any rule, so special setting for file size is no longer required
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
What's done:
This pull request closes #971