Skip to content

Commit b2d4f3d

Browse files
authored
Merge branch 'master' into update/scalatest-3.2.19
2 parents 2ea6e83 + 40be500 commit b2d4f3d

File tree

73 files changed

+328
-276
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

73 files changed

+328
-276
lines changed

.git-blame-ignore-revs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# Scala Steward: Reformat with scalafmt 3.8.3
2+
fb3b1e158c70f5b76207764dc42b128cb878b3be

.scalafmt.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Version https://scalameta.org/scalafmt/docs/configuration.html#version
2-
version = 3.8.1
2+
version = 3.8.3
33
# Dialect https://scalameta.org/scalafmt/docs/configuration.html#scala-dialects
44
runner.dialect = scala212
55

integration-tests-ansible/test-project-play-rpm/build.sbt

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,6 @@
11
scalaVersion in ThisBuild := "2.11.6"
22

3-
scalacOptions in ThisBuild ++= Seq(
4-
"-deprecation",
5-
"-encoding",
6-
"UTF-8",
7-
"-feature",
8-
"-unchecked",
9-
"-Xfuture",
10-
"-Xlint"
11-
)
3+
scalacOptions in ThisBuild ++= Seq("-deprecation", "-encoding", "UTF-8", "-feature", "-unchecked", "-Xfuture", "-Xlint")
124

135
name := "test-project-play-rpm"
146

