@@ -11,7 +11,7 @@ val isScala3 = Def.setting(
1111 CrossVersion .partialVersion(scalaVersion.value).exists(_._1 == 3 )
1212)
1313
14- def gitHash (): String = sys.process.Process (" git rev-parse HEAD" ).lineStream_ !.head
14+ def gitHash (): String = sys.process.Process (" git rev-parse HEAD" ).lazyLines_ !.head
1515
1616val tagName = Def .setting {
1717 s " v ${if (releaseUseGlobalVersion.value) (ThisBuild / version).value
@@ -21,13 +21,14 @@ val tagOrHash = Def.setting {
2121 if (isSnapshot.value) gitHash() else tagName.value
2222}
2323
24- val runAll = TaskKey [Unit ](" runAll" )
24+ @ transient
25+ val runAll = taskKey[Unit ](" " )
2526
2627def runAllIn (config : Configuration ): Setting [Task [Unit ]] = {
2728 (config / runAll) := {
2829 val classes = (config / discoveredMainClasses).value
2930 val runner0 = (run / runner).value
30- val cp = (config / fullClasspath).value
31+ val cp = (config / fullClasspath).value.map(x => Attributed .blank(fileConverter.value.toPath(x.data)))
3132 val s = streams.value
3233 classes.foreach(c => runner0.run(c, Attributed .data(cp), Seq (), s.log))
3334 }
@@ -125,15 +126,15 @@ val commonSettings = Def.settings(
125126 }
126127 },
127128 libraryDependencies ++= List (
128- " com.github.scalaprops" %%% " scalaprops" % scalapropsVersion.value % " test" ,
129- " org.scalaz" %%% " scalaz-core" % " 7.3.9"
129+ " com.github.scalaprops" %% " scalaprops" % scalapropsVersion.value % " test" ,
130+ " org.scalaz" %% " scalaz-core" % " 7.3.9"
130131 ),
131132 libraryDependencies ++= {
132133 if (isScala3.value) {
133134 Nil
134135 } else {
135136 Seq (
136- compilerPlugin(" org.typelevel" % " kind-projector" % " 0.13.4" cross CrossVersion .full)
137+ compilerPlugin(( " org.typelevel" % " kind-projector" % " 0.13.4" ). cross( CrossVersion .full) )
137138 )
138139 }
139140 }
@@ -210,17 +211,18 @@ val example = projectMatrix
210211 optparseApplicative
211212 )
212213
213- commonSettings
214- noPublish
215-
216- TaskKey [Unit ](" testSequential" ) := Def
217- .sequential(
218- (optparseApplicative.projectRefs ++ example.projectRefs).map { x =>
219- Def .sequential(
220- Def .task(streams.value.log.info(s " start ${(x / thisProject).value.id} test " )),
221- x / Test / test,
222- Def .task(streams.value.log.info(s " end ${(x / thisProject).value.id} test " ))
223- )
224- }
225- )
226- .value
214+ val optparseApplicativeRoot = rootProject.autoAggregate.settings(
215+ commonSettings,
216+ noPublish,
217+ TaskKey [Unit ](" testSequential" ) := Def
218+ .sequential(
219+ (optparseApplicative.projectRefs ++ example.projectRefs).map { x =>
220+ Def .sequential(
221+ Def .task(streams.value.log.info(s " start ${(x / thisProject).value.id} test " )),
222+ x / Test / testFull,
223+ Def .task(streams.value.log.info(s " end ${(x / thisProject).value.id} test " ))
224+ )
225+ }
226+ )
227+ .value
228+ )
0 commit comments