diff --git a/.github/workflows/test-cpan-libraries.yml b/.github/workflows/test-cpan-libraries.yml index 7d33f9b7f0..12c9d8144e 100644 --- a/.github/workflows/test-cpan-libraries.yml +++ b/.github/workflows/test-cpan-libraries.yml @@ -364,6 +364,8 @@ jobs: - name: "Statistics::Regression" build_distribs: "bullseye" version: "0.53" + - name: "WWW::Selenium" + deb_dependencies: "libcarp-always-perl libdata-dumper-compact-perl libexporter-tiny-perl libhttp-headers-fast-perl libhttp-request-ascgi-perl libio-socket-ssl-perl liblwp-useragent-determined-perl libtest-simple-perl libtest-more-utf8-perl liburi-escape-xs-perl libclass-base-perl" - name: "ZMQ::LibZMQ4" version: "0.01" deb_dependencies: "libzmq5" @@ -390,26 +392,25 @@ jobs: id: package-version run: | if [ -z "${{ matrix.version }}" ]; then - CPAN_PACKAGE_VERSION=$(cpanm --info ${{ matrix.name }} | sed 's/\.tar\.gz$//' | sed 's/.*\-//' | sed 's/v//') - + cpan_info=$(cpanm --info ${{ matrix.name }}) + CPAN_PACKAGE_VERSION=$cpan_info | sed 's/\.tar\.gz$//' | sed 's/.*\-//' | sed 's/v//') if [[ ! $CPAN_PACKAGE_VERSION =~ ^[0-9]+\.[0-9]+ ]]; then echo "::error::Invalid version number: ${CPAN_PACKAGE_VERSION}" exit 1 fi - PACKAGE_VERSION="${CPAN_PACKAGE_VERSION}" else PACKAGE_VERSION="${{ matrix.version }}" fi - echo "package_version=$(echo $PACKAGE_VERSION)" >> $GITHUB_OUTPUT + CPAN_PACKAGE_NAME=$cpan_info | sed 's/.*\///g' | sed 's/-[0-9\.]*\.tar\.gz//g' | tr '[:upper:]' '[:lower:]') + echo "package_name=$(echo $CPAN_PACKAGE_NAME)" >> $GITHUB_OUTPUT shell: bash - if: ${{ contains(matrix.build_distribs, matrix.distrib) }} name: Check if package already exists run: | - package_name=$(echo "lib${{ matrix.name }}-perl" | sed 's/::/-/g' | tr '[:upper:]' '[:lower:]') - package_info=$(apt-cache policy $package_name) + package_info=$(apt-cache policy ${{ steps.package-version.outputs.package_name }}) if [[ -n $package_info ]]; then echo "Package already exists in the repository." candidate_version=$(echo "$package_info" | grep 'Candidate:' | awk '{print $2}')