[ci] Use ruby 2.7 on travis

This commit is contained in:
Andreas Dangel
2020-10-26 20:15:30 +01:00
parent ff6e5278f3
commit fc39b28a9f
3 changed files with 9 additions and 0 deletions

View File

@ -32,6 +32,7 @@ function install_jdk() {
}
if travis_isLinux; then
change_ruby_version
gem install bundler
bundle config set --local path vendor/bundle
bundle config set --local with release_notes_preprocessing

View File

@ -57,3 +57,8 @@ function travis_isWindows() {
function get_pom_version() {
echo $(./mvnw -q -Dexec.executable="echo" -Dexec.args='${project.version}' --non-recursive org.codehaus.mojo:exec-maven-plugin:3.0.0:exec)
}
function change_ruby_version() {
source "$HOME/.rvm/scripts/rvm"
rvm use ruby-2.7
}

View File

@ -1,6 +1,7 @@
#
# The functions here require the following scripts:
# .travis/logger.sh
# .travis/common-functions.sh
#
# The functions here require the following environment variables:
# PMD_SF_USER
@ -12,6 +13,7 @@
# In that case, just a error logging is provided.
#
function regression-tester_uploadBaseline() {
change_ruby_version
log_debug "$FUNCNAME branch=${TRAVIS_BRANCH}"
local targetUrl="https://sourceforge.net/projects/pmd/files/pmd-regression-tester/"
@ -49,6 +51,7 @@ function regression-tester_uploadBaseline() {
# In that case, just a error logging is provided.
#
function regression-tester_executeDanger() {
change_ruby_version
log_debug "$FUNCNAME"
local errexitstate="$(shopt -po errexit)"