Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: chromedriver versions not installing #96

Merged
merged 1 commit into from
Sep 13, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/scripts/install-chromedriver.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ else
fi

CHROME_VERSION_STRING="$(echo "$CHROME_VERSION" | sed 's/.*Google Chrome //' | sed 's/.*Chromium //')"
# shellcheck disable=SC2001
# shellcheck disable=SC2001
CHROME_VERSION_MAJOR="$(echo "$CHROME_VERSION_STRING" | sed "s/\..*//" )"
echo "Chrome version major is $CHROME_VERSION_MAJOR"

Expand Down Expand Up @@ -157,7 +157,7 @@ else
echo $MATCHING_CHROMEDRIVER_URL_RESPONSE
if [[ $MATCHING_CHROMEDRIVER_URL_RESPONSE == 404 ]]; then
echo "Matching Chrome Driver Version 404'd, falling back to first matching major version."
CHROMEDRIVER_VERSION=$( curl https://googlechromelabs.github.io/chrome-for-testing/latest-versions-per-milestone.json | grep -o "$CHROME_VERSION_MAJOR.*" | grep -o "version.*" | grep -o '\:*'"$CHROME_VERSION_MAJOR"'.*,' | sed 's/".*//')
CHROMEDRIVER_VERSION=$( curl https://googlechromelabs.github.io/chrome-for-testing/latest-versions-per-milestone.json | jq ".milestones.\"$CHROME_VERSION_MAJOR\".version" | sed 's/\"//g')
echo "New ChromeDriver version to be installed: $CHROMEDRIVER_VERSION"
fi
echo "$CHROMEDRIVER_VERSION will be installed"
Expand Down