Skip to content

Commit d649bdb

Browse files
authored
Refactor build.sbt (#71)
* add cross compile * update * cross compile update * remove scripted * update to 2.13 * update * update * remove * sbt verion selection:w * use value * update sbt version * rearrange * rearrange * set module name * update workflow
1 parent b49d3a9 commit d649bdb

File tree

1 file changed

+17
-15
lines changed

1 file changed

+17
-15
lines changed

build.sbt

Lines changed: 17 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,7 @@ This gives you the ability to generate client SDKs, documentation, new generator
77
specifications as part of your build. Other tasks are available as command line tasks.
88
"""
99

10-
lazy val `sbt-openapi-generator` = (project in file("."))
11-
.settings(
12-
scalaVersion := "2.12.20",
13-
crossScalaVersions := Seq(scalaVersion.value),
14-
crossSbtVersions := List("1.11.4"),
15-
sbtPlugin := true,
16-
17-
inThisBuild(List(
10+
inThisBuild(List(
1811
homepage := Some(url("https://openapi-generator.tech")),
1912

2013
organization := "org.openapitools",
@@ -29,21 +22,30 @@ lazy val `sbt-openapi-generator` = (project in file("."))
2922
email = "team@openapitools.org",
3023
url = url("https://github.com/OpenAPITools")
3124
)
32-
)),
25+
))
3326

34-
scriptedLaunchOpts := {
35-
scriptedLaunchOpts.value ++ Seq("-Xmx1024M", "-server", "-Dplugin.version=" + version.value)
36-
},
27+
crossScalaVersions := Nil
3728

38-
scriptedBufferLog := false,
29+
lazy val `sbt-openapi-generator` = (project in file("."))
30+
.enablePlugins(SbtPlugin)
31+
.settings(
32+
moduleName := "sbt-openapi-generator",
33+
crossScalaVersions := Seq("2.12.20"),
34+
sbtPlugin := true,
35+
//crossScalaVersions := Seq("2.12.20", "3.7.2"),
36+
//(pluginCrossBuild / sbtVersion) := {
37+
// scalaBinaryVersion.value match {
38+
// case "2.12" => "1.11.4"
39+
// case _ => "2.0.0-RC3"
40+
// }
41+
//},
3942

4043
resolvers ++= Seq(
4144
Resolver.sbtPluginRepo("snapshots"),
4245
),
4346

4447
//version := "7.14.0",
4548

46-
4749
scmInfo := Some(
4850
ScmInfo(
4951
browseUrl = url("https://github.com/OpenAPITools/openapi-generator"),
@@ -52,4 +54,4 @@ lazy val `sbt-openapi-generator` = (project in file("."))
5254
),
5355

5456
libraryDependencies += "org.openapitools" % "openapi-generator" % "7.14.0"
55-
).enablePlugins(SbtPlugin)
57+
)

0 commit comments

Comments
 (0)