14 lines
548 B
Bash
14 lines
548 B
Bash
#!/bin/bash
|
|
set -e
|
|
|
|
# get the latest version or change to a specific version
|
|
VERSION=$(curl --silent "https://api.github.com/repos/argoproj-labs/argocd-autopilot/releases/latest" | grep '"tag_name"' | sed -E 's/.*"([^"]+)".*/\1/')
|
|
|
|
# download and extract the binary
|
|
curl -L --output - https://github.com/argoproj-labs/argocd-autopilot/releases/download/"$VERSION"/argocd-autopilot-linux-arm64.tar.gz | tar zx
|
|
|
|
# move the binary to your $PATH
|
|
mv ./argocd-autopilot-* /usr/local/bin/argocd-autopilot
|
|
|
|
# check the installation
|
|
argocd-autopilot version |