Agent skill

Spotless Fix

by MartinStyk in MartinStyk/apk-analyzer

A skill your agent uses when fixing code formatting errors, ktlint violations, or style issues.

GPL-3.0Auto-check passedMobile

Install Spotless Fix

skills CLI
$ npx skills add MartinStyk/apk-analyzer --skill spotless-fix -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install MartinStyk/apk-analyzer spotless-fix --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/MartinStyk/apk-analyzer.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.claude/skills/spotless-fix .claude/skills/spotless-fix && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
spotless-fix
GitHub stars
369
Token cost
~756 tokens
SKILL.md length
149 words
Files
1
Skills in repo
18
Repo updated
First seen
Licence
GPL-3.0

At a glance

A skill your agent uses when fixing code formatting errors, ktlint violations, or style issues.

  • Works in 5 steps: Multiline function signature (3+… → Wildcard imports → Missing trailing comma in multiline lists → …
  • Fixing code formatting errors
  • SKILL.md covers Fix Commands, Spotless Configuration Summary, Common Violations and Manual… and After Running spotlessApply
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Spotless Fix is an agent skill from MartinStyk/apk-analyzer. Use when fixing code formatting errors, ktlint violations, or style issues. Run after generating or modifying Kotlin files. Triggered by phrases like "fix formatting", "spotless", "ktlint error", "formatting violation", "fix code style", "run spotless".

Its SKILL.md is about 760 tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Mobile, covering Android development and Linting and formatting. It works with Kotlin. The repository describes itself as: The most downloaded APK analysis app on Google Play. Detailed reports of every app on your device. No root, no ads, nothing leaves the phone. The licence is GPL-3.0.

When your agent uses it

  • Fixing code formatting errors
  • Ktlint violations

Example prompts

  • “fix formatting”
  • “spotless”
  • “ktlint error”
  • “/spotless-fix”

Workflow steps

5 steps, taken from the step headings in SKILL.md.

  1. Multiline function signature (3+ parameters)
  2. Wildcard imports
  3. Missing trailing comma in multiline lists
  4. Callback naming (present tense, not past tense)
  5. Modifier parameter position

What it can do on your machine

Read from SKILL.md and the folder at commit d807559. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are kotlin and bash).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Spotless Fix loads about 756 tokens when it runs. Until then it costs about 67 tokens; SKILL.md has 149 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~67
When it runs · the whole SKILL.md, loaded when a task matches
~756

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from MartinStyk/apk-analyzer at commit d807559, republished under its GPL-3.0 licence (© MartinStyk). 149 words, ~756 tokens.

