Releases: alejandrohdezma/sbt-fix
v0.7.2
📈 Dependency updates
Full Changelog: v0.7.1...v0.7.2
v0.7.1
📈 Dependency updates
Full Changelog: v0.7.0...v0.7.1
v0.7.0
What's changed
⚠️ Breaking changes
Remove scalafixEnable
from fix --check
(#138)
Contributors to this release
v0.6.1
What's changed
❗ This release should be used instead of 0.6.0
scalafixAll
should not be called with all
#137
Contributors to this release
v0.6.0
❗ This release introduce a bug that prevents fix --check
from working correctly. Use version 0.6.1
or greater instead.
What's changed
- Remove
scalafixAll
command (#136) @alejandrohdezma
📈 Dependency updates
- Update sbt-scalafix to 0.9.19 (#135) @alejandrohdezma
- Update sbt-scalafix to 0.9.18 (#134) @alejandrohdezma
- Update sbt to 1.3.13 (#133) @alejandrohdezma
- Update sbt-tpolecat to 0.1.13 (#132) @alejandrohdezma
- Update sbt-mdoc to 2.2.3 (#131) @alejandrohdezma
- Update sbt-mdoc to 2.2.2 (#130) @alejandrohdezma
- Update sbt-scalafix to 0.9.17 (#129) @alejandrohdezma
- Update sbt-mdoc to 2.2.1 (#128) @alejandrohdezma
- Update sbt-tpolecat to 0.1.12 (#127) @alejandrohdezma
- Update sbt to 1.3.12 (#126) @alejandrohdezma
- Update sbt-scalafmt-defaults to 0.2.0 (#125) @alejandrohdezma
- Update sbt-scalafmt-defaults to 0.1.1 (#122) @alejandrohdezma
- Update sbt-scalafix to 0.9.16 (#124) @alejandrohdezma
- Update sbt-scalafix-defaults to 0.2.3 (#123) @alejandrohdezma
- Update sbt-scalafmt to 2.4.0 (#121) @alejandrohdezma
- Update sbt-mdoc to 2.2.0 (#120) @alejandrohdezma
- Update sbt-scalafix-defaults to 0.2.2 (#119) @alejandrohdezma
- Update sbt-scalafix-defaults to 0.2.1 (#118) @alejandrohdezma
- Update sbt-scalafix-defaults to 0.2.0 (#117) @alejandrohdezma
- Update sbt-scalafix to 0.9.15 (#116) @alejandrohdezma
- Update sbt-github to version 0.8.2 (#115) @alejandrohdezma
- Update sbt-ci-release to 1.5.3 (#114) @scala-steward
- Update Scala, SBT & plugins to latest version (#112) @alejandrohdezma
Contributors to this release
v0.5.0
tl;dr;
Synchronization of configuration has been removed. To enable similar functionality to previous versions add the following to your plugins.sbt
:
// This plugin no longer forces a version of Scalafmt/Scalafix
addSbtPlugin("ch.epfl.scala" % "sbt-scalafix" % "0.9.12")
addSbtPlugin("org.scalameta" % "sbt-scalafmt" % "2.3.2")
addSbtPlugin("com.alejandrohdezma" % "sbt-fix" % "0.5.0")
// https://github.com/alejandrohdezma/sbt-scalafix-defaults
addSbtPlugin("com.alejandrohdezma" % "sbt-scalafix-defaults" % "0.1.0")
// https://github.com/alejandrohdezma/sbt-scalafmt-defaults
addSbtPlugin("com.alejandrohdezma" % "sbt-scalafmt-defaults" % "0.1.0")
If you were using extra configurations in your project you can add:
import scala.sys.process._ Global / onLoad := (Global / onLoad).value andThen { state => (file(".scalafmt-extra.conf") #>> file(".scalafmt.conf")).! state }
If you were using this plugin to synchronize your own configuration, you can continue to do so easily by using alejandrohdezma/sbt-scalafix-defaults and alejandrohdezma/sbt-scalafmt-defaults as templates, edit the included configurations at will and publish them under your own domain.
And last but not least sbt-fix-it
has been removed. To obtain that same functionality, please add the following plugin to your project
folder:
object IntegrationTestPlugin extends AutoPlugin {
override def trigger = allRequirements
override def requires = ScalafmtPlugin && ScalafixPlugin
override def projectConfigurations = Seq(IntegrationTest)
override def projectSettings = inConfig(IntegrationTest) {
testSettings ++ scalafixConfigSettings(IntegrationTest) ++ scalafmtConfigSettings
}
}
What's changed
The configuration-synchronization part of the plugin has become obsolete with alejandrohdezma/sbt-scalafix-defaults and alejandrohdezma/sbt-scalafmt-defaults.
These new plugins can be used to automatically include scalafmt & scalafix configuration files on any build and are auto-upgradable by using scala-steward. Also, they're written to be extremely easy to use as a template repository, so anyone out there can create their version to use across their repositories.
In addition, since there is no longer any synchronization, there is also no possibility of using .*-extra.conf
files but it can be easily obtained by adding the following piece of code to your build.sbt
:
import scala.sys.process._
Global / onLoad := (Global / onLoad).value andThen { state =>
(file(".scalafmt-extra.conf") #>> file(".scalafmt.conf")).!
state
}
Also sbt-fix-it
has been removed. It was only useful for projects using both tools that also use the IntegrationTest
configuration.
The same goal can be met by adding the following AutoPlugin
to your project
folder:
object IntegrationTestPlugin extends AutoPlugin {
override def trigger = allRequirements
override def requires = ScalafmtPlugin && ScalafixPlugin
override def projectConfigurations = Seq(IntegrationTest)
override def projectSettings = inConfig(IntegrationTest) {
testSettings ++ scalafixConfigSettings(IntegrationTest) ++ scalafmtConfigSettings
}
}
Finally, dependencies with scalafix and scalafmt have been set as Provided
so you'll need to provide your own version of these plugins in your plugins.sbt
:
addSbtPlugin("ch.epfl.scala" % "sbt-scalafix" % "0.9.12")
addSbtPlugin("org.scalameta" % "sbt-scalafmt" % "2.3.2")
⚠️ Breaking changes
- Set scalafix & scalafmt dependencies as
Provided
(#107) @alejandrohdezma - Remove configuration synchronisation code (#100) @alejandrohdezma
- Remove
sbt-fix-it
module (#97) @alejandrohdezma scalafixDependencies
should be added by config providers (#91) @alejandrohdezma- Remove default values from
sbt-fix
(#80) @alejandrohdezma
🚀 Features
- Enable calling
fix --check
usingfix -c
(#105) @alejandrohdezma - Add
scalafixEnable
before callingscalafix
onfix --check
(#103) @alejandrohdezma
🐛 Bug Fixes
- Avoid publishing
root
project (#93) @alejandrohdezma
📈 Dependency updates
- Update sbt-header to 5.5.0 (#76) @scala-steward
- Update sbt-github-header, sbt-github-mdoc to 0.7.0 (#72) @scala-steward
- Update sbt-mdoc to 2.1.5 (#70) @scala-steward
- Update sbt-scalafix to 0.9.13 (#69) @scala-steward
- Update sbt to 1.3.9 (#65) @scala-steward
- Update scaluzzi to 0.1.5 (#64) @scala-steward
- Update sbt-scalafix to 0.9.12 (#63) @scala-steward
- Update sbt-mdoc to 2.1.3 (#62) @scala-steward
- Update sbt-scalafmt to 2.3.2 (#60) @scala-steward
- Update sbt-github-header, sbt-github-mdoc to 0.6.0 (#57) @scala-steward
- Update scaluzzi to 0.1.4.1 (#53) @scala-steward
Contributors to this release
v0.4.0
What's changed
🚀 Features
- First run scalafix, then scalafmt (#44) @sideeffffect
- Support a pretty simple offline mode (#42) @alejandrohdezma
- Ensure we get notified of new scalafix rules versions by scala-steward (#40) @alejandrohdezma
📈 Dependency updates
- Update sort-imports to 0.3.2 (#41) @scala-steward
📘 Documentation
- Update workflows and documentation templates to v0.2 (#46) @alejandrohdezma
🐛 Bug Fixes
fix --check
should call check scalafmt commands (#39) @alejandrohdezma
Contributors to this release
v0.3.1
Update to sbt-fix-defaults
v0.0.5
v0.3.0
Merge pull request #28 from alejandrohdezma/remove-scalaj Remove dependency on `scalaj-http`