scalafix icon indicating copy to clipboard operation
scalafix copied to clipboard

Refactoring and linting tool for Scala

Results 141 scalafix issues
Sort by recently updated
recently updated
newest added
trafficstars

Removing an unused variable with Scalafix’s RemoveUnused rule leaves unbalanced parentheses in expressions, resulting in invalid syntax. scala version: 2.13.13 sbt version: 1.10.1 scalafix version: 0.12.1 build.sbt ``` ThisBuild /...

bug
RemoveUnused

## About this PR πŸ“¦ Updates [com.github.sbt:sbt-ci-release](https://github.com/sbt/sbt-ci-release) from `1.9.3` to `1.11.1` πŸ“œ [GitHub Release Notes](https://github.com/sbt/sbt-ci-release/releases/tag/v1.11.1) - [Version Diff](https://github.com/sbt/sbt-ci-release/compare/v1.9.3...v1.11.1) ## Usage βœ… **Please merge!** I'll automatically update this PR to resolve...

Given the following imports: ``` import io.circe.Json import io.circe.parser.* import io.circe.syntax.* import io.circe.{Decoder, Encoder} import org.scalatest.flatspec.AnyFlatSpec import chimp.mcp.JSONRPCMessage.{given Decoder[JSONRPCMessage], given Encoder[JSONRPCMessage]} import org.scalatest.matchers.should.Matchers ``` Organizing them yields: ``` import chimp.mcp.JSONRPCMessage.given...

## About this PR πŸ“¦ Updates [org.scalameta:metaconfig-typesafe-config](https://github.com/scalameta/metaconfig) from `0.15.0` to `0.16.0` πŸ“œ [GitHub Release Notes](https://github.com/scalameta/metaconfig/releases/tag/v0.16.0) - [Version Diff](https://github.com/scalameta/metaconfig/compare/v0.15.0...v0.16.0) ## Usage βœ… **Please merge!** I'll automatically update this PR to resolve...

Helps for https://github.com/scalacenter/sbt-scalafix/pull/482 Towards https://github.com/scalacenter/scalafix/issues/1146 & https://github.com/joan38/mill-scalafix/issues/239 Revisits https://github.com/scalacenter/scalafix/pull/2226 & https://github.com/scalacenter/scalafix/pull/2231, reverted in https://github.com/scalacenter/scalafix/pull/2240

I got the following error, when running `scalafix` with Scala 3.7.0-RC3: ``` error: The ExplicitResultTypes rule was compiled with a different Scala 3 minor (3.6) than the target sources (3.7)....

documentation
upstream

Even though [docs](https://scalacenter.github.io/scalafix/docs/rules/external-rules.html) do mention that the `scalafix dependency:RULE@GROUP::ARTIFACT:VERSION` syntax is only usable within sbt, it's easy to miss that. See https://github.com/scala-steward-org/scala-steward/issues/3486#issuecomment-2628649445 for example. As more build tools support scalafix...

enhancement
cli
sbt
interfaces

## Context sbt-scalafix has had opt-in [support for cached/incremental invocations within a build](https://github.com/scalacenter/sbt-scalafix/pull/102) for sbt 0.13.x and sbt 1.x since v0.9.15-3. This feature was instrumental to [introduce `scalafixOnCompile`](https://github.com/scalacenter/sbt-scalafix/pull/140) in v0.9.19....

sbt
feature

scalafix-cli is currently exposed as [a coursier app](https://github.com/coursier/apps/blob/main/apps/resources/scalafix.json), but the burden of chosing the right (full) scala version to load scalafix-cli (which is needed for ExplicitResultTypes ,which needs the presentation...

cli
feature