Skip to content

Commit

Permalink
Made required changes to Publish ZIO Http under dev.zio (#1748)
Browse files Browse the repository at this point in the history
  • Loading branch information
Dhirendra Kumar Kashyap authored Nov 4, 2022
1 parent ded09fc commit 28ad22a
Showing 1 changed file with 19 additions and 6 deletions.
25 changes: 19 additions & 6 deletions project/BuildHelper.scala
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ object BuildHelper extends ScalaSettings {
"UTF-8",
"-feature",
"-unchecked",
"-language:postfixOps",
"-language:postfixOps"
) ++ {
if (sys.env.contains("CI")) {
Seq("-Xfatal-warnings")
Expand All @@ -37,14 +37,27 @@ object BuildHelper extends ScalaSettings {
val publishSettings = Seq(
organization := "dev.zio",
organizationName := "zio",
licenses += ("MIT License", new URL("https://github.com/zio/zio-http/blob/master/LICENSE")),
licenses := Seq("MIT License" -> url("https://github.com/zio/zio-http/blob/master/LICENSE")),
sonatypeCredentialHost := "oss.sonatype.org",
sonatypeRepository := "https://oss.sonatype.org/service/local",
sonatypeProfileName := "dev.zio",
publishTo := sonatypePublishToBundle.value,
sonatypeTimeoutMillis := 300 * 60 * 1000,
publishMavenStyle := true,
credentials ++=
(for {
username <- Option(System.getenv().get("SONATYPE_USERNAME"))
password <- Option(System.getenv().get("SONATYPE_PASSWORD"))
} yield Credentials(
"Sonatype Nexus Repository Manager",
"oss.sonatype.org",
username,
password
)).toSeq
)
val skipSettings = Seq(
publish / skip := true,
publishArtifact := false,
publishArtifact := false
)
if (publishArtifacts) publishSettings else publishSettings ++ skipSettings
}
Expand All @@ -68,12 +81,12 @@ object BuildHelper extends ScalaSettings {
"-Dio.netty.leakDetectionLevel=paranoid",
s"-DZIOHttpLogLevel=${Debug.ZIOHttpLogLevel}",
),
ThisBuild / fork := true,
ThisBuild / fork := true
)

def runSettings(className: String = "example.HelloWorld") = Seq(
fork := true,
Compile / run / mainClass := Option(className),
Compile / run / mainClass := Option(className)
)

def meta = Seq(
Expand All @@ -94,7 +107,7 @@ object BuildHelper extends ScalaSettings {
"Amit Kumar Singh",
"[email protected]",
new URL("https://github.com/amitksingh1490"),
),
)
),
)
}

0 comments on commit 28ad22a

Please sign in to comment.