Releases: typelevel/sbt-typelevel
v0.6.2
This is the third release in the sbt-typelevel 0.6.x series. mdoc now requires JDK 11+ and the sbt-typelevel-site plugin will now automatically configure a sufficiently modern JVM for the site generation job.
Features
- Expose
tlSiteJavaVersion
, auto-config to JDK 11+ by @armanbilge in #660
Updates
- Update mdoc, sbt-mdoc to 2.5.1 by @typelevel-steward in #661
- Update scalac-compat-annotation to 0.1.3 by @typelevel-steward in #663
Full Changelog: v0.6.1...v0.6.2
v0.6.1
This is the second release in the sbt-typelevel 0.6.x series. It fixes issues with the scalac-compat-annotation
library and introduces a new, composable way for defining command aliases.
Features
- Introduce
tlCommandAliases
setting for defining command aliases by @armanbilge in #652
Fixes
Updates
- Update mdoc, sbt-mdoc to 2.4.0 by @typelevel-steward in #650
- Update sbt to 1.9.7 by @typelevel-steward in #651
Full Changelog: v0.6.0...v0.6.1
v0.6.0
This is the first release in the sbt-typelevel v0.6.x series! The sole reason for the minor bump is to upgrade to Laika v1.0.0 in the sbt-typelevel-site plugin. In all other respects this release remains entirely compatible with the v0.5.x series and for most projects the upgrade will be straightforward, if not trivial.
A round of applause for @jenshalm whose tireless work on Laika has fostered documentation across the Typelevel and Scala ecosystems! 👏
What's Changed
- migrate to Laika 1.0.0 by @jenshalm in #646
- Update mdoc, sbt-mdoc to 2.3.8 by @typelevel-steward in #649
Full Changelog: v0.5.4...v0.6.0
v0.5.4
This is the fifth release in the 0.5.x series.
Fixes
- Glorious hack to fix publishing key import on macOS runners by @armanbilge in #648
Full Changelog: v0.5.3...v0.5.4
v0.5.3
This is the fourth release in the 0.5.x series.
Features
- Support customizing publish job
needs
by @armanbilge in #645
Fixes
cat=scala3-migration
only exists in 2.13.12+ by @armanbilge in #640- Added version bound check and added slash by @j-mie6 in #643
Updates
- Update laika-sbt to 0.19.5 by @typelevel-steward in #641
- Update sbt to 1.9.6 by @typelevel-steward in #644
Full Changelog: v0.5.2...v0.5.3
v0.5.2
This is the third release in the 0.5.x series. It silences the migration warnings raised by -Xsource:3
on Scala 2.13. These warnings are effectively "unfixable FYIs" that otherwise need to be @nowarn
ed.
Fixes
- Add
-Wconf:cat=scala3-migration:s
on 2.13 by @armanbilge in #639
Full Changelog: v0.5.1...v0.5.2
v0.5.1
This is the second release in the 0.5.x series. It adds support for Scala v2.13.12.
Updates
- Update sbt to 1.9.4 by @typelevel-steward in #627
- Update sbt-scalafmt to 2.5.2 by @typelevel-steward in #631
- Update to checkout v4 by @armanbilge in #633
- Update sbt-scalafix to 0.11.1 by @typelevel-steward in #638
Full Changelog: v0.5.0...v0.5.1
v0.5.0
This is the first release in the sbt-typelevel v0.5.x series! It brings several enhancements, unfortunately some of which may break existing builds. However for many projects with standard builds I expect upgrading to be simple and straightforward.
Over the course of 12 RCs I have personally upgraded a handful of projects. In my experience the roughest bit was the scalacOptions
changes: specifically the new warnings and also some subtle changes to type inference and implicit resolution. However while working through these warnings, I did identify and fix a couple of bugs ... YMMV ;)
Thank you to everyone who has contributed to this and previous releases! Special thanks to @satorg, @mzuehlke, @j-mie6, @etspaceman, @bpholt, @jenshalm for collaborations and contributions, early adoption and issue reporting, and keeping things fun on Discord :)
Major changes
sbt v1.9.0
sbt-typelevel now requires sbt v1.9.0+.
CI jobs identified by Scala binary version
Previously, CI jobs were identified by the full Scala version e.g. 2.13.11
or 3.2.2
. Now, they are identified only by the binary version e.g. 2.13
or 3
. This means that CI job names are now stable to Scala updates.
However, if you have customized your CI matrix with exclusions or conditions based on the Scala version you will need to update those to match only on the binary version. To restore the old behavior set githubWorkflowScalaVersions := scalaCrossVersions.value
.
- Use semantic version selector for
++
by @armanbilge in #400
Other enhancements
- Populate
releaseNotesURL
setting by @armanbilge in #532 - javadoc.io now supports sbt plugins by @armanbilge in #585
Refreshed scalac
options
Compiler options are now optimized for the following Scala versions. If possible, please upgrade to these versions first.
- Scala 2.12.18+, Scala 2.13.11+, Scala 3.3.0+
Scala 2 is now tuned to behave like Scala 3, not the other way around
Previously, our compiler flags were tuned to make Scala 3 behave more like Scala 2 e.g. with -source:3.0-migration
. Now, we have removed that flag and are instead tuning Scala 2 to behave more like Scala 3 e.g. with -Xsource:3
.
One example of a common pattern where this makes a difference is a case class
with a private
constructor.
case class Foo private (bar: Bar, baz: Baz)
Under the old settings, this would still generate a public apply(bar, baz)
method. For Scala 2.13 and 3, under the new settings the apply
method will also be private, and you must explicitly add a public apply
method if desired. This is Scala 3 behavior. Most projects should catch this change either at compile-time or with MiMa.
- Remove
-source:3.0-migration
by @armanbilge in #531 - Add
-Xsource:3
to 2.12 (and future minor 2 releases) builds by @etspaceman in #493
Unused warnings for all Scala versions
Unused warnings are now enabled on Scala 2.12 and Scala 3.3+, in addition to Scala 2.13.
- Re-enable unused warnings for scala 2.12 by @satorg in #312
- Add re-introduced unused/discard warnings for scala >3.3.0 by @amumurst in #515
Scala version-specific @nowarn
s
To help manage fatal warnings when cross-building for multiple Scala versions, @satorg has created the scalac-compat library which provides @nowarn2
, @nowarn3
, etc. This is now included by default as compile-only dependency.
- Add
scalac-compat
dependency by default by @armanbilge in #518
Other enhancements
- Tune Scala compiler warnings by @satorg in #344
- Fix console/scalacOptions by @satorg in #349
tlFatalWarnings
now respectsCompile
/Test
scopes by @armanbilge in #531- Scaladoc3 Wiki Syntax Flag by @j-mie6 in #563
Target JDK 8 by default
We now set tlJdkRelease := Some(8)
so that the compiler explicitly targets JDK 8. If you are using APIs from newer JDKs your code will fail to compile. To target a newer JDK you may set e.g. tlJdkRelease := Some(11)
. To restore the old behavior, set tlJdkRelease := None
i.e. no explicit target.
- Set default
tlJdkRelease := Some(8)
by @armanbilge in #218 -release
->-java-output-version
in Scala 3.2 by @armanbilge in #543
Publish to s01.oss.sonatype.org
by default
The original oss.sonatype.org
is now designated "legacy" in favor of s01.oss.sonatype.org
. Typelevel and several other orgs are already publishing to s01
as well as all group IDs registered since 2021. You can migrate your org by opening a ticket on the Sonatype Jira. To restore the old behavior set tlSonatypeUseLegacyHost := true
.
- Make
s01.oss.sonatype.org
the default host by @armanbilge in #539
Laika 0.19
Huge thanks to @jenshalm for releasing Laika v0.19.0 and upgrading the sbt-typelevel-site plugin. This includes several enhancements and overall improves the integration.
- Site Plugin: Migrate to Laika 0.19.0-RC1 + separate generic defaults from Typelevel-specific ones by @jenshalm in #377
Projects not published under Typelevel will no longer automatically have Typelevel-themed websites. If you are a Typelevel-affiliated project you can opt-in to the theming by setting tlSiteIsTypelevelProject := Some(TypelevelProject.Affiliate)
.
- Distinguish between org, affiliate projects in site plugin by @armanbilge in #540
The tlSiteRelatedProjects
setting is now deprecated. You may either remove it or replicate the feature as done in the following PR.
- Address
tlSiteRelatedProjects
deprecation by @armanbilge in #549
New Typelevel site theme
@j-mie6 aka Dr Doc Warrior generously set aside his doctoral thesis writing to instead focus on making us a beautiful new theme for all Typelevel and affiliate sites. This has already been rolled out to the sbt-typelevel documentation and several others.
CI enhancements
JDKs and dependency caching
We now fully rely on the setup-java (and similar setup-graalvm) actions to manage JDKs and Maven dependency caching, instead of custom JDK index and caching steps.
- Setup java cache by @pjfanning in #300
- Use new setup-graalvm action by @armanbilge in #396
- Use vanilla setup-java action, update setup-graalvm action by @armanbilge in #538
- Support new Java Distributions by @mzuehlke in #564
Caching is now also more aggressive: if no cache is found, the CI job will create one by attempting to download all the dependencies used in the build. This cache is then shared by all CI jobs.
- Run
sbt update
on cache miss by @armanbilge in #423 - Cache hit outputs as a string by @armanbilge in #427
Dependency submission
Your project will now export its dependency graph to the GitHub API with the sbt-dependency-submission action. For example, this powers Dependabot vulnerability alerts. To opt-out, set tlCiDependencyGraphJob := false
.
- Add dependency submission job to CI by @armanbilge in #340
- Move submit-dependencies condition to job-level, not step-level by @armanbilge in #341
- Make dependency submission ignore non-compile scopes and no-publish projects by @armanbilge in #530
More aggressive cancelation of CI jobs
The build CI jobs now have a default 60-minute timeout that is configurable e.g. githubWorkflowBuildTimeoutMinutes := Some(30)
. CI is also now configured by default so that there is at most one concurrent job per PR or branch i.e. pushing another commit to a PR will cancel CI on the previous commit and merging another PR to main will cancel CI on the previous merge. Note that these concurrency limits will never affect the publishing of a tag.
- Allow configuring
timeout-minutes
for a job and a step by @iRevive in #416 - Allow configuring
concurrency
for a job by @iRevive in #417
Configurable job permissions
It is now possible to set granular permissions at both the workflow- and job-level. This is opt-in; otherwise CI defaults to the permissions granted in the repository settings.
- Add global permissions by @etspaceman in https://github.com...
v0.5.0-RC12
This is the twelfth release candidate of sbt-typelevel v0.5.0.
Fixes
- Disable the
byname-implicit
lint on 2.13 by @armanbilge in #624
Full Changelog: v0.5.0-RC11...v0.5.0-RC12
v0.5.0-RC11
This is the eleventh release candidate of sbt-typelevel v0.5.0.
Fixes
- Only add scala-compat dep for supported Scalas by @armanbilge in #622
- Allow preamble to be skipped in
Sbt
step by @armanbilge in #623
Full Changelog: v0.5.0-RC10...v0.5.0-RC11