utwente-fmt / vercors

The VerCors verification toolset for verifying parallel and concurrent software
https://utwente.nl/vercors
Mozilla Public License 2.0
56 stars 26 forks source link

Fix deprecation warning of sbt #688

Closed Vescatur closed 2 years ago

Vescatur commented 3 years ago

Building vercors causes the following useless warnings to be printed, we should fix them:

C:\Users\Ivan\Documents\Develop\vercors4\vercors\hre\build.sbt:10: warning: method in in trait ScopingSetting is deprecated (since 1.5.0): `in` is deprecated; migrate to slash syntax - https://www.scala-sbt.org/1.x/docs/Migrating-from-sbt-013x.html#slash
    sources in (Compile, doc) := Seq(),
            ^
C:\Users\Ivan\Documents\Develop\vercors4\vercors\hre\build.sbt:11: warning: method in in trait ScopingSetting is deprecated (since 1.5.0): `in` is deprecated; migrate to slash syntax - https://www.scala-sbt.org/1.x/docs/Migrating-from-sbt-013x.html#slash
    publishArtifact in (Compile, packageDoc) := false,
                    ^
[info] loading settings for project hre from build.sbt ...
C:\Users\Ivan\Documents\Develop\vercors4\vercors\col\build.sbt:5: warning: method in in trait ScopingSetting is deprecated (since 1.5.0): `in` is deprecated; migrate to slash syntax - https://www.scala-sbt.org/1.x/docs/Migrating-from-sbt-013x.html#slash
sources in (Compile, doc) := Seq()
        ^
C:\Users\Ivan\Documents\Develop\vercors4\vercors\col\build.sbt:6: warning: method in in trait ScopingSetting is deprecated (since 1.5.0): `in` is deprecated; migrate to slash syntax - https://www.scala-sbt.org/1.x/docs/Migrating-from-sbt-013x.html#slash
publishArtifact in (Compile, packageDoc) := false
                ^
[info] loading settings for project col from build.sbt ...
C:\Users\Ivan\Documents\Develop\vercors4\vercors\parsers\build.sbt:10: warning: method in in trait ScopingSetting is deprecated (since 1.5.0): `in` is deprecated; migrate to slash syntax - https://www.scala-sbt.org/1.x/docs/Migrating-from-sbt-013x.html#slash
    val target = (sourceManaged in Compile).value / "antlr4" / "vct" / "antlr4" / "generated"
                                ^
C:\Users\Ivan\Documents\Develop\vercors4\vercors\parsers\build.sbt:9: warning: method in in trait ScopingSetting is deprecated (since 1.5.0): `in` is deprecated; migrate to slash syntax - https://www.scala-sbt.org/1.x/docs/Migrating-from-sbt-013x.html#slash
    val lib = (unmanagedBase in Compile).value / "antlr4"
                             ^
C:\Users\Ivan\Documents\Develop\vercors4\vercors\parsers\build.sbt:8: warning: method in in trait ScopingSetting is deprecated (since 1.5.0): `in` is deprecated; migrate to slash syntax - https://www.scala-sbt.org/1.x/docs/Migrating-from-sbt-013x.html#slash
    val src = (sourceDirectory in Compile).value / "antlr4"
                               ^
C:\Users\Ivan\Documents\Develop\vercors4\vercors\parsers\build.sbt:7: warning: method in in trait ScopingSetting is deprecated (since 1.5.0): `in` is deprecated; migrate to slash syntax - https://www.scala-sbt.org/1.x/docs/Migrating-from-sbt-013x.html#slash
    val cp = (dependencyClasspath in Compile).value.files
                                  ^
C:\Users\Ivan\Documents\Develop\vercors4\vercors\parsers\build.sbt:93: warning: method in in trait ScopingSetting is deprecated (since 1.5.0): `in` is deprecated; migrate to slash syntax - https://www.scala-sbt.org/1.x/docs/Migrating-from-sbt-013x.html#slash
sourceGenerators in Compile += (antlrTask in Compile).taskValue
                 ^
C:\Users\Ivan\Documents\Develop\vercors4\vercors\parsers\build.sbt:93: warning: method in in trait ScopingSetting is deprecated (since 1.5.0): `in` is deprecated; migrate to slash syntax - https://www.scala-sbt.org/1.x/docs/Migrating-from-sbt-013x.html#slash
sourceGenerators in Compile += (antlrTask in Compile).taskValue
                                          ^
C:\Users\Ivan\Documents\Develop\vercors4\vercors\parsers\build.sbt:94: warning: method in in trait ScopingSetting is deprecated (since 1.5.0): `in` is deprecated; migrate to slash syntax - https://www.scala-sbt.org/1.x/docs/Migrating-from-sbt-013x.html#slash
managedSourceDirectories in Compile += (sourceManaged in Compile).value / "antlr4"
                         ^
C:\Users\Ivan\Documents\Develop\vercors4\vercors\parsers\build.sbt:94: warning: method in in trait ScopingSetting is deprecated (since 1.5.0): `in` is deprecated; migrate to slash syntax - https://www.scala-sbt.org/1.x/docs/Migrating-from-sbt-013x.html#slash
managedSourceDirectories in Compile += (sourceManaged in Compile).value / "antlr4"
                                                      ^
C:\Users\Ivan\Documents\Develop\vercors4\vercors\parsers\build.sbt:97: warning: method in in trait ScopingSetting is deprecated (since 1.5.0): `in` is deprecated; migrate to slash syntax - https://www.scala-sbt.org/1.x/docs/Migrating-from-sbt-013x.html#slash
sources in (Compile, doc) := Seq()
        ^
C:\Users\Ivan\Documents\Develop\vercors4\vercors\parsers\build.sbt:98: warning: method in in trait ScopingSetting is deprecated (since 1.5.0): `in` is deprecated; migrate to slash syntax - https://www.scala-sbt.org/1.x/docs/Migrating-from-sbt-013x.html#slash
publishArtifact in (Compile, packageDoc) := false
bobismijnnaam commented 3 years ago

This can be fixed by rewriting

publishArtifact in (Compile, packageDoc) := false

to

Compile / packageDoc / publishArtifact := false

I already did this for the main file, but as the subprojects are not always rebuild I didn't see the errors for the subprojects...