Created
July 13, 2022 21:53
-
-
Save highercomve/ae94752d3d9560c1445968ed6bb3d8a4 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -e | |
echo "Loading latest revision from github" | |
version=`curl -L 'https://api.github.com/repos/MediaBrowser/Emby.Releases/releases' -H 'Accept: application/vnd.github.v3+json' -H 'Accept-Language: en-US,en;q=0.5' | jq '[.[] | select(.prerelease == false)][0].assets | (.[] | select(.name | contains("arm64.deb")))'` | |
downloadurl=`echo "$version" | jq -r .browser_download_url` | |
versionnumber=`echo "$version" | jq -r .name` | |
echo "You have emby installed with this version" | |
dpkg -l | grep emby | |
echo "Do you what to download $downloadurl [yes/y]" | |
read download | |
if [ "$download" != "yes" ] && [ "$download" != y ]; then | |
exit 0 | |
fi | |
echo "Downloading latest version from: $downloadurl" | |
curl -L "$downloadurl" -o /tmp/emby_install.deb | |
echo "Download completed" | |
echo "Installing $versionnumber" | |
sudo dpkg --install /tmp/emby_install.deb | |
rm /tmp/emby_install.deb |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment