Last active
May 27, 2020 14:02
-
-
Save hashy0917/2e7c7c72c61955f4d12612367515216d to your computer and use it in GitHub Desktop.
zd
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/sh | |
set -eu | |
main(){ | |
echo "installcheck start" | |
echo "bit_check>" | |
if [ "x86_64" = $(uname -m) ]; then | |
echo "bit_check>OK" | |
echo "distribution_check>" | |
if [ -e /etc/debian_version ] ||[ -e /etc/debian_release ]; then | |
echo "distribution_check>Ubuntu or Debian" | |
if [ -e /etc/lsb-release ]; then | |
distri_name="ubuntu" | |
else | |
distri_name="debian" | |
fi | |
elif [ -e /etc/arch-release ]; then | |
distri_name="arch" | |
fi | |
echo "distribution_check>"+$distri_name | |
echo "install_start" | |
mkdir /tmp/autoinstallscript | |
DIR=/tmp/autoinstallscript | |
case $distri_name in | |
"ubuntu") | |
echo "zoom install" | |
apt update; | |
wget -P $DIR https://zoom.us/client/latest/zoom_amd64.deb | |
dpkg -i $DIR/zoom_amd64.deb | |
echo "discord install" | |
wget -P $DIR https://dl.discordapp.net/apps/linux/0.0.10/discord-0.0.10.deb | |
dpkg -i $DIR/discord-0.0.10.deb | |
apt -f install | |
break | |
;; | |
"debian") | |
echo "zoom install" | |
apt update; | |
wget -P $DIR https://zoom.us/client/latest/zoom_amd64.deb | |
dpkg -i $DIR/zoom_amd64.deb | |
echo "discord install" | |
wget -P $DIR https://dl.discordapp.net/apps/linux/0.0.10/discord-0.0.10.deb | |
dpkg -i $DIR/discord-0.0.10.deb | |
apt -f install | |
break | |
;; | |
"arch") | |
echo "zoom install" | |
wget -P $DIR https://zoom.us/client/latest/zoom_x86_64.pkg.tar.x | |
pacman -U $DIR/zoom_x86_64.tar.xz | |
echo "discord install" | |
wget -P $DIR https://dl.discordapp.net/apps/linux/0.0.10/discord-0.0.10.tar.gz | |
pacman -U $DIR/discord-0.0.10.tar.gz | |
break | |
;; | |
*) | |
echo "error" | |
exit 1 | |
esac | |
else | |
echo "thix pc is no 64bit" | |
exit 1 | |
fi | |
} | |
main |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment