Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [cu-dev] Gitlab issue for uploads

Hi,

On Mon, Apr 25, 2022 at 4:08 PM Nathan Rauh <nathan.rauh@xxxxxxxxxx> wrote:

One minor thing that I noticed in looking over the latest TCK build,

https://ci.eclipse.org/cu/view/all/job/Concurrency%20TCK%20Master%20Build/44/

is that 3.0.0-SNAPSHOT appears in a couple places within the concurrency-tck-3.0.0-dist.zip file, which has
concurrency-tck-reference-guide-3.0.0-SNAPSHOT.html

and

concurrency-tck-reference-guide-3.0.0-SNAPSHOT.pdf

although it might just be a result of that build not building with parameters to supply the 3.0.0 version.


I added the following to the TCK build in Security to make sure the versions don't contain snapshot. We could do the same or similar for security:

 
  # Compute release versions
  SNAPSHOT_VERSION=`mvn ${MVN_EXTRA} -B ${HELP_PLUGIN}:evaluate -Dexpression=project.version 2> /dev/null | grep -E '^[0-9]+(\.[0-9]+)+-SNAPSHOT$'`
 
  if [ -z "${RELEASE_VERSION}" ]; then
    if [ -z ${SNAPSHOT_VERSION} ]; then
      echo '-[ Missing required snapshot version number! ]----------------------------------'
    fi
    RELEASE_VERSION=`echo ${SNAPSHOT_VERSION} | sed -e 's/-SNAPSHOT//'`
  fi
 
  # Bash specific code
  if [ -z "${NEXT_VERSION}" ]; then
    NEXT_VERSION=`echo ${RELEASE_VERSION} | sed -e 's/\([0-9][0-9]*\.[0-9][0-9]*\).*/\1/'`
    set -f
    NEXT_COMPONENTS=(${RELEASE_VERSION//\./ })
    LAST_INDEX=$((${#NEXT_COMPONENTS[@]} - 1))
    NEXT_COMPONENTS[${LAST_INDEX}]=$((${NEXT_COMPONENTS[${LAST_INDEX}]} + 1))
    NEXT_VERSION=`echo ${NEXT_COMPONENTS[@]} | tr ' ' '.'`'-SNAPSHOT'
  fi


RELEASE_TAG="${RELEASE_VERSION}-RELEASE"

echo "Current version: ${SNAPSHOT_VERSION}"
echo "Release version: ${RELEASE_VERSION}"
echo "Next version:    ${NEXT_VERSION}"
echo "Release tag:     ${RELEASE_TAG}"

if [ -z "${SNAPSHOT_VERSION}" -o -z "${RELEASE_VERSION}" -o -z "${NEXT_VERSION}" ]; then
  echo '-[ Missing required version numbers! ]------------------------------------------'
  exit 1
fi

# Set release version if needed
if [ ${SNAPSHOT_VERSION} != ${RELEASE_VERSION} ]; then
  echo '-[ Set release version ]--------------------------------------------------------'
  cd ${BUILD_DIR}

  # Project identifiers
  ARTIFACT_ID=$(mvn ${MVN_EXTRA} -B ${HELP_PLUGIN}:evaluate -Dexpression=project.artifactId | grep -Ev '(^\[)')
  GROUP_ID=$(mvn ${MVN_EXTRA} -B ${HELP_PLUGIN}:evaluate -Dexpression=project.groupId | grep -Ev '(^\[)')

  # Set release version
  mvn ${MVN_EXTRA} -U -C \
      -DnewVersion="${RELEASE_VERSION}" \
      -DgenerateBackupPoms=false \
      clean ${VERSIONS_PLUGIN}:set
     
  cd old-tck/build
 
   # Set release version
  mvn ${MVN_EXTRA} -U -C \
      -DnewVersion="${RELEASE_VERSION}" \
      -DgenerateBackupPoms=false \
      clean ${VERSIONS_PLUGIN}:set
 
  cd ${WORKSPACE}
 
  echo '-[ Commit modified pom.xml files ]----------------------------------------------'
  POM_FILES=`git status | grep -E 'modified:.*pom\.xml' | sed -e 's/[[:space:]][[:space:]]*modified:[[:space:]][[:space:]]*//'`
  git add ${POM_FILES} && \
  git commit -m "Prepare release ${GROUP_ID}:${ARTIFACT_ID}:${RELEASE_VERSION}"
fi

 



 

Back to the top