1- import de .heikoseeberger .sbtheader .HeaderPattern
21import de .heikoseeberger .sbtheader .HeaderPlugin .autoImport ._
2+ import de .heikoseeberger .sbtheader .License ._
33import sbt .Keys ._
44import sbt ._
55import sbtorgpolicies ._
@@ -12,6 +12,19 @@ object ProjectPlugin extends AutoPlugin {
1212
1313 override def requires : Plugins = plugins.JvmPlugin && OrgPoliciesPlugin
1414
15+ object autoImport {
16+
17+ lazy val V = new {
18+ val scala212 : String = " 2.12.10"
19+ val shapeless : String = " 2.3.3"
20+ val scalatest : String = " 3.0.8"
21+ val scalacheck : String = " 1.14.2"
22+ val scalacheckShapeless : String = " 1.2.3"
23+ }
24+ }
25+
26+ import autoImport ._
27+
1528 override def projectSettings : Seq [Def .Setting [_]] =
1629 Seq (
1730 description := " Scala Exercises: The path to enlightenment" ,
@@ -25,23 +38,17 @@ object ProjectPlugin extends AutoPlugin {
2538 organizationEmail = " hello@47deg.com"
2639 ),
2740 orgLicenseSetting := ApacheLicense ,
28- scalaVersion := " 2.11.11 " ,
41+ scalaVersion := V .scala212 ,
2942 scalaOrganization := " org.scala-lang" ,
30- crossScalaVersions := Seq (" 2.11.11" ),
3143 resolvers ++= Seq (
3244 Resolver .mavenLocal,
3345 Resolver .sonatypeRepo(" snapshots" ),
3446 Resolver .sonatypeRepo(" releases" )
3547 ),
3648 scalacOptions := sbtorgpolicies.model.scalacCommonOptions,
37- headers := Map (
38- " scala" -> (HeaderPattern .cStyleBlockComment,
39- s """ |/*
40- | * scala-exercises - ${name.value}
41- | * Copyright (C) 2015-2016 47 Degrees, LLC. <http://www.47deg.com>
42- | */
43- |
44- | """ .stripMargin)
45- )
49+ headerLicense := Some (Custom (s """ | scala-exercises - ${name.value}
50+ | Copyright (C) 2015-2019 47 Degrees, LLC. <http://www.47deg.com>
51+ |
52+ | """ .stripMargin))
4653 )
4754}
0 commit comments