Last active
April 13, 2019 07:45
-
-
Save IslamAlam/4b60e337c5cd5c42b8baa4e01b222687 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
https://www.realvnc.com/download/file/viewer.files/VNC-Viewer-6.19.325-Linux-x64.deb | |
#!/bin/sh | |
# Go to home directory | |
cd ~ | |
# https://stackoverflow.com/questions/22510705/get-the-latest-download-link-programmatically | |
# Determine latest version: | |
latestVer=$(curl 'https://www.realvnc.com/download/file/viewer.files/' | | |
grep -oP 'href="VNC-Viewer-\K[0-9]+\.[0-9]+\.[0-9]+' | | |
sort -t. -rn -k1,1 -k2,2 | head -1) | |
# Echo latest version: | |
echo "VNC-Viewer-${latestVer}-Linux-x64.deb" t | |
# Download latest versanaconda-navigatorion: | |
curl "https://www.realvnc.com/download/file/viewer.files/VNC-Viewer-${latestVer}-Linux-x64.deb" > "VNC-Viewer-${latestVer}-Linux-x64.deb" | |
sudo apt install "VNC-Viewer-${latestVer}-Linux-x64.deb" -y | |
rm "VNC-Viewer-${latestVer}-Linux-x64.deb" | |
echo "Installation is complete :)" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment