Merge pull request #178 from indrajitr/snapshot-key

Expose snapshot flag via standard `SettingKey`
This commit is contained in:
Mark Harrah 2011-09-09 06:34:53 -07:00
commit 3511b47f07
2 changed files with 2 additions and 0 deletions

View File

@ -632,6 +632,7 @@ object Classpaths
conflictWarning <<= (thisProjectRef, conflictWarning) { (ref, cw) => cw.copy(label = Project.display(ref)) },
unmanagedBase <<= baseDirectory / "lib",
normalizedName <<= name(StringUtilities.normalize),
isSnapshot <<= isSnapshot or version(_ endsWith "-SNAPSHOT"),
description <<= description or name.identity,
homepage in GlobalScope :== None,
startYear in GlobalScope :== None,

View File

@ -248,6 +248,7 @@ object Keys
val moduleName = SettingKey[String]("module-name", "The name of the current module, used for dependency management.")
val version = SettingKey[String]("version", "The version/revision of the current module.")
val isSnapshot = SettingKey[Boolean]("is-snapshot", "True if the the version of the project is a snapshot version.")
val moduleID = SettingKey[ModuleID]("module-id", "A dependency management descriptor. This is currently used for associating a ModuleID with a classpath entry.")
val projectID = SettingKey[ModuleID]("project-id", "The dependency management descriptor for the current module.")
val externalResolvers = TaskKey[Seq[Resolver]]("external-resolvers", "The external resolvers for automatically managed dependencies.")