gradle-dependencies-sorter icon indicating copy to clipboard operation
gradle-dependencies-sorter copied to clipboard

Add support for build scripts that are renamed from build.gradle

Open changusmc opened this issue 6 months ago • 0 comments

Hey! Our devs were asking for exactly something like this and I was happy to see it already exists. However, this currently doesn't work for us because we rename all of our build.gradle files to contain the module name e.g. featureBoards.gradle.

This check https://github.com/square/gradle-dependencies-sorter/blob/7496c0a0281bcc61aac8c84db2c80de982efbe20/app/src/main/kotlin/com/squareup/sort/BuildDotGradleFinder.kt could be updated to return filename.endsWith(".gradle") || filename == "build.gradle.kts" and it would work for us.

Locally, I made that change and ran it for our codebase and it only updated our script files. It didn't touch any of our utility or settings files.

If you are willing to consider this change, I'd be happy to put up a PR and update any tests.

changusmc avatar Aug 08 '24 21:08 changusmc