Download SKILL.mdSave it as .claude/skills/spotless-fix/SKILL.md (or your agent's skills folder).
name
spotless-fix
description
Use when fixing code formatting errors, ktlint violations, or style issues. Run after generating or modifying Kotlin files. Triggered by phrases like "fix formatting", "spotless", "ktlint error", "formatting violation", "fix code style", "run spotless".

Spotless Fix

Fix Commands

Fix all modules (run from project root):

shell
./gradlew spotlessApply

Fix a specific module:

shell
./gradlew :<module>:spotlessApply

# Examples:
./gradlew :app:spotlessApply
./gradlew :core:apps:spotlessApply
./gradlew :core:ui-library:spotlessApply
./gradlew :feature:apps:impl:spotlessApply
./gradlew :feature:app-detail:impl:spotlessApply

Check without fixing (see violations only):

shell
./gradlew spotlessCheck
./gradlew :<module>:spotlessCheck

Spotless Configuration Summary

Configured in build-logic/convention/src/main/kotlin/sk/styk/martin/apkanalyzer/SpotlessPlugin.kt:

RuleValue
Multiline signaturesForced when 3+ parameters
Compose CompositionLocal allowlistDisabled
Compose lambda-param-in-effectDisabled
@Composable function namingPascalCase allowed (ignored by ktlint)
Custom rulesetio.nlopez.compose.rules:ktlint

Common Violations and Manual Fixes

1. Multiline function signature (3+ parameters)
kotlin
// ❌ Wrong
fun myFun(param1: String, param2: Int, param3: Boolean) {}

// ✅ Correct — each param on its own line, trailing comma
fun myFun(
    param1: String,
    param2: Int,
    param3: Boolean,
) {}

Same rule applies to: constructor parameters, lambda parameters, function call arguments.

2. Wildcard imports
kotlin
// ❌ Wrong
import kotlinx.coroutines.flow.*

// ✅ Correct — explicit imports only
import kotlinx.coroutines.flow.Flow
import kotlinx.coroutines.flow.map
import kotlinx.coroutines.flow.stateIn
3. Missing trailing comma in multiline lists
kotlin
// ❌ Wrong
fun myFun(
    param1: String,
    param2: Int   // <-- missing trailing comma
)

// ✅ Correct
fun myFun(
    param1: String,
    param2: Int,
)
4. Callback naming (present tense, not past tense)
kotlin
// ❌ Wrong
onClicked: () -> Unit
onItemSelected: (String) -> Unit
onBackPressed: () -> Unit

// ✅ Correct
onClick: () -> Unit
onSelectItem: (String) -> Unit
onBack: () -> Unit
5. Modifier parameter position
kotlin
// ❌ Wrong — Modifier not after required params
@Composable
fun MyComponent(modifier: Modifier = Modifier, label: String) {}

// ✅ Correct — required params first, Modifier after
@Composable
fun MyComponent(
    label: String,
    modifier: Modifier = Modifier,
) {}

After Running spotlessApply

If spotlessApply still fails or cannot auto-fix, manually verify:

  1. No wildcard imports in any file
  2. All 3+ parameter function signatures are multiline with trailing commas
  3. All preview functions are private and suffixed with Preview
  4. No data object is missing the data keyword in sealed hierarchies

© MartinStyk, GPL-3.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in .claude/skills/spotless-fix of MartinStyk/apk-analyzer.

Open the folder on GitHubat commit d807559

Compare with similar skills

Spotless Fix next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Spotless Fix compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Spotless Fix this skillMartinStyk/apk-analyzer369—~756Automated safety check: PassGPL-3.0
Cometchat Android V6 Kotlin Customizationcometchat/cometchat-skills131—~2.2kAutomated safety check: PassMIT
Guided PR Fixupalexvanyo/composelife267—~1kAutomated safety check: PassApache-2.0
Code Stewardnekomangaorg/Neko2.8k—~977Automated safety check: PassApache-2.0
Kotlin LintingGerardPaligot/Confily152—~708Automated safety check: PassApache-2.0
Post Edit VerificationGerardPaligot/Confily152—~1.1kAutomated safety check: PassApache-2.0

Similar skills

  • Make the CometChat Android v6 UI match your app in the Kotlin XML Views cohort — theming via CometChatTheme.DayNight attributes, per-component styles, message-bubble styling, ViewHolder view slots…

    131 GitHub stars~2.2k tokensUpdated 4 days ago
    MobileAuto-check passed
  • Guided PR Fixup

    alexvanyo/composelife

    Performs a guided fixup of a given GitHub PR. An agent skill from alexvanyo/composelife.

    267 GitHub stars~1k tokensUpdated yesterday
    MobileAuto-check passed
  • Code Steward

    nekomangaorg/Neko

    Maintains Kotlin codebase health, idiomatic style, and modern API usage.

    2.8k GitHub stars~977 tokensUpdated yesterday
    MobileAuto-check passed
  • Kotlin Linting

    GerardPaligot/Confily

    A skill your agent uses whenever you write or modify Kotlin files in this project.

    152 GitHub stars~708 tokensUpdated 12 days ago
    MobileAuto-check passed
  • Post Edit Verification

    GerardPaligot/Confily

    Use this skill after every working session where Kotlin or Android code was created or modified, and ALWAYS before committing, opening a PR, or reporting work as done.

    152 GitHub stars~1.1k tokensUpdated 12 days ago
    MobileAuto-check passed
  • Kotlin Tooling Kotlin Toolchain

    Kotlin/kotlin-agent-skills

    Load when building, running, testing, packaging, linting, or configuring a Kotlin/Java project with the Kotlin Toolchain (JetBrains' unified CLI, formerly Amper), when scaffolding a new or…

    1.1k GitHub stars~2.4k tokensUpdated yesterday
    MobileAuto-check passed

More from MartinStyk/apk-analyzer

All 18 skills in this repo
  • Triage Crashes

    MartinStyk/apk-analyzer

    A skill your agent uses to review production Crashlytics crashes and non-fatals for the latest release and file a GitHub issue for each one that isn't tracked yet.

    369 GitHub stars~4.3k tokensUpdated 4 days ago
    Auto-check passed
  • Analyze CI Failure

    MartinStyk/apk-analyzer

    A skill your agent uses to check GitHub Actions build status or diagnose why a workflow run failed and propose a fix.

    369 GitHub stars~1.9k tokensUpdated 4 days ago
    Auto-check passed
  • Capture App Flow Media

    MartinStyk/apk-analyzer

    A skill your agent uses to record or convert ApkAnalyzer app flows into screenshots or GIFs for the README or product docs.

    369 GitHub stars~1.7k tokensUpdated 4 days ago
    Auto-check passed
  • Create Compose Component

    MartinStyk/apk-analyzer

    A skill your agent uses when creating a new reusable Compose UI component that should live in core:ui-library.

    369 GitHub stars~885 tokensUpdated 4 days ago
    Auto-check passed
  • Create Core Module

    MartinStyk/apk-analyzer

    A skill your agent uses when creating a new core or shared library module for domain logic, data access, repositories, managers, or utilities.

    369 GitHub stars~1.7k tokensUpdated 4 days ago
    Auto-check passed
  • Create Feature Module

    MartinStyk/apk-analyzer

    A skill your agent uses when creating a new feature module, screen, or feature area.

    369 GitHub stars~1.6k tokensUpdated 4 days ago
    Auto-check passed

Works with

Categories

Questions about Spotless Fix

What does Spotless Fix do?

A skill your agent uses when fixing code formatting errors, ktlint violations, or style issues. Spotless Fix is an agent skill from MartinStyk/apk-analyzer. Use when fixing code formatting errors, ktlint violations, or style issues.

When should I use Spotless Fix?

Spotless Fix fits situations like: fixing code formatting errors; ktlint violations.

How do I install Spotless Fix in Claude Code?

Run `npx skills add MartinStyk/apk-analyzer --skill spotless-fix -a claude-code`. Or copy the skill folder (.claude/skills/spotless-fix in MartinStyk/apk-analyzer) into .claude/skills/spotless-fix in your project. Claude Code loads it when a task matches its description.

How do I install Spotless Fix in Codex?

Run `npx skills add MartinStyk/apk-analyzer --skill spotless-fix -a codex`. Or copy the skill folder (.claude/skills/spotless-fix in MartinStyk/apk-analyzer) into .agents/skills/spotless-fix in your project. Codex loads it when a task matches its description.

Can I use Spotless Fix in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add MartinStyk/apk-analyzer --skill spotless-fix -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/spotless-fix, .gemini/skills/spotless-fix, .github/skills/spotless-fix and .opencode/skills/spotless-fix in your project.

What does Spotless Fix need to run?

SKILL.md names no scripts, command-line tools or credentials: Spotless Fix is instructions for the agent only.

Does Spotless Fix access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Spotless Fix safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Spotless Fix use?

Spotless Fix is published under the GPL-3.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Spotless Fix use?

About 756 tokens (SKILL.md is roughly 3k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Spotless Fix?

Skills that share tags, products or a category with Spotless Fix: Cometchat Android V6 Kotlin Customization (cometchat/cometchat-skills, 131 stars), Guided PR Fixup (alexvanyo/composelife, 267 stars), Code Steward (nekomangaorg/Neko, 2.8k stars) and Kotlin Linting (GerardPaligot/Confily, 152 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Spotless Fix?

MartinStyk (a GitHub user) maintains it in MartinStyk/apk-analyzer, which has 369 GitHub stars. The repository holds 18 skills in this directory. The repository was last updated on October 5, 2026.

Source: MartinStyk/apk-analyzer on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.