Skip to content

Commit cc7ba86

Browse files
authored
Merge pull request scala#5979 from retronym/topic/disable-tag-driven
Disable tag driven publication of distribution
2 parents 7b45797 + a0e9bfd commit cc7ba86

File tree

1 file changed

+6
-28
lines changed

1 file changed

+6
-28
lines changed

scripts/jobs/integrate/bootstrap

Lines changed: 6 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,7 @@
1414

1515
# Specifying the Scala version:
1616
# - To build a release (this enables publishing to sonatype):
17-
# - Either specify SCALA_VER_BASE. You may also specify SCALA_VER_SUFFIX, the Scala version is SCALA_VER=$SCALA_VER_BASE$SCALA_VER_SUFFIX.
18-
# - Or have the current HEAD tagged as v$base$suffix
19-
# - To prevent staging on sonatype (for testing), set publishToSonatype to anything but "yes"
17+
# - Specify SCALA_VER_BASE. You may also specify SCALA_VER_SUFFIX, the Scala version is SCALA_VER=$SCALA_VER_BASE$SCALA_VER_SUFFIX.
2018
# - Note: After building a release, the jenkins job provides an updated versions.properties file as artifact.
2119
# Put this file in the Scala repo and create a pull request, also update `baseVersion in Global` in build.sbt.
2220
#
@@ -285,31 +283,11 @@ determineScalaVersion() {
285283
if [ -z "$SCALA_VER_BASE" ]; then
286284
echo "No SCALA_VER_BASE specified."
287285

288-
scalaTag=$(git describe --tag --exact-match ||:)
289-
290-
if [ -z "$scalaTag" ]
291-
then
292-
echo "No tag found, running an integration build."
293-
$SBT_CMD $sbtArgs 'set baseVersionSuffix in Global := "SHA"' generateBuildCharacterPropertiesFile
294-
parseScalaProperties "buildcharacter.properties"
295-
SCALA_VER_BASE="$maven_version_base"
296-
SCALA_VER_SUFFIX="$maven_version_suffix"
297-
298-
# TODO: publish nightly snapshot using this script - currently it's a separate jenkins job still running at EPFL.
299-
publishToSonatype="no"
300-
else
301-
echo "HEAD is tagged as $scalaTag."
302-
# borrowed from https://github.com/cloudflare/semver_bash/blob/master/semver.sh
303-
local RE='v*\([0-9]*\)[.]\([0-9]*\)[.]\([0-9]*\)\([0-9A-Za-z-]*\)' # don't change this to make it more accurate, it's not worth it
304-
SCALA_VER_BASE="$(echo $scalaTag | sed -e "s#$RE#\1.\2.\3#")"
305-
SCALA_VER_SUFFIX="$(echo $scalaTag | sed -e "s#$RE#\4#")"
306-
307-
if [ "$SCALA_VER_BASE" == "$scalaTag" ]; then
308-
echo "Could not parse version $scalaTag"
309-
exit 1
310-
fi
311-
publishToSonatype=${publishToSonatype-"yes"} # unless forced previously, publish
312-
fi
286+
$SBT_CMD $sbtArgs 'set baseVersionSuffix in Global := "SHA"' generateBuildCharacterPropertiesFile
287+
parseScalaProperties "buildcharacter.properties"
288+
SCALA_VER_BASE="$maven_version_base"
289+
SCALA_VER_SUFFIX="$maven_version_suffix"
290+
publishToSonatype="no"
313291
else
314292
publishToSonatype=${publishToSonatype-"yes"} # unless forced previously, publish
315293
fi

0 commit comments

Comments
 (0)