Skip to content

MobileAct/RetektRule

Repository files navigation

Retekt

Build Status Download
Retekt is extension rules for detekt

Usage

build.gradle

allprojects {
    repositories {
        google()
        jcenter()
        maven{ url "https://dl.bintray.com/mobile-act/RetektRule" } // need!
    }
}
dependencies {
    detektPlugins 'mobile-act:retekt:VERSION' // adapt latest version
}

Rule

see example config

InterfaceNaming

check interface name

Option

  • interfacePattern: Regex for interface name

TypeParameterNaming

check type parameter name

Option

  • typeParameterPattern: Regex for type parameter name

SuspendFunction

check function type, validate suspend function

Option

  • ignorePrivateFunction: ignore private function for this checking

UnitFunction

check function type, validate unit function for no-return

Option

  • ignorePrivateFunction: ignore private function for this checking

License

This library is under MIT License

Rule

Sample

Contribute

ToDo: Write

Other

Author: @MeilCli