WhatsApp: Merge pull request #963 from cycool29/master

Fix some WhatsApp issue
pull/966/head
Botspot 4 years ago committed by GitHub
commit 0a9bdc1baa
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -7,21 +7,21 @@ function error {
exit 1
}
cd $HOME
rm -f WhatsAppWeb-linux-armv7l.tar.xz
wget https://github.com/Itai-Nelken/Nativefier-WebApps/releases/download/v3.0/WhatsAppWeb-linux-armv7l.tar.xz || error 'Failed to download!'
tar -xf WhatsAppWeb-linux-armv7l.tar.xz || error "Failed to extract!"
rm WhatsAppWeb-linux-armv7l.tar.xz
mv "WhatsAppWeb-linux-armv7l" WhatsAppWeb
rm -rf ~/whatsapp.tar.xz ~/WhatsApp
mkdir ~/WhatsApp
wget -O ~/whatsapp.tar.xz https://github.com/cycool29/whatsapp-for-linux/releases/download/rpi-v1.0/WhatsApp-linux-armv7l.tar.xz || error 'Failed to download!'
tar -xf ~/whatsapp.tar.xz -C ~/WhatsApp || error "Failed to extract!"
rm ~/whatsapp.tar.xz
mv ~/WhatsApp/WhatsApp-linux-armv7l/* ~/WhatsApp && rm -rf ~/WhatsApp/WhatsApp-linux-armv7l
#create menu shortcut
echo "[Desktop Entry]
Name=Whatsapp Web
Comment=Nativefier Whatsapp Web webapp.
Exec=$HOME/WhatsAppWeb/WhatsAppWeb
Path=$HOME/WhatsAppWeb
Name=WhatsApp
Exec=bash -c "\""rm -rf $HOME/.config/whats*/Service* ; $HOME/WhatsApp/WhatsApp"\""
Path=$HOME/WhatsApp
Icon=$(dirname "$0")/icon-64.png
Terminal=false
StartupNotify=true
Type=Application
Categories=Network;" > ~/.local/share/applications/whatsappweb.desktop || error "Failed to create menu button!"
Categories=Network;" > ~/.local/share/applications/whatsapp.desktop || error "Failed to create menu button!"

@ -7,21 +7,21 @@ function error {
exit 1
}
cd $HOME
rm -f WhatsAppWeb-linux-arm64.tar.xz
wget https://github.com/Itai-Nelken/Nativefier-WebApps/releases/download/v3.0/WhatsAppWeb-linux-arm64.tar.xz || error 'Failed to download!'
tar -xf WhatsAppWeb-linux-arm64.tar.xz || error "Failed to extract!"
rm WhatsAppWeb-linux-arm64.tar.xz
mv "WhatsAppWeb-linux-arm64" WhatsAppWeb
rm -rf ~/whatsapp.tar.xz ~/WhatsApp
mkdir ~/WhatsApp
wget -O ~/whatsapp.tar.xz https://github.com/cycool29/whatsapp-for-linux/releases/download/rpi-arm64-1.0/WhatsApp-linux-arm64.tar.xz || error 'Failed to download!'
tar -xf ~/whatsapp.tar.xz -C ~/WhatsApp || error "Failed to extract!"
rm ~/whatsapp.tar.xz
mv ~/WhatsApp/WhatsApp-linux-armv7l/* ~/WhatsApp && rm -rf ~/WhatsApp/WhatsApp-linux-armv7l
#create menu shortcut
echo "[Desktop Entry]
Name=Whatsapp Web
Comment=Nativefier Whatsapp Web webapp.
Exec=$HOME/WhatsAppWeb/WhatsAppWeb
Path=$HOME/WhatsAppWeb
Name=WhatsApp
Exec=bash -c "\""rm -rf $HOME/.config/whats*/Service* ; $HOME/WhatsApp/WhatsApp"\""
Path=$HOME/WhatsApp
Icon=$(dirname "$0")/icon-64.png
Terminal=false
StartupNotify=true
Type=Application
Categories=Network;" > ~/.local/share/applications/whatsappweb.desktop || error "Failed to create menu button!"
Categories=Network;" > ~/.local/share/applications/whatsapp.desktop || error "Failed to create menu button!"

@ -8,8 +8,12 @@ function error {
}
#for backwards compatibility with the chromium version
rm -rf ~/WhatsappWeb &>/dev/null
rm -rf ~/WhatsappWeb
#for backwards compatibility with Itai's version
rm -rf ~/WhatsAppWeb
rm ~/.local/share/applications/whatsappweb.desktop
rm -f ~/.local/share/applications/whatsappweb.desktop
rm -rf ~/WhatsApp
rm -f ~/.local/share/applications/whatsapp.desktop
exit 0

Loading…
Cancel
Save