Fix nightly push to go to snapshot repository.

This commit is contained in:
Josh Suereth 2014-08-04 11:08:29 -04:00
parent 4a83fcaeb1
commit 33deeea8b3
2 changed files with 10 additions and 2 deletions

View File

@ -34,7 +34,7 @@ object Release extends Build {
) ++ lameCredentialSettings ++ javaVersionCheckSettings
def snapshotPattern(version: String) = Resolver.localBasePattern.replaceAll("""\[revision\]""", version)
def publishResolver: Project.Initialize[Option[Resolver]] = (remoteID, remoteBase) { (id, base) =>
def publishResolver: Def.Initialize[Option[Resolver]] = (remoteID, remoteBase) { (id, base) =>
Some(Resolver.url("publish-" + id, url(base))(Resolver.ivyStylePatterns))
}

View File

@ -11,7 +11,15 @@ object Status {
commands += stampVersion
)
def stampVersion = Command.command("stamp-version") { state =>
Project.extract(state).append((version in ThisBuild ~= stamp) :: Nil, state)
val extracted = Project.extract(state)
val status = extracted.get(publishStatus)
// Set new version AND lock down the publishStatus to what it was, as
// our release regexes no longer support ivy data format, due to other issues.
extracted.append(
(version in ThisBuild ~= stamp) ::
(publishStatus in ThisBuild := status) ::
Nil,
state)
}
def stamp(v: String): String =
if (v endsWith Snapshot)