mirror of
https://github.com/LIV2/A4092-dev.git
synced 2025-12-06 00:32:49 +00:00
21 lines
505 B
Bash
Executable File
21 lines
505 B
Bash
Executable File
#!/bin/bash -eu
|
|
|
|
case $(arch) in
|
|
aarch64):
|
|
ARCH=arm64
|
|
;;
|
|
x86_64):
|
|
ARCH=x86_64
|
|
;;
|
|
*)
|
|
echo "Unknown architecture"
|
|
exit 1
|
|
;;
|
|
esac
|
|
|
|
URL=$(curl -Ls https://api.github.com/repos/chipsalliance/verible/releases/latest | jq --raw-output ".assets[] | select(.name|test(\"${ARCH}\")).browser_download_url")
|
|
|
|
curl -Lsf ${URL} -o /tmp/verible.tar.gz
|
|
tar xf /tmp/verible.tar.gz -C /tmp
|
|
sudo mv /tmp/verible-*/bin/* /usr/local/bin
|
|
rm -rf /tmp/verible* |