Skip to content
Agentmart
Submit a tool

kotlin-patterns

Kotlin patterns — Gradle, coroutines, null safety, Android and Ktor.

Skill by alec-c4

IndexedMIT★ 1
Write a review

Install

Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.

npx agentmarket install skill/alec-c4-kotlin-patterns

Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.

Get the weekly diff

The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.

We use your email only for this newsletter. Privacy

About

Kotlin patterns — Gradle, coroutines, null safety, Android and Ktor. Load after stacks/kotlin profile.

No reviews yet. Installed it? Reviews come from verified installers only. How reviews work

Permissions

What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.

Tools
No tools found
Secrets
None asked for
Install scripts
None found

Network hosts it talks to 1

  • codeload.github.com · found in install command

Files it touches

  • ~/.claude/skills/kotlin-patterns

What's inside

Skill name
kotlin-patterns
Description
Kotlin patterns — Gradle, coroutines, null safety, Android and Ktor. Load after stacks/kotlin profile.
License
MIT
Instructions
40 lines in SKILL.md · view on GitHub

Files (1)

  • SKILL.md

SKILL.md (first lines)

# Kotlin patterns

Load after [stacks/kotlin](../stacks/kotlin/SKILL.md).

## Structure

- **Gradle Kotlin DSL** — `build.gradle.kts` and `settings.gradle.kts`; version catalogs (`libs.versions.toml`) for deps.
- **Modules** — separate `api` / `implementation` boundaries; Android `app` vs feature modules when applicable.
- **Packages** — match directory layout; one public top-level type per file when practical.

## Language

- Prefer **null-safe** APIs; avoid `!!` — use `?.`, `?:`, `requireNotNull`, or early returns.
- **Data classes** for DTOs; **sealed** types for closed hierarchies and UI/network states.
- **Coroutines** for async IO; structured concurrency with `supervisorScope` where failures must be isolated.

## Android (when applicable)

- UI state in ViewModel / presenter layer; collect flows with lifecycle-aware APIs —
  `collectAsStateWithLifecycle()` in Compose, `repeatOnLifecycle(STARTED)` in Views.
  Never a bare `collect` in a composable or `launchWhenStarted`.
- No secrets in `BuildConfig` committed to git; use local properties or CI secrets.
- Minimize work on main thread; use `Dispatchers.IO` for blocking IO.

## Server / Ktor (when applicable)

- Route handlers thin; domain logic in testable services.
- Validate input at boundaries; map errors to typed HTTP responses.

## Testing

- JUnit 5 + kotlinx-coroutines-test for suspend code.
- Prefer fakes over heavy mocks for repositories and clients.

## References

- [Kotlin docs](https://kotlinlang.org/docs/home.html)
- [Gradle Kotlin DSL](https://docs.gradle.org/current/userguide/kotlin_dsl.html)

From alec-c4/agent_dev_kit, MIT.

More from alec-c4/agent_dev_kit

Signals

Stars
1
Forks
0
Open issues
0
Last commit (this folder)
Sep 2, 2026 (1 month ago)

From GitHub (fetched Oct 24, 2026).

Details

License
MIT
First seen
Oct 24, 2026
Last checked
Oct 24, 2026

More from alec-c4

Cite this page

kotlin-patterns skill. Agent Mart. https://agentmart.dev/skills/alec-c4-kotlin-patterns (last updated 2026-10-24)