Upgrade to Pro — share decks privately, control downloads, hide ads and more …

AIツールでDetektのカスタムルールをお手軽に作ろう

 AIツールでDetektのカスタムルールをお手軽に作ろう

Avatar for Keita Tsukamoto

Keita Tsukamoto

January 23, 2026
Tweet

More Decks by Keita Tsukamoto

Other Decks in Programming

Transcript

  1. 自己紹介 名前・所属 塚本 啓太( @tsukakei1012 ) 株式会社スマートラウンド 執行役員VPoE サーバーサイドKotlin歴 ここ5年くらいずっとKotlinでやっています!

    2019-04~2023-10 某社テックリード 2023-10~ 株式会社スマートラウンド 2024-01~2025-06 テックリード:サービス開発、イネーブルメント担当 2025-07~ 執行役員VPoE:開発部全体のマネジメント、AI推進 2
  2. サンプルコード class TooManyFunctions(config: Config) : Rule( config, "This rule reports

    a file with an excessive function count.", ) { private val threshold = 10 private var amount: Int = 0 override fun visitKtFile(file: KtFile) { super.visitKtFile(file) if (amount > threshold) { report(Finding(Entity.from(file), "Too many functions can make the maintainability of a file costlier")) } amount = 0 } override fun visitNamedFunction(function: KtNamedFunction) { super.visitNamedFunction(function) amount++ } } 12