An sbt plugin that backports parts of sbt 1's public API on top of sbt 0.13 implementation
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.
project Upgrade the build to sbt 1.1.0 Jan 8, 2018
src/main Add more type aliases in sbt.librarymanagement Feb 10, 2018
.gitignore Add .gitignore Sep 29, 2017
.travis.yml Drop the -print when clearing the cache on Travis CI Jan 9, 2018
LICENSE Refetch the Apache 2.0 licence Jan 9, 2018
NOTICE Prep for 1.0.0 release Aug 22, 2017
build.sbt Enable all language features except reflective calls Jan 9, 2018

sbt-compat travis-badge

sbt-compat is an sbt plugin that backports parts of sbt 1's public API on top of sbt 0.13 implementation.

The idea of providing the latest (and greatest) API on top of older versions comes from Miles Sabin's macro-compat where the newer macro APIs are provided for older versions of Scala.


Add this plugin to your sbt plugin (in build.sbt, NOT project/plugins.sbt):

libraryDependencies += Defaults.sbtPluginExtra(
  "com.dwijnand" % "sbt-compat" % "1.0.0",
  (sbtBinaryVersion in pluginCrossBuild).value,
  (scalaBinaryVersion in update).value

Once sbt 0.13.17 is released with the fix to sbt/sbt#3393 this will simplify to:

addSbtPlugin("com.dwijnand" % "sbt-compat" % "1.0.0")


Use sbt 1's API, importing the relevant packages.

It might be necessary to wildcard import at times, and sometimes it might be necessary to import sbt.compat._.


Copyright 2017 Dale Wijnand

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.