Skip to content

Commit

Permalink
Fix download link
Browse files Browse the repository at this point in the history
  • Loading branch information
mau-mauricelim committed Aug 11, 2024
1 parent ff0007d commit 0f0ac23
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ run_install() { echo "Running $1 installer"; "${1}_install"; }
set_url_and_version() {
repo_name=$(echo "$1" | cut -d"/" -f2)
repo_name=${repo_name^^} # Uppercase
# Sets release url e.g. RIPGREP_URL=https://github.com/BurntSushi/ripgrep/releases/lastest
eval "${repo_name}_URL"="https://github.com/$1/releases/lastest"
# Sets release url e.g. RIPGREP_URL=https://github.com/BurntSushi/ripgrep/releases/lastest/download
eval "${repo_name}_URL"="https://github.com/$1/releases/lastest/download"
latest_tag=$(curl -sL "https://api.github.com/repos/$1/releases/latest" | grep tag_name | cut -d '"' -f4)
# Strip v (first charcter) from tag
if [ "$2" = "true" ]; then latest_tag="${latest_tag:1}"; fi
Expand Down

0 comments on commit 0f0ac23

Please sign in to comment.