Repository navigation
Detect Gradle build scripts and Kotlin scripts - #37
Merged
Merged
Conversation
.gradle now reports as Groovy and .kts as Kotlin. Both were missing from EXT_FILETYPES, so every Gradle script and Kotlin script reported Unknown. Gradle selects the DSL by extension alone, so the mapping is exact and detection stays path-based. build.gradle.kts carries the same gradle, build and dependencies tags as build.gradle. A project on the Gradle Kotlin DSL previously looked like it declared no dependencies. settings.gradle and settings.gradle.kts are tagged gradle and build only, since they declare project structure. Bumps the version to 0.0.21. Closes #36 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #36.
Summary
.gradlenow reports as Groovy and.ktsas Kotlin. Both were missing fromEXT_FILETYPES, so every Gradle script and Kotlin script reportedUnknown.build.gradle.ktscarries the samegradle,buildanddependenciestags asbuild.gradle. A project on the Gradle Kotlin DSL previously looked like it declared no dependencies.settings.gradleandsettings.gradle.ktsare taggedgradleandbuild. They declare project structure, not dependencies.CHANGELOG.mdentry under[Unreleased]and achanges/note.Before and after
Why the mapping is safe
Gradle selects the DSL by file extension alone:
.gradleis compiled as Groovy and.gradle.ktsas Kotlin. There is no content-dependent case, so detection stays path-based.Things to note
Testing
pytest: 709 passed. The new extension and tag tests were written first and failed before the change.src/tests/for all four Gradle filenames;panopticas assessshows each with the expected language and tags.🤖 Generated with Claude Code