mirror of https://github.com/sbt/sbt.git
[2.x] ci: Avoid infix syntax in build files (#9157)
This commit is contained in:
parent
0968cbf7ef
commit
01fbc474f1
|
|
@ -129,7 +129,7 @@ val sbt20Plus =
|
|||
"2.0.0-RC12",
|
||||
)
|
||||
val mimaSettings = mimaSettingsSince(sbt20Plus)
|
||||
def mimaSettingsSince(versions: Seq[String]): Seq[Def.Setting[?]] = Def settings (
|
||||
def mimaSettingsSince(versions: Seq[String]): Seq[Def.Setting[?]] = Def.settings(
|
||||
mimaPreviousArtifacts := {
|
||||
val crossVersion = if (crossPaths.value) CrossVersion.binary else CrossVersion.disabled
|
||||
if (sbtPlugin.value) {
|
||||
|
|
|
|||
|
|
@ -42,7 +42,7 @@ object HouseRulesPlugin extends AutoPlugin {
|
|||
(c / console / scalacOptions) --= Seq("-Ywarn-unused-import", "-Xlint")
|
||||
)
|
||||
|
||||
private def scalaPartV = Def setting (CrossVersion partialVersion scalaVersion.value)
|
||||
private def scalaPartV = Def.setting(CrossVersion.partialVersion(scalaVersion.value))
|
||||
|
||||
private implicit final class AnyWithIfScala[A](val __x: A) {
|
||||
def ifScala2x(p: Long => Boolean) =
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ object PublishBinPlugin extends AutoPlugin {
|
|||
private val dummyDoc = taskKey[File]("").withRank(Int.MaxValue)
|
||||
override val globalSettings = Seq(publishLocalBin := (()))
|
||||
|
||||
override val projectSettings: Seq[Def.Setting[?]] = Def settings (
|
||||
override val projectSettings: Seq[Def.Setting[?]] = Def.settings(
|
||||
publishLocalBin := Classpaths
|
||||
.publishOrSkip(publishLocalBinConfig, publishLocalBin / skip)
|
||||
.value,
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@ object Scripted {
|
|||
// This is to workaround https://github.com/sbt/io/issues/110
|
||||
if (!sys.props.contains("jna.nosys")) sys.props.put("jna.nosys", "true")
|
||||
|
||||
val RepoOverrideTest = config("repoOverrideTest") extend Compile
|
||||
val RepoOverrideTest = config("repoOverrideTest").extend(Compile)
|
||||
|
||||
val sbtWindowsExcludeFilter: FileFilter =
|
||||
if (scala.util.Properties.isWin)
|
||||
|
|
@ -102,10 +102,10 @@ object Scripted {
|
|||
} yield files map (f => s"$group/$f")
|
||||
|
||||
val testID = (for (group <- groupP; name <- nameP(group)) yield (group, name))
|
||||
val testIdAsGroup = matched(testID) map (test => Seq(test))
|
||||
val testIdAsGroup = matched(testID).map(test => Seq(test))
|
||||
|
||||
// (token(Space) ~> matched(testID)).*
|
||||
(token(Space) ~> (PagedIds | testIdAsGroup)).* map (_.flatten)
|
||||
(token(Space) ~> (PagedIds | testIdAsGroup)).*.map(_.flatten)
|
||||
}
|
||||
|
||||
@nowarn
|
||||
|
|
|
|||
|
|
@ -36,7 +36,7 @@ object Utils {
|
|||
|
||||
def projectComponent: Setting[?] =
|
||||
projectID := (componentID.value match {
|
||||
case Some(id) => projectID.value extra ("e:component" -> id)
|
||||
case Some(id) => projectID.value.extra("e:component" -> id)
|
||||
case None => projectID.value
|
||||
})
|
||||
|
||||
|
|
@ -127,7 +127,7 @@ object Utils {
|
|||
excludePomArtifact(n.text)
|
||||
}
|
||||
|
||||
def excludePomArtifact(artifactId: String) = (artifactId startsWith "compiler-bridge")
|
||||
def excludePomArtifact(artifactId: String) = artifactId.startsWith("compiler-bridge")
|
||||
|
||||
val testExclusive = test / tags += (ExclusiveTest, 1)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue