Skip to content

Commit cec7282

Browse files
authored
Merge pull request #6 from whisklabs/update
Update
2 parents 4292679 + 1a9ec9a commit cec7282

File tree

8 files changed

+16
-13
lines changed

8 files changed

+16
-13
lines changed

.git-blame-ignore-revs

+3
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,6 @@
33

44
# Scala Steward: Reformat with scalafmt 3.8.0
55
00d482c75c16b0791a717e6374de4adf225f8af1
6+
7+
# Scala Steward: Reformat with scalafmt 3.8.6
8+
9556ab3724f06bc35adc5f6a1cc4d21043fb3525

.github/workflows/ci.yml

+2
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,8 @@ jobs:
4141
java-version: "21"
4242
distribution: 'temurin'
4343

44+
- uses: sbt/setup-sbt@v1
45+
4446
- name: restore cache
4547
uses: ./.github/actions/scala_restore_cache
4648
with:

.scalafmt.conf

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
version=3.8.3
1+
version=3.9.2
22
style = defaultWithAlign
33
maxColumn = 100
44
assumeStandardLibraryStripMargin = true

README.md

-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
sbt-protoc
22
==========
3-
[![CI](https://github.com/thesamet/sbt-protoc/workflows/CI/badge.svg)](https://github.com/thesamet/sbt-protoc/actions?query=workflow%3ACI)
4-
53
This plugin uses protoc to generate code from proto files. This SBT plugin is
64
meant to supersede
75
[sbt-protobuf](https://github.com/sbt/sbt-protobuf/) and
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
sbt.version=1.10.5
1+
sbt.version=1.10.7

project/build.properties

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
sbt.version=1.10.5
1+
sbt.version=1.10.7

project/plugins.sbt

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
libraryDependencies += "org.scala-sbt" %% "scripted-plugin" % sbtVersion.value
22

3-
addSbtPlugin("org.scalameta" % "sbt-scalafmt" % "2.5.0")
3+
addSbtPlugin("org.scalameta" % "sbt-scalafmt" % "2.5.4")
44

55
credentials += Credentials(Path.userHome / ".m2" / ".credentials")
66
resolvers += "internal.repo.read" at "https://nexus.whisk-dev.com/repository/whisk-maven-group/"
7-
addSbtPlugin("com.whisk" % "whisk-sbt-plugin" % "2024.10.29-2357")
7+
addSbtPlugin("com.whisk" % "whisk-sbt-plugin" % "2025.04.09-3153")

src/main/scala/sbtprotoc/ProtocPlugin.scala

+6-6
Original file line numberDiff line numberDiff line change
@@ -292,7 +292,7 @@ object ProtocPlugin extends AutoPlugin {
292292
s"""PB.protocVersion must contain a dot-separated version number. For example: "3.13.0". Got: '${PB.protocVersion.value}'"""
293293
)
294294
}
295-
("com.google.protobuf" % "protoc" % version) asProtocBinary (),
295+
("com.google.protobuf" % "protoc" % version) asProtocBinary ()
296296
},
297297
PB.protocExecutable := {
298298
scala.concurrent.Await.result(
@@ -465,7 +465,7 @@ object ProtocPlugin extends AutoPlugin {
465465

466466
targets.flatMap {
467467
case Target(DescriptorSetGenerator(), outputFile, _) => Seq(outputFile)
468-
case Target(_, outputDirectory, _) => outputDirectory.allPaths.get
468+
case Target(_, outputDirectory, _) => outputDirectory.allPaths.get()
469469
}.toSet
470470
} else if (schemas.nonEmpty && targets.isEmpty) {
471471
log.info("Protobufs files found, but PB.targets is empty.")
@@ -552,7 +552,8 @@ object ProtocPlugin extends AutoPlugin {
552552
sources
553553
.toSet[File]
554554
.flatMap(srcDir =>
555-
(srcDir ** (toInclude -- toExclude)).get
555+
(srcDir ** (toInclude -- toExclude))
556+
.get()
556557
.map(_.getAbsoluteFile)
557558
) match {
558559
case protos if protos.nonEmpty =>
@@ -622,8 +623,7 @@ object ProtocPlugin extends AutoPlugin {
622623
{ (_, prevValue) =>
623624
def stampClasspath(files: Seq[File]) =
624625
// artifact paths can be JARs or directories, so a recursive stamp is needed
625-
FileInfo.hash(files.toSet[File].allPaths.get.toSet)
626-
626+
FileInfo.hash(files.toSet[File].allPaths.get().toSet)
627627
if (prevValue == null) {
628628
// first time this classpath is requested since the start of sbt
629629
val resolved = resolver(artifact)
@@ -711,7 +711,7 @@ object ProtocPlugin extends AutoPlugin {
711711
val sandboxedArtifactsStamps =
712712
stampedClassLoadersByArtifact.values.map(_._1).toSeq
713713
val inputStamp =
714-
FileInfo.hash(schemas ++ arguments.includePaths.allPaths.get)
714+
FileInfo.hash(schemas ++ arguments.includePaths.allPaths.get())
715715
cachedCompile((arguments, sandboxedArtifactsStamps :+ inputStamp)).toSeq
716716
}
717717
}

0 commit comments

Comments
 (0)