Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .git-blame-ignore-revs
Original file line number Diff line number Diff line change
@@ -1,2 +1,5 @@
# initial format for 3.10.7
bee6f0547cf036a8007becefd500328e38b5d5e7

# Scala Steward: Reformat with scalafmt 3.11.0
c6688cd06ea7f8e0f2277caca234ad46aebf6571
2 changes: 1 addition & 1 deletion .scalafmt.conf
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
version = 3.10.7
version = 3.11.0
align {
preset = none
}
Expand Down
11 changes: 5 additions & 6 deletions build.sbt
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

import Settings._

def dataclassScalafixV = "0.2.0"
Expand Down Expand Up @@ -50,7 +49,7 @@ def lmIvy = Def.setting {
scalaBinaryVersion.value match {
case "2.12" => "1.3.4"
case "2.13" => "1.7.0"
case _ => "2.0.0-alpha2"
case _ => "2.0.0-alpha2"
}
}
}
Expand Down Expand Up @@ -206,10 +205,10 @@ lazy val `sbt-lm-coursier` = project

// TODO Get those automatically
// (but shouldn't scripted itself handle that…?)
(`lm-coursier-shaded` / publishLocal).value
(`sbt-coursier-shared-shaded` / publishLocal).value
}
)
(`lm-coursier-shaded` / publishLocal).value
(`sbt-coursier-shared-shaded` / publishLocal).value
}
)

lazy val `sbt-coursier` = project
.in(file("modules/sbt-coursier"))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ object Resolvers {

case r: FileRepository
if r.patterns.ivyPatterns.lengthCompare(1) == 0 &&
r.patterns.artifactPatterns.lengthCompare(1) == 0 =>
r.patterns.artifactPatterns.lengthCompare(1) == 0 =>

val mavenCompatibleBaseOpt0 = mavenCompatibleBaseOpt(r.patterns)

Expand Down Expand Up @@ -159,7 +159,7 @@ object Resolvers {

private def patternMatchGuard(patterns: Patterns): Boolean =
patterns.ivyPatterns.lengthCompare(1) == 0 &&
patterns.artifactPatterns.lengthCompare(1) == 0
patterns.artifactPatterns.lengthCompare(1) == 0

private def parseMavenCompatResolver(
log: Logger,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
18 changes: 11 additions & 7 deletions modules/sbt-coursier/src/sbt-test/sbt-coursier/s3/build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@ check := {
// Sanity check to ensure SBT is loading the resolvers properly
assert(sbtResolvers.exists(_.name == "Private S3 Snapshots"))
assert(sbtResolvers.exists(_.name == "Private S3 Releases"))

// Have Coursier SBT Plugin Parse the SBT Resolvers
val parsedCoursierResolvers: Seq[coursier.core.Repository] =
sbtResolvers.flatMap{ sbtResolver: sbt.librarymanagement.Resolver =>
sbtResolvers.flatMap { sbtResolver: sbt.librarymanagement.Resolver =>
lmcoursier.internal.Resolvers.repository(
resolver = sbtResolver,
ivyProperties = lmcoursier.internal.ResolutionParams.defaultIvyProperties(
Expand All @@ -49,8 +49,12 @@ check := {
}
}

assert(containsRepo("s3://s3-us-west-2.amazonaws.com/bucket-name/snapshots/"),
"Didn't have snapshots s3 repo")
assert(containsRepo("s3://s3-us-west-2.amazonaws.com/bucket-name/releases/"),
"Didn't have releases s3 repo")
}
assert(
containsRepo("s3://s3-us-west-2.amazonaws.com/bucket-name/snapshots/"),
"Didn't have snapshots s3 repo"
)
assert(
containsRepo("s3://s3-us-west-2.amazonaws.com/bucket-name/releases/"),
"Didn't have releases s3 repo"
)
}
Original file line number Diff line number Diff line change
@@ -1 +1 @@
addSbtPlugin("com.frugalmechanic" % "fm-sbt-s3-resolver" % "0.18.0")
addSbtPlugin("com.frugalmechanic" % "fm-sbt-s3-resolver" % "0.18.0")
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
Original file line number Diff line number Diff line change
@@ -1 +1 @@
object Foo
object Foo
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
scalaVersion := "2.13.1"

libraryDependencies += "com.typesafe.play" %% "play-test" % "2.8.0-RC1" % Test // worked around in 2.8.0
libraryDependencies += "org.scalatest" %% "scalatest" % "3.0.8" % Test
libraryDependencies += "org.scalatest" %% "scalatest" % "3.0.8" % Test
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package t

import com.typesafe.config.ConfigFactory
import org.scalatest.{ MustMatchers, WordSpec }
import org.scalatest.{MustMatchers, WordSpec}

class UnitSpec extends WordSpec with MustMatchers {
def conf = ConfigFactory.defaultReference()
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

// examples adapted from https://github.com/coursier/sbt-coursier/pull/75#issuecomment-497128870

lazy val a = project
Expand All @@ -8,26 +7,26 @@ lazy val a = project
"org.typelevel" %% "cats-effect" % "1.3.1",
"org.typelevel" %% "cats-core" % "1.5.0"
)
)
)

lazy val b = project
.settings(
scalaVersion := "2.12.8",
libraryDependencies ++= Seq(
"org.slf4s" %% "slf4s-api" % "1.7.25", // depends on org.slf4j:slf4j-api:1.7.25
"org.slf4s" %% "slf4s-api" % "1.7.25", // depends on org.slf4j:slf4j-api:1.7.25
"ch.qos.logback" % "logback-classic" % "1.1.2" // depends on org.slf4j:slf4j-api:1.7.6
)
)
)

lazy val c = project
.settings(
scalaVersion := "2.12.8",
libraryDependencies ++= Seq(
"org.slf4s" %% "slf4s-api" % "1.7.25", // depends on org.slf4j:slf4j-api:1.7.25
"org.slf4s" %% "slf4s-api" % "1.7.25", // depends on org.slf4j:slf4j-api:1.7.25
"ch.qos.logback" % "logback-classic" % "1.1.2" // depends on org.slf4j:slf4j-api:1.7.6
),
dependencyOverrides += "org.slf4j" % "slf4j-api" % "1.7.30"
)
)

lazy val check = taskKey[Unit]("")

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

scalaVersion := "2.12.2-bin-typelevel-4"
scalaOrganization := "org.typelevel"
scalacOptions += "-Yinduction-heuristics"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

scalaVersion := "2.12.8"

organization := "io.get-coursier.test"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

lazy val b = project
.settings(
apiURL := Some(url(s"http://example.org/b")),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@

publishTo := baseDirectory(base => Some(Resolver.file("filesys-publish", base / "repo")) ).value
publishTo := baseDirectory(base => Some(Resolver.file("filesys-publish", base / "repo"))).value

resolvers += baseDirectory(base => "filesys" at (base / "repo").toURI.toString).value

Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
12 changes: 8 additions & 4 deletions modules/sbt-coursier/src/sbt-test/shared-1/caller/build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,19 @@ lazy val app = (project in file("app"))
val coreReport = cr.modules.find(m =>
m.module.name == "core_2.12"
).getOrElse(sys.error("report for core is missing"))
assert(coreReport.callers.exists(c => c.caller.name == "util_2.12"),
s"caller on core is missing util: ${coreReport.callers}")
assert(
coreReport.callers.exists(c => c.caller.name == "util_2.12"),
s"caller on core is missing util: ${coreReport.callers}"
)

// configuration report must include a module report for library dependency
val shapelessReport = cr.modules.find(m =>
m.module.name == "shapeless_2.12"
).getOrElse(sys.error("report for shapeless is missing"))
assert(shapelessReport.callers.exists(c => c.caller.name == "app_2.12"),
s"caller on shapeless is missing self module (app): ${shapelessReport.callers}")
assert(
shapelessReport.callers.exists(c => c.caller.name == "app_2.12"),
s"caller on shapeless is missing self module (app): ${shapelessReport.callers}"
)
}
)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
2 changes: 1 addition & 1 deletion modules/sbt-coursier/src/sbt-test/shared-1/clean/build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ val checkNotEmpty = TaskKey[Unit]("checkNotEmpty")

checkNotEmpty := {
assert(!coursier.Helper.checkEmpty)
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
Original file line number Diff line number Diff line change
@@ -1 +1 @@
object Main extends App
object Main extends App
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
Original file line number Diff line number Diff line change
@@ -1 +1 @@
object Main extends App
object Main extends App
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
Original file line number Diff line number Diff line change
@@ -1 +1 @@
object Main extends App
object Main extends App
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
Original file line number Diff line number Diff line change
@@ -1 +1 @@
object Main extends App
object Main extends App
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
Original file line number Diff line number Diff line change
@@ -1 +1 @@
object Main extends App
object Main extends App
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
Original file line number Diff line number Diff line change
@@ -1 +1 @@
object Main extends App
object Main extends App
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ addSbtPlugin {
)

"io.get-coursier" % name % version
}
}
Original file line number Diff line number Diff line change
@@ -1 +1 @@
object Main extends App
object Main extends App
Loading