You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
11 lines
412 B
11 lines
412 B
#!/bin/bash
|
|
|
|
INSTALL_DIR="/usr/local/bin"
|
|
|
|
json=$(curl -s https://api.github.com/repos/mozilla/geckodriver/releases/latest)
|
|
url=$(echo "$json" | jq -r '.assets[].browser_download_url | select(contains("linux64") and endswith("gz"))')
|
|
curl -s -L "$url" | tar -xz
|
|
chmod +x geckodriver
|
|
sudo mv geckodriver "$INSTALL_DIR"
|
|
export PATH=$PATH:$INSTALL_DIR/geckodriver
|
|
echo "installed geckodriver binary in $INSTALL_DIR" |