本文へ移動
cccskills
無料GitHub で公開

footgun-scan

Scan a Kotlin or Compose Multiplatform diff for known footgun shapes and open the matching trap to confirm each hit. Use before committing, when reviewing a Kotlin change, or to audit a codebase.

インストール方法を見る

含まれるファイル(2)

  • SKILL.md2.0 KB
  • scripts/scan.py28.4 KB

SKILL.md(原文)

インストールする前に、エージェントに与えられる指示の中身を確認できます。

Footgun scan

scripts/scan.py matches 32 patterns against the lines a change adds. Each pattern is tied to one trap file in the kotlin-footguns area skills. It finds shapes, not bugs: every hit needs the trap's judgment before it becomes a finding.

Run it

From inside the user's git repository, with this skill's base directory as <skill>:

python3 <skill>/scripts/scan.py                     # lines added in the working tree and index since HEAD
python3 <skill>/scripts/scan.py --base origin/main  # lines added on this branch since it left main
python3 <skill>/scripts/scan.py --all src/          # every line under a path: an audit, and noisier

Pick the scope from the request. Uncommitted work takes the default. A branch or pull request takes --base with its target branch. "Audit the codebase" takes --all, narrowed to the paths that matter. For a pre-commit hook or CI step, add --fail to exit 1 on any likely hit.

Triage every hit

  1. Read the trap file the hit points to (the -> path).
  2. Read the code around the hit and decide, by the trap's own conditions, whether it applies. A likely hit is wrong unless the exception the trap names holds. A look hit is a place the trap says to inspect before trusting it.
  3. Report each confirmed problem with the trap's fix and its Verifying step. List dismissed hits one line each with the reason, for example "column is NOT NULL" or "the fade goes to black".

Hits of one detector in one file are grouped: triage the group once, then check the listed lines for exceptions.

When the scanner cannot run

It needs python3 and git. Without them, read scripts/scan.py: the DETECTORS list gives each pattern, its message and its trap. Run those patterns with the Grep tool over the changed files and triage the same way.

レビュー

まだレビューはありません。使ってみた感想をお寄せください。

同じリポジトリのスキル

概要と使いどころ

Compose screen and interaction traps: navigation, adaptive layout, window insets, pagers, toolbars, sheets, list drag and selection, sliders, text fields, settings UI, one-shot effects. Use when layout, gestures or navigation misbehave.

日本語の概要は準備中です。原文の説明を表示しています。

maxrave-dev/kotlin-footguns1,2152026年9月25日 更新

Compose look-and-feel traps: theme and colour tokens, artwork palettes, gradients and scrims, shimmer, glass and particle effects, animation, image loading, charts and stats displays (percent changes, shares, buckets). Use when a visual bands, pops, freezes or misleads.

日本語の概要は準備中です。原文の説明を表示しています。

maxrave-dev/kotlin-footguns1,2152026年9月25日 更新

Room/SQLite, DataStore and repository traps: migrations, NOT IN with NULLs, LIKE escaping, delete order, local-time bucketing, imports, caching, paging. Use before writing a query or migration, or when data comes back wrong.

日本語の概要は準備中です。原文の説明を表示しています。

maxrave-dev/kotlin-footguns1,2152026年9月25日 更新

Desktop JVM and build traps: JNA natives, bundling, memory, packaging, code signing, R8, deep links, Gradle and CI releases. Use when a desktop build fails packaged, signed, on another OS or arch, or in CI.

日本語の概要は準備中です。原文の説明を表示しています。

maxrave-dev/kotlin-footguns1,2152026年9月25日 更新

Debugging-method traps: run the discriminating experiment first, read build logs bottom-up, treat an empty actual as unwritten, audit shared handles before removing a feature, read commit history critically. Use when a fix is not converging.

日本語の概要は準備中です。原文の説明を表示しています。

maxrave-dev/kotlin-footguns1,2152026年9月25日 更新

Kotlin Multiplatform structure and language traps: module splits, expect/actual, Koin and ViewModel scoping, layers, version catalogs, erased overloads, Char and string-resource formatting limits. Use when shaping modules or DI, when a format specifier renders verbatim, or code misbehaves on one platform.

日本語の概要は準備中です。原文の説明を表示しています。

maxrave-dev/kotlin-footguns1,2152026年9月25日 更新

maxrave-dev のスキルをすべて見る

このスキルの問題を報告する