#!/bin/bash
if type aptitude &>/dev/null; then APT=aptitude
else APT=apt-get
fi
echo "using $APT"
line='foreign-architecture i386'
file=/etc/dpkg/dpkg.cfg.d/multiarch
grep "$line" "$file" &>/dev/null || { echo "$line" >> "$file"; $APT update; }
$APT install libxss1:i386 libqtcore4:i386 libqt4-dbus:i386 libqtgui4:i386 libpulse0:i386
FILE=skype-ubuntu_2.2.0.35-1_amd64.deb
[[ -f "./$FILE" ]] || {
URL="
http://download.skype.com/linux/$FILE"
if type wget &>/dev/null; then wget "$URL";
elif type curl &>/dev/null; then curl "$URL" > "$FILE";
else echo "Please, download the skype deb here: $URL";
fi
}
dpkg -i "./$FILE"