-
Notifications
You must be signed in to change notification settings - Fork 50
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 5 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.") | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks, these are great descriptions! Bikeshed time, is "current release" and "current pre-release" the best terminology for these? Maybe "latest" is more appropriate? And "version" instead of "release"? I guest that gets us to something like There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I have absolutely no opinion on this but happy to change it if you like 😃 There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Not even a smidgeon of an opinion? 😂 I hate deciding these things. I can commit whatever I decide before I merge. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Maybe I have a slight preference for There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. On the other hand,
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can I leave this with you to commit the final wording and naming? Happy to discuss ideas of course There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yup, I can do that. Thanks for all your help, nice to bounce ideas! Much appreciated. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Ah yeah sounds good, I only just saw this now. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Actually I don't think that's correct? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. You are right, it's still not 100% correct.
It is, albeit indirectly.
You are right about this. It uses the binary series and not the |
||
} | ||
|
||
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.