Skip to content

Commit

Permalink
address denoland#256
Browse files Browse the repository at this point in the history
  • Loading branch information
jeff-hykin committed Apr 30, 2023
1 parent 85a078d commit 04b0509
Showing 1 changed file with 4 additions and 9 deletions.
13 changes: 4 additions & 9 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -41,15 +41,10 @@ if [ ! -d "$bin_dir" ]; then
mkdir -p "$bin_dir"
fi

if has curl; then
curl --fail --location --progress-bar --output "$exe.zip" "$deno_uri"
elif has wget; then # basic ubuntu only has wget
wget --output-document="$exe.zip" "$deno_uri"
else
echo "When installing deno, I looked for the 'curl' and for 'wget' commands but I didn't see either of them."
echo "Please install one of them"
echo "Otherwise I have no way to install Deno"
fi
curl --fail --location --progress-bar --output "$exe.zip" "$deno_uri" || \
wget --output-document="$exe.zip" "$deno_uri" || \
echo "When installing deno, I looked for the 'curl' and for 'wget' commands but I didn't see either of them. Please install one of them, otherwise I have no way to install Deno"

unzip -d "$bin_dir" -o "$exe.zip"
chmod +x "$exe"
rm "$exe.zip"
Expand Down

0 comments on commit 04b0509

Please sign in to comment.