Editorconfig

From aspiers/ai-config · View interactive version

Editorconfig is an AI agent skill from the GitHub repository aspiers/ai-config. Generates a minimal .editorconfig with sensible defaults for a repository. Use when starting work in a new repository, when a project has no .editorconfig, or when the user asks to add or standardise editor and formatting settings.

How to use this skill

Skill file

Generate .editorconfig

When to use this skill

When starting work on a new repository or adding an .editorconfig to an

existing project that lacks one.

How it works

Creates a minimal .editorconfig file with sensible defaults. The generated

config follows the repository's existing style when possible.

Process

  1. Check if .editorconfig already exists - if so, update it
  2. Examine existing files in the repo to detect coding style:
  1. Generate appropriate, minimal .editorconfig content

with no unnecessary duplication.

  1. Write the file to the repository root

Generated Config Structure

root = true

[*]
indent_style = space
indent_size = <detected or 4>
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true

[*.md]
max_line_length = 78

[*.json]
indent_size = 2

Best Practices

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.