Skip to content

Commit 6277fa0

Browse files
committed
First try to use sbt-ci-release
1 parent ce2a44c commit 6277fa0

File tree

5 files changed

+41
-40
lines changed

5 files changed

+41
-40
lines changed

.github/workflows/release.yml

+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
name: Release
2+
on:
3+
push:
4+
branches: [master, main]
5+
tags: ["*"]
6+
jobs:
7+
publish:
8+
runs-on: ubuntu-20.04
9+
steps:
10+
- uses: actions/checkout@v3.0.2
11+
with:
12+
fetch-depth: 0
13+
- uses: olafurpg/setup-scala@v13
14+
- run: sbt ci-release
15+
env:
16+
PGP_PASSPHRASE: ${{ secrets.PGP_PASSPHRASE }}
17+
PGP_SECRET: ${{ secrets.PGP_SECRET }}
18+
SONATYPE_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }}
19+
SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }}

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -15,3 +15,4 @@ project/metals.sbt
1515

1616
*/target
1717
target/metals.sbt
18+
/null

.scalafmt.conf

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
1-
version = 2.0.0-RC5
1+
version = "3.5.3"
22

33
maxColumn = 120
44

55
align.openParenCallSite = false
6+
runner.dialect = scala3

build.sbt

+18-39
Original file line numberDiff line numberDiff line change
@@ -1,50 +1,29 @@
11
import sbtcrossproject.CrossPlugin.autoImport.{CrossType, crossProject}
22
import xerial.sbt.Sonatype._
33

4-
val commonSettings = Def.settings(
5-
// publish to the sonatype repository
6-
publishTo := sonatypePublishTo.value
7-
)
8-
9-
ThisBuild / publishTo := sonatypePublishTo.value
10-
ThisBuild / name := "url-dsl"
11-
ThisBuild / organization := "be.doeraene"
12-
ThisBuild / sonatypeProjectHosting := Some(GitHubHosting("sherpal", "url-dsl", "antoine.doeraene@gmail.com"))
13-
ThisBuild / description := "A tiny library for parsing and creating urls in a type-safe way"
14-
ThisBuild / licenses := Seq("MIT" -> url("http://www.opensource.org/licenses/mit-license.php"))
15-
//ThisBuild / homepage := Some(new java.net.URL("https://github.com/sherpal/url-dsl"))
16-
//ThisBuild / developers := List(
17-
// Developer(
18-
// "sherpal",
19-
// "Antoine Doeraene",
20-
// "antoine.doeraene@gmail.com",
21-
// new java.net.URL("https://github.com/sherpal")
22-
// )
23-
//)
24-
//ThisBuild / homepage := Some(url("https://github.com/sherpal/url-dsl"))
25-
26-
sonatypeProjectHosting := Some(GitHubHosting("sherpal", "url-dsl", "antoine.doeraene@gmail.com"))
27-
organization := "be.doeraene"
28-
29-
inThisBuild(
30-
Def.settings(
31-
version := "0.4.1",
32-
crossScalaVersions := Seq("3.2.0", "2.13.5", "2.12.13"),
33-
scalaVersion := crossScalaVersions.value.head,
34-
scalacOptions ++= Seq("-feature", "-deprecation")
35-
)
36-
)
4+
inThisBuild(List(
5+
name := "url-dsl",
6+
organization := "be.doeraene",
7+
description := "A tiny library for parsing and creating urls in a type-safe way",
8+
homepage := Some(url("https://github.com/sherpal/url-dsl")),
9+
licenses := List("MIT" -> url("http://www.opensource.org/licenses/mit-license.php")),
10+
developers := List(
11+
Developer(
12+
"sherpal",
13+
"Antoine Doeraene",
14+
"antoine.doeraene@gmail.com",
15+
url("https://github.com/sherpal")
16+
)
17+
),
18+
crossScalaVersions := Seq("3.2.0", "2.13.5", "2.12.13"),
19+
scalaVersion := crossScalaVersions.value.head,
20+
scalacOptions ++= Seq("-feature", "-deprecation"),
21+
))
3722

3823
lazy val `shared` = crossProject(JSPlatform, JVMPlatform)
3924
.crossType(CrossType.Pure)
4025
.in(file("shared"))
4126
.settings(
42-
name := "url-dsl",
43-
publishTo := sonatypePublishTo.value,
44-
sonatypeProjectHosting := Some(GitHubHosting("sherpal", "url-dsl", "antoine.doeraene@gmail.com")),
45-
organization := "be.doeraene",
46-
description := "A tiny library for parsing and creating urls in a type-safe way",
47-
licenses := Seq("MIT" -> url("http://www.opensource.org/licenses/mit-license.php")),
4827
libraryDependencies ++= Seq(
4928
"org.scalatest" %%% "scalatest" % "3.2.9" % "test",
5029
"org.scalacheck" %%% "scalacheck" % "1.15.4" % "test"

project/plugins.sbt

+1
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,4 @@ val scalaJSVersion =
99

1010
addSbtPlugin("org.portable-scala" % "sbt-scalajs-crossproject" % "1.0.0")
1111
addSbtPlugin("org.scala-js" % "sbt-scalajs" % scalaJSVersion)
12+
addSbtPlugin("com.github.sbt" % "sbt-ci-release" % "1.5.10")

0 commit comments

Comments
 (0)