pekko/project/AutomaticModuleName.scala
kerr bdc90052aa Update headers from 2018 to 2019 once for all. (#26165)
* Add CopyrightHeader support for sbt-boilerplate plugin.
* Add CopyrightHeader support for `*.proto` files.
* Add regex match for both `–` and `-` for CopyrightHeader.
* Add CopyrightHeader support for sbt build files.
* Update copyright from 2018 to 2019.
2019-01-02 11:55:26 +01:00

24 lines
748 B
Scala

/*
* Copyright (C) 2016-2019 Lightbend Inc. <https://www.lightbend.com>
*/
package akka
import sbt.{Def, _}
import sbt.Keys._
/**
* Helper to set Automatic-Module-Name in projects.
*
* !! DO NOT BE TEMPTED INTO AUTOMATICALLY DERIVING THE NAMES FROM PROJECT NAMES !!
*
* The names carry a lot of implications and DO NOT have to always align 1:1 with the group ids or package names,
* though there should be of course a strong relationship between them.
*/
object AutomaticModuleName {
private val AutomaticModuleName = "Automatic-Module-Name"
def settings(name: String): Seq[Def.Setting[Task[Seq[PackageOption]]]] = Seq(
packageOptions in (Compile, packageBin) += Package.ManifestAttributes(AutomaticModuleName name)
)
}