# Detekt: the rules this project deliberately overrides. # # Everything else is detekt's default (buildUponDefaultConfig is set in app/build.gradle.kts), and # findings that exist today are frozen in baseline.xml. Overrides are here for one of two reasons: # the threshold has to match this codebase, or the rule disagrees with a deliberate choice. build: # The gate is "no new findings", which the baseline answers; a hard zero would only re-report the # backlog the baseline exists to park. maxIssues: 0 complexity: # The size rules are the point of adding detekt: BrowserViewModel is 2 100 lines and was touched # in 2 300 changed lines of history, which is the one place this codebase could rot. LongMethod: threshold: 100 LargeClass: threshold: 700 TooManyFunctions: thresholdInFiles: 30 thresholdInClasses: 30 CognitiveComplexMethod: threshold: 25 NestedBlockDepth: threshold: 4 LongParameterList: functionThreshold: 10 constructorThreshold: 14 style: # Comments are prose here and wrap where the sentence ends, not at a column. MaxLineLength: maxLineLength: 110 excludeCommentStatements: true # A TODO that nobody is reminded of is a TODO that stays forever. ForbiddenComment: comments: - 'TODO:' - 'FIXME:' - 'STOPSHIP:' # Sizes, timeouts and buffer lengths are named constants in this codebase; the rule would argue # with every one of them. MagicNumber: active: false ReturnCount: max: 5 naming: # `de.softwareapp_hb.filemanager` is the applicationId this app is locked to; the underscore is # part of it and an identity change is not a lint fix. PackageNaming: active: false # Test names are sentences in backticks, which is the project's specification style, and a # `@Composable` is a type in PascalCase — that is Compose's convention, not this project's choice. FunctionNaming: ignoreAnnotated: ['Composable'] excludes: - '**/src/test/**' # Files are named after the concept they hold (BrowserRoots.kt is a group of composables), not after # a declaration inside them. MatchingDeclarationName: active: false