-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #217 from laserdisc-io/use-plugin
use the laserdisc plugin
- Loading branch information
Showing
8 changed files
with
101 additions
and
122 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,25 +12,24 @@ jobs: | |
strategy: | ||
matrix: | ||
scala: | ||
- 2.13.11 | ||
- 3.3.0 | ||
- 2.13.15 | ||
- 3.3.4 | ||
java: | ||
- [email protected] | ||
- [email protected] | ||
os: | ||
- ubuntu-22.04 | ||
runs-on: ${{ matrix.os }} | ||
steps: | ||
- name: Branch Checkout | ||
uses: actions/checkout@v2.5.0 | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
- name: Install Java And Sbt | ||
uses: olafurpg/setup-scala@v13 | ||
uses: olafurpg/setup-scala@v14 | ||
with: | ||
java-version: ${{ matrix.java }} | ||
- name: Cache | ||
uses: actions/cache@v2 | ||
uses: actions/cache@v4 | ||
with: | ||
path: | | ||
$HOME/.cache/coursier | ||
|
@@ -42,7 +41,7 @@ jobs: | |
project/target | ||
key: ${{ runner.os }}-cache-v2-${{ hashFiles('**/*.sbt') }}-${{ hashFiles('project/build.properties') }} | ||
- name: Test (${{ matrix.scala }}, ${{ matrix.java }}) | ||
run: sbt ++${{ matrix.scala }} fullTest | ||
run: sbt ++${{ matrix.scala }} build | ||
- name: Upload To Codecov | ||
uses: codecov/codecov-action@v2 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,42 @@ | ||
.terraform/ | ||
# ------------------ autogenerated file - do not edit ------------------- | ||
# This file was generated by sbt-laserdisc-defaults | ||
# | ||
# Please check in any changes generated in this file (for IDE support) | ||
# | ||
# To make changes, please publish a new version of the plugin at: | ||
# https://github.com/laserdisc-io/sbt-laserdisc-defaults | ||
# | ||
# To temporarily disable generation, set this at the top of build.sbt: | ||
# ThisBuild / laserdiscGitIgnoreGenOn := false | ||
# ----------------------------------------------------------------------- | ||
|
||
# tip: use a "global" gitignore (core.excludesfile) for your own, local, personal preferences | ||
# See: https://gist.github.com/subfuzion/db7f57fff2fb6998a16c | ||
|
||
# scala / sbt / java | ||
project/project/ | ||
project/target/ | ||
target/ | ||
.sbtopts | ||
.tasty | ||
|
||
# intellij | ||
.idea/ | ||
.idea/* | ||
*.iml | ||
|
||
# metals / bsp | ||
.metals/ | ||
.bloop/ | ||
.bsp/ | ||
.jvmopts | ||
.DS_Store | ||
project/metals.sbt | ||
|
||
# vscode | ||
.vscode/ | ||
|
||
# terraform | ||
.terraform/ | ||
*.tfplan | ||
*.terraform.lock.hcl | ||
|
||
# mac | ||
.DS_Store |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,79 +1,14 @@ | ||
lazy val scala213 = "2.13.15" | ||
lazy val scala3 = "3.3.4" | ||
lazy val supportedScalaVersions = List(scala213, scala3) | ||
ThisBuild / crossScalaVersions := supportedScalaVersions | ||
ThisBuild / scalaVersion := scala213 | ||
import laserdisc.sbt.CompileTarget.Scala2And3 | ||
import laserdisc.sbt.LaserDiscDevelopers.Barry | ||
|
||
lazy val publishSettings = Seq( | ||
Test / publishArtifact := false, | ||
pomIncludeRepository := (_ => false), | ||
organization := "io.laserdisc", | ||
homepage := Some(url("http://laserdisc.io/slack4s")), | ||
developers := List( | ||
Developer("barryoneill", "Barry O'Neill", "", url("https://github.com/barryoneill")) | ||
), | ||
scmInfo := Some( | ||
ScmInfo( | ||
url("https://github.com/laserdisc-io/slack4s/tree/master"), | ||
"scm:git:[email protected]:laserdisc-io/slack4s.git" | ||
) | ||
), | ||
licenses := Seq( | ||
"MIT" -> url("https://raw.githubusercontent.com/laserdisc-io/slack4s/master/LICENSE") | ||
) | ||
) | ||
ThisBuild / laserdiscRepoName := "slack4s" | ||
ThisBuild / laserdiscCompileTarget := Scala2And3 | ||
|
||
lazy val root = project | ||
.in(file(".")) | ||
.settings( | ||
name := "slack4s", | ||
publishSettings, | ||
Seq( | ||
libraryDependencies ++= Seq( | ||
compilerPlugin(("org.typelevel" %% "kind-projector" % "0.13.3").cross(CrossVersion.full)), | ||
compilerPlugin("com.olegpy" %% "better-monadic-for" % "0.3.1") | ||
).filterNot(_ => scalaVersion.value.startsWith("3.")), | ||
scalacOptions ++= Seq( | ||
"-deprecation", | ||
"-encoding", | ||
"UTF-8", | ||
"-feature", | ||
"-language:existentials,experimental.macros,higherKinds,implicitConversions,postfixOps", | ||
"-unchecked", | ||
"-Xfatal-warnings" | ||
), | ||
scalacOptions ++= { | ||
CrossVersion.partialVersion(scalaVersion.value) match { | ||
case Some((2, minor)) if minor >= 13 => | ||
Seq( | ||
"-Xlint:-unused,_", | ||
"-Ywarn-numeric-widen", | ||
"-Ywarn-value-discard", | ||
"-Ywarn-unused:implicits", | ||
"-Ywarn-unused:imports", | ||
"-Xsource:3", | ||
"-Xlint:-byname-implicit", | ||
"-P:kind-projector:underscore-placeholders", | ||
"-Xlint", | ||
"-Ywarn-macros:after" | ||
) | ||
case _ => Seq.empty | ||
} | ||
}, | ||
scalacOptions ++= { | ||
CrossVersion.partialVersion(scalaVersion.value) match { | ||
case Some((3, _)) => | ||
Seq( | ||
"-Ykind-projector:underscores", | ||
"-source:future", | ||
"-language:adhocExtensions", | ||
"-Wconf:msg=`= _` has been deprecated; use `= uninitialized` instead.:s" | ||
) | ||
case _ => Seq.empty | ||
} | ||
} | ||
), | ||
Test / fork := true, | ||
name := "slack4s", | ||
developers := List(Barry), | ||
// ------------------------- deps ------------------------- | ||
excludeDependencies += "commons-logging", | ||
Dependencies.TestLib, | ||
|
@@ -85,9 +20,6 @@ lazy val root = project | |
Dependencies.Slack, | ||
// ------------------ version fmt + buildinfo ------------------ | ||
buildInfoKeys := Seq[BuildInfoKey](name, version, scalaVersion, sbtVersion), | ||
buildInfoPackage := "slack4s", | ||
addCommandAlias("format", ";scalafmtAll;scalafmtSbt"), | ||
addCommandAlias("checkFormat", ";scalafmtCheckAll;scalafmtSbtCheck"), | ||
addCommandAlias("fullTest", ";clean;checkFormat;test") | ||
buildInfoPackage := "slack4s" | ||
) | ||
.enablePlugins(BuildInfoPlugin, GitVersioning) | ||
.enablePlugins(BuildInfoPlugin, LaserDiscDefaultsPlugin) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,13 @@ | ||
sbt.version=1.10.2 | ||
# ------------------ autogenerated file - do not edit ------------------- | ||
# This file was generated by sbt-laserdisc-defaults | ||
# | ||
# Please check in any changes generated in this file (for IDE support) | ||
# | ||
# To make changes, please publish a new version of the plugin at: | ||
# https://github.com/laserdisc-io/sbt-laserdisc-defaults | ||
# | ||
# To temporarily disable generation, set this at the top of build.sbt: | ||
# ThisBuild / laserdiscSBTVersionGenOn := false | ||
# ----------------------------------------------------------------------- | ||
|
||
sbt.version = 1.10.5 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
addSbtPlugin("org.scalameta" % "sbt-scalafmt" % "2.5.2") | ||
addSbtPlugin("com.eed3si9n" % "sbt-buildinfo" % "0.12.0") | ||
addSbtPlugin("org.scoverage" % "sbt-scoverage" % "2.0.11") | ||
addSbtPlugin("com.github.sbt" % "sbt-ci-release" % "1.7.0") | ||
addSbtPlugin("io.laserdisc" % "sbt-laserdisc-defaults" % "0.1.1") | ||
addSbtPlugin("com.eed3si9n" % "sbt-buildinfo" % "0.13.1") | ||
addSbtPlugin("org.scoverage" % "sbt-scoverage" % "2.0.12") | ||
addSbtPlugin("com.github.sbt" % "sbt-ci-release" % "1.9.0") |