Code Style
Developmentcode-styleCode Style is an Agent Skill for development published in the JetBrains/intellij-community repository on GitHub: a SKILL.md instruction file an AI agent can load to do this task.
Code style rules for IntelliJ codebase. Use when writing or reviewing code for style compliance.
QUICK START
How to use this skill
Bring this guide into your coding agent with a prompt tailored to the tool you use.
- Open your project in Codex.
- Copy and paste the prompt below.
- Review files and risks before approving any action.
Prompt to paste
Inspect the Agent Skill at https://github.com/JetBrains/intellij-community/blob/HEAD/.claude/skills/code-style/SKILL.md and all supporting files. Report provenance, permissions, scripts, dependencies, and security risks. Propose an exact installation into .agents/skills/code-style-49912713, but wait for my approval before writing files or running scripts.
Copying this prompt does not install or run the skill. Review third-party files before use.
Code Style
Follow the IntelliJ Coding Guidelines with these IntelliJ-specific rules.
Language
- ALWAYS use Kotlin for new files - Only use Java when modifying existing Java code
- Use idiomatic Kotlin: extension functions, data classes, null safety
- Mark experimental APIs with
@ApiStatus.Experimental - Build scripts Kotlin style: Follow
community/platform/build-scripts/kotlin-style-recommendations.mdfor build-scripts code:- Use
@JvmFieldfor internal data class fields - Use
.put()/.get()instead of[]operator - Use explicit
HashMap/HashSet/LinkedHashMapinstead ofmutableMapOf()/mutableSetOf()
- Use
Formatting
- Indentation: 2 spaces (4 for Go files)
- Line length: 140 characters max
- Braces: else/catch/finally on new lines
- Only in
/rustroverdirectory you must always use standard Kotlin formatting rules with 4 spaces indentation.