-
Notifications
You must be signed in to change notification settings - Fork 51
Add tlLatestVersion, tlLatestPreReleaseVersion to versioning plugin
#333
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 6 commits
bce0230
defe6b3
9572683
210a174
f23c6d2
085bdd1
c58d30b
4852218
4e2eb8e
91d747d
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -25,6 +25,7 @@ import sbt._ | |
| import scala.util.Try | ||
|
|
||
| import Keys._ | ||
bplommer marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| import org.typelevel.sbt.TypelevelKernelPlugin.autoImport._ | ||
|
|
||
| object TypelevelVersioningPlugin extends AutoPlugin { | ||
|
|
||
|
|
@@ -37,6 +38,13 @@ object TypelevelVersioningPlugin extends AutoPlugin { | |
| lazy val tlUntaggedAreSnapshots = | ||
| settingKey[Boolean]( | ||
| "If true, an untagged commit is given a snapshot version, e.g. 0.4-00218f9-SNAPSHOT. If false, it is given a release version, e.g. 0.4-00218f9. (default: true)") | ||
|
|
||
| lazy val tlCurrentRelease = | ||
| settingKey[Option[String]]( | ||
| "The latest stable released version of your project, e.g. 0.2.0, 3.5.1. If applicable, this will be the version currently being released.") | ||
|
|
||
| lazy val tlCurrentPreRelease = settingKey[Option[String]]( | ||
| "The latest pre-release (e.g. milestone, release candidate) of your project. If applicable, this will be the version currently being released.") | ||
|
||
| } | ||
|
|
||
| import autoImport._ | ||
|
|
@@ -123,7 +131,9 @@ object TypelevelVersioningPlugin extends AutoPlugin { | |
| if (isSnapshot.value) version += "-SNAPSHOT" | ||
|
|
||
| version | ||
| } | ||
| }, | ||
| tlCurrentRelease := currentRelease.value, | ||
| tlCurrentPreRelease := currentPreRelease.value | ||
| ) | ||
|
|
||
| private val Description = """^.*-(\d+)-[a-zA-Z0-9]+$""".r | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.