3 dépôts
Automatic code formatting tools specifically for the Kotlin language.
Distinct from Code Formatting: Specializes general code formatting for the Kotlin language syntax and style guidelines.
Explore 3 awesome GitHub repositories matching part of an awesome list · Kotlin Formatters. Refine with filters or upvote what's useful.
ktlint is a linter and code formatter for Kotlin that checks source files against a built-in set of style rules and automatically rewrites them to match those rules. It operates by walking the Kotlin abstract syntax tree, detecting violations, and applying transformations directly at the node level before regenerating the source code from the modified tree. The project ships a curated default rule set that requires no configuration to enforce consistent formatting, and provides a command-line interface for running linting and formatting in batch mode. Its rule-set-based plugin architecture al
Formats Kotlin source files to match built-in style rules automatically.
Spotless est un orchestrateur de formatage multi-langage et un plugin Gradle qui automatise le style de code sur divers langages de programmation au sein d'un pipeline de build unique. Il fonctionne comme un coordinateur pour plusieurs formateurs tiers, un outil de linting de style de code et un système pour insérer et mettre à jour des en-têtes de licence standardisés. Le projet se distingue par une application du style intégrée à git, utilisant des hooks de pré-push et des références git pour appliquer le formatage uniquement aux fichiers ou lignes modifiés. Il prend en charge des configurations de build partagées, permettant aux règles de formatage d'être distribuées et chargées sur plusieurs projets via des artefacts distants pour maintenir une source unique de vérité. L'outil couvre un large éventail de capacités, notamment la transformation de texte de code source via des expressions régulières et des patchs JSON, la gestion des imports et la standardisation des espaces blancs. Il s'intègre avec un large éventail de binaires et d'outils externes pour des langages tels que Java, Python, Kotlin, C++, Go et TypeScript. Une fonctionnalité supplémentaire inclut la vérification du formatage pour assurer l'idempotence et l'optimisation incrémentale pour ignorer les fichiers inchangés.
Applies ktfmt to Kotlin source files to ensure consistent styling and trailing comma usage.
kotlin-lsp is a language server implementation that integrates editors with the Kotlin compiler and build tools to provide language intelligence and code analysis. It uses the Language Server Protocol to decouple heavy language processing from the text editor user interface. The project provides static code analysis to detect issues and provide real-time diagnostics. It enables source code navigation through symbol-index based jumping to definitions and an analysis of how components interact. Additional capabilities include automated source code formatting, intelligent code completion, and s
Provides automated source code formatting to enforce consistent Kotlin coding styles.