Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove automatic installation of semanticdb-scalac #665

Merged
merged 3 commits into from
Mar 23, 2018

Conversation

olafurpg
Copy link
Contributor

@olafurpg olafurpg commented Mar 22, 2018

Previously, addSbtPlugin(sbt-scalafix) would automatically enable the
semanticdb-scalac compiler plugin and -Yrange scalac options.
This commit removes the automatic installation so that users now need to
manually enable the following settings

addCompilerPlugin(scalafixSemanticdb)
scalacOptions += "-Yrangepos"

This makes the installation consistent for all users regardless of what
order they define libraryDependencies and scalacOptions.
The installation documentation for sbt-scalafix was pretty complex
before because the automatic setup only worked sometimes.

Fixes #589

PS. Right after merging this PR we should immediately cut a v0.6.0-M2 release in order to make the installation instructions up-to-date.

Previously, addSbtPlugin(sbt-scalafix) would automatically enable the
semanticdb-scalac compiler plugin and -Yrange scalac options.
This commit removes the automatic installation so that users now need to
manually enable the following settings
```
addCompilerPlugin(scalafixSemanticdb)
scalacOptions += "-Yrangepos"
```
This makes the installation consistent for all users regardless of what
order they define libraryDependencies and scalacOptions.
The installation documentation for sbt-scalafix was pretty complex
before because the automatic setup only worked sometimes.
Custom sourceroots are an esoteric feature that is not worth
maintaining.
@olafurpg olafurpg requested a review from MasseGuillaume March 22, 2018 17:52
Copy link
Contributor Author

@olafurpg olafurpg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review by @MasseGuillaume in person.


/** Settings that must appear after scalacOptions and libraryDependencies */
@deprecated(
"Use addCompilerPlugin(semanticdb-scalac) and scalacOptions += -Yrangepos instead",
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

scalafixSemanticdb

@@ -1,3 +1,4 @@
> scalafixEnable
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

addCompilerPlugin instead

@MasseGuillaume MasseGuillaume merged commit fb4da6c into scalacenter:master Mar 23, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Stop automatic installation of semanticdb-scalac
2 participants