src/main/scala-sbt-0.13/com/typesafe/sbt/packager/Compat.scala

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,15 @@ object Compat {
99
/**
1010
* Used in:
1111
*
12-
* - [[com.typesafe.sbt.packager.windows.WindowsPlugin]]
13-
* - [[com.typesafe.sbt.packager.rpm.RpmHelper]]
14-
* - [[com.typesafe.sbt.packager.docker.DockerPlugin]]
15-
* - [[com.typesafe.sbt.packager.debian.DebianNativePackaging]]
16-
* - [[com.typesafe.sbt.packager.rpm.RpmPlugin]]
12+
* - [[com.typesafe.sbt.packager.windows.WindowsPlugin]]
13+
* - [[com.typesafe.sbt.packager.rpm.RpmHelper]]
14+
* - [[com.typesafe.sbt.packager.docker.DockerPlugin]]
15+
* - [[com.typesafe.sbt.packager.debian.DebianNativePackaging]]
16+
* - [[com.typesafe.sbt.packager.rpm.RpmPlugin]]
1717
*
1818
* @param log
19-
* @return turns a Logger into a ProcessLogger
19+
* @return
20+
* turns a Logger into a ProcessLogger
2021
*/
2122
implicit def log2ProcessLogger(log: Logger): sys.process.ProcessLogger =
2223
new BufferedLogger(new FullLogger(log)) with sys.process.ProcessLogger {
@@ -27,17 +28,20 @@ object Compat {
2728
/**
2829
* Used in
2930
*
30-
* - [[com.typesafe.sbt.packager.docker.DockerPlugin]]
31+
* - [[com.typesafe.sbt.packager.docker.DockerPlugin]]
3132
*
32-
* @param logger The sbt.ProcessLogger that should be wrapped
33-
* @return A scala ProcessLogger
33+
* @param logger
34+
* The sbt.ProcessLogger that should be wrapped
35+
* @return
36+
* A scala ProcessLogger
3437
*/
3538
implicit def sbtProcessLogger2ScalaProcessLogger(logger: sbt.ProcessLogger): sys.process.ProcessLogger =
3639
ProcessLogger(msg => logger.info(msg), err => logger.error(err))
3740

3841
/**
3942
* Use in the scripted `universal/multiproject-classifiers` test.
40-
* @param artifact polyfill new methods
43+
* @param artifact
44+
* polyfill new methods
4145
*/
4246
implicit class CompatArtifact(artifact: Artifact) {
4347
def withClassifier(classifier: Option[String]): Artifact =

src/main/scala-sbt-0.13/com/typesafe/sbt/packager/MappingsHelper.scala

Lines changed: 41 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,13 @@ object MappingsHelper {
99
* return a Seq of mappings which effect is to add a whole directory in the generated package
1010
*
1111
* @example
12-
* {{{
12+
* {{{
1313
* mappings in Universal ++= directory(baseDirectory.value / "extra")
14-
* }}}
14+
* }}}
1515
*
1616
* @param sourceDir
17-
* @return mappings
17+
* @return
18+
* mappings
1819
*/
1920
def directory(sourceDir: File): Seq[(File, String)] =
2021
Option(sourceDir.getParentFile)
@@ -25,27 +26,29 @@ object MappingsHelper {
2526
* It lightens the build file if one wants to give a string instead of file.
2627
*
2728
* @example
28-
* {{{
29+
* {{{
2930
* mappings in Universal ++= directory("extra")
30-
* }}}
31+
* }}}
3132
*
3233
* @param sourceDir
33-
* @return mappings
34+
* @return
35+
* mappings
3436
*/
3537
def directory(sourceDir: String): Seq[(File, String)] =
3638
directory(file(sourceDir))
3739

3840
/**
39-
* return a Seq of mappings which effect is to add the content of directory in the generated package,
40-
* excluding the directory itself.
41+
* return a Seq of mappings which effect is to add the content of directory in the generated package, excluding the
42+
* directory itself.
4143
*
4244
* @example
43-
* {{{
45+
* {{{
4446
* mappings in Universal ++= sourceDir(baseDirectory.value / "extra")
45-
* }}}
47+
* }}}
4648
*
4749
* @param sourceDir
48-
* @return mappings
50+
* @return
51+
* mappings
4952
*/
5053
def contentOf(sourceDir: File): Seq[(File, String)] =
5154
(sourceDir.*** --- sourceDir) pair relativeTo(sourceDir)
@@ -54,50 +57,57 @@ object MappingsHelper {
5457
* It lightens the build file if one wants to give a string instead of file.
5558
*
5659
* @example
57-
* {{{
60+
* {{{
5861
* mappings in Universal ++= sourceDir("extra")
59-
* }}}
62+
* }}}
6063
*
61-
* @param sourceDir as string representation
62-
* @return mappings
64+
* @param sourceDir
65+
* as string representation
66+
* @return
67+
* mappings
6368
*/
6469
def contentOf(sourceDir: String): Seq[(File, String)] =
6570
contentOf(file(sourceDir))
6671

6772
/**
68-
* Create mappings from your classpath. For example if you want to add additional
69-
* dependencies, like test or model.
73+
* Create mappings from your classpath. For example if you want to add additional dependencies, like test or model.
7074
*
71-
* @example Add all test artifacts to a separated test folder
72-
* {{{
75+
* @example
76+
* Add all test artifacts to a separated test folder
77+
* {{{
7378
* mappings in Universal ++= fromClasspath((managedClasspath in Test).value, target = "test")
74-
* }}}
79+
* }}}
7580
*
7681
* @param entries
7782
* @param target
78-
* @return a list of mappings
83+
* @return
84+
* a list of mappings
7985
*/
8086
def fromClasspath(entries: Seq[Attributed[File]], target: String): Seq[(File, String)] =
8187
fromClasspath(entries, target, _ => true)
8288

8389
/**
84-
* Create mappings from your classpath. For example if you want to add additional
85-
* dependencies, like test or model. You can also filter the artifacts that should
86-
* be mapped to mappings.
90+
* Create mappings from your classpath. For example if you want to add additional dependencies, like test or model.
91+
* You can also filter the artifacts that should be mapped to mappings.
8792
*
88-
* @example Filter all osgi bundles
89-
* {{{
93+
* @example
94+
* Filter all osgi bundles
95+
* {{{
9096
* mappings in Universal ++= fromClasspath(
9197
* (managedClasspath in Runtime).value,
9298
* "osgi",
9399
* artifact => artifact.`type` == "bundle"
94100
* )
95-
* }}}
101+
* }}}
96102
*
97-
* @param entries from where mappings should be created from
98-
* @param target folder, e.g. `model`. Must not end with a slash
99-
* @param includeArtifact function to determine if an artifact should result in a mapping
100-
* @param includeOnNoArtifact default is false. When there's no Artifact meta data remove it
103+
* @param entries
104+
* from where mappings should be created from
105+
* @param target
106+
* folder, e.g. `model`. Must not end with a slash
107+
* @param includeArtifact
108+
* function to determine if an artifact should result in a mapping
109+
* @param includeOnNoArtifact
110+
* default is false. When there's no Artifact meta data remove it
101111
*/
102112
def fromClasspath(
103113
entries: Seq[Attributed[File]],

src/main/scala-sbt-0.13/com/typesafe/sbt/packager/SettingsHelper.scala

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -72,8 +72,8 @@ object SettingsHelper {
7272
) ++ addPackage(config, packageTask, extension, classifier) ++ addResolver(config)
7373

7474
/**
75-
* SBT looks in the `otherResolvers` setting for resolvers defined in `publishTo`.
76-
* If a user scopes a `publishTo`, e.g.
75+
* SBT looks in the `otherResolvers` setting for resolvers defined in `publishTo`. If a user scopes a `publishTo`,
76+
* e.g.
7777
*
7878
* {{{
7979
* // publish the rpm to the target folder
@@ -82,7 +82,8 @@ object SettingsHelper {
8282
*
8383
* then the resolver must also be present in the `otherResolvers`
8484
*
85-
* @param config the ivy configuration to look for resolvers
85+
* @param config
86+
* the ivy configuration to look for resolvers
8687
*/
8788
private def addResolver(config: Configuration): Seq[Setting[_]] =
8889
Seq(otherResolvers ++= (publishTo in config).value.toSeq)

src/main/scala/com/typesafe/sbt/packager/docker/DockerPlugin.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -383,7 +383,7 @@ object DockerPlugin extends AutoPlugin {
383383
* FROM command
384384
*/
385385
private final def makeFromAs(dockerBaseImage: String, name: String): CmdLike =
386-
Cmd("FROM", dockerBaseImage, "as", name)
386+
Cmd("FROM", dockerBaseImage, "AS", name)
387387

388388
/**
389389
* @param label

src/sbt-test/ash/add-app-settings/build.sbt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,9 @@ TaskKey[Unit]("scriptCheck") := {
1515

1616
TaskKey[Unit]("runCheck") := {
1717
val cwd = (stagingDirectory in Universal).value
18-
val cmd = Seq((cwd / "bin" / packageName.value).getAbsolutePath)
18+
val cmd = Seq((cwd / "bin" / packageName.value).getAbsolutePath)
1919
val output = (sys.process.Process(cmd, cwd).!!).replaceAll("\n", "")
20-
20+
2121
assert(output.contains("info"), s"Application did not receive residual arg 'info'")
2222
assert(output.contains("help"), s"Application did not receive residual arg 'help'")
2323
}
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
object MainApp extends App {
1+
object MainApp extends App {
22
println(args.mkString("|"))
33
}

src/sbt-test/ash/command-line-settings/build.sbt

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,23 @@ TaskKey[Unit]("checkResidual") := {
2323
}
2424

2525
TaskKey[Unit]("checkComplexResidual") := {
26-
val args = Seq("-J-Dfoo=bar", "arg1", "--", "-J-Dfoo=bar", "arg 2", "--", "\"", "$foo", "'", "%s", "-y", "bla", "\\'", "\\\"", "''")
26+
val args = Seq(
27+
"-J-Dfoo=bar",
28+
"arg1",
29+
"--",
30+
"-J-Dfoo=bar",
31+
"arg 2",
32+
"--",
33+
"\"",
34+
"$foo",
35+
"'",
36+
"%s",
37+
"-y",
38+
"bla",
39+
"\\'",
40+
"\\\"",
41+
"''"
42+
)
2743
val cwd = (stagingDirectory in Universal).value
2844
val cmd = Seq((cwd / "bin" / packageName.value).getAbsolutePath) ++ args
2945
val expected = """arg1|-J-Dfoo=bar|arg 2|--|"|$foo|'|%s|-y|bla|\'|\"|''"""

0 commit comments

Comments
 (0)