From bbe7f06bf7543fe8345bb24dabca1db5d0562b00 Mon Sep 17 00:00:00 2001 From: theofficialgman <28281419+theofficialgman@users.noreply.github.com> Date: Sun, 15 May 2022 14:50:48 -0400 Subject: [PATCH] change over nativefier apps to webapps resolves https://github.com/Botspot/pi-apps/issues/2321 --- apps/Snapdrop/credits | 2 +- apps/Snapdrop/install | 16 ++++++++++++++++ apps/Snapdrop/install-32 | 5 ----- apps/Snapdrop/install-64 | 5 ----- apps/Snapdrop/uninstall | 3 ++- apps/StackEdit/credits | 4 +--- apps/StackEdit/description | 1 - apps/StackEdit/install | 16 ++++++++++++++++ apps/StackEdit/install-32 | 19 ------------------- apps/StackEdit/install-64 | 19 ------------------- apps/StackEdit/uninstall | 8 +++----- apps/WhatsApp/credits | 4 +--- apps/WhatsApp/description | 6 ++---- apps/WhatsApp/install | 17 +++++++++++++++++ apps/WhatsApp/install-32 | 5 ----- apps/WhatsApp/install-64 | 5 ----- apps/WhatsApp/uninstall | 1 + etc/categories | 2 +- 18 files changed, 61 insertions(+), 77 deletions(-) create mode 100755 apps/Snapdrop/install delete mode 100755 apps/Snapdrop/install-32 delete mode 100755 apps/Snapdrop/install-64 create mode 100755 apps/StackEdit/install delete mode 100755 apps/StackEdit/install-32 delete mode 100755 apps/StackEdit/install-64 create mode 100755 apps/WhatsApp/install delete mode 100755 apps/WhatsApp/install-32 delete mode 100755 apps/WhatsApp/install-64 diff --git a/apps/Snapdrop/credits b/apps/Snapdrop/credits index 556a64fcbc2..3460872914e 100644 --- a/apps/Snapdrop/credits +++ b/apps/Snapdrop/credits @@ -1 +1 @@ -@ryanfortner (GitHub) +theofficialgman diff --git a/apps/Snapdrop/install b/apps/Snapdrop/install new file mode 100755 index 00000000000..034eff8faff --- /dev/null +++ b/apps/Snapdrop/install @@ -0,0 +1,16 @@ +#!/bin/bash + +"${DIRECTORY}/manage" install-if-not-installed 'Chromium' || error "Chromium is required but it failed to install!" + +sudo mkdir -p /usr/local/share/applications +echo "Creating menu button..." +echo "[Desktop Entry] +Name=Snapdrop +GenericName=Local File Sharing +Comment=Local file sharing in your browser. Inspired by Apple's Airdrop. +Exec=chromium-browser %U --user-data-dir=$HOME/.config/webapps/snapdrop --app=https://snapdrop.net/ +Icon=$(dirname "$0")/icon-64.png +Terminal=false +StartupNotify=true +Type=Application +Categories=Utility" | sudo tee /usr/local/share/applications/Snapdrop.desktop || error "Failed to create menu shortcut!" diff --git a/apps/Snapdrop/install-32 b/apps/Snapdrop/install-32 deleted file mode 100755 index 48e4300d6e7..00000000000 --- a/apps/Snapdrop/install-32 +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/bash - -filepath="https://github.com/ryanfortner/snapdrop-rpi/raw/master/snapdrop_20221216_armhf.deb" - -install_packages "${filepath}" || exit 1 diff --git a/apps/Snapdrop/install-64 b/apps/Snapdrop/install-64 deleted file mode 100755 index c9ae9f9ef7a..00000000000 --- a/apps/Snapdrop/install-64 +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/bash - -filepath="https://github.com/ryanfortner/snapdrop-rpi/raw/master/snapdrop_20221216_arm64.deb" - -install_packages "${filepath}" || exit 1 diff --git a/apps/Snapdrop/uninstall b/apps/Snapdrop/uninstall index b81bf44c52f..9689156625b 100755 --- a/apps/Snapdrop/uninstall +++ b/apps/Snapdrop/uninstall @@ -1,3 +1,4 @@ #!/bin/bash -purge_packages || exit 1 \ No newline at end of file +sudo rm -f /usr/local/share/applications/Snapdrop.desktop +purge_packages || exit 1 diff --git a/apps/StackEdit/credits b/apps/StackEdit/credits index 85b80019641..3460872914e 100644 --- a/apps/StackEdit/credits +++ b/apps/StackEdit/credits @@ -1,3 +1 @@ -Added to pi-apps by Itai-Nelken. -webapps compiled by Itai-Nelken using nativefier. -nativefier by jiahaog. +theofficialgman diff --git a/apps/StackEdit/description b/apps/StackEdit/description index c88d6fe48c6..7715e31a386 100644 --- a/apps/StackEdit/description +++ b/apps/StackEdit/description @@ -2,4 +2,3 @@ Full-featured, open-source Markdown editor. StackEdit uses the same markdown library as Stack Overflow and is fully compatible with Github README.md files as well. This is Botspot's preferred tool to write the README for all his repositories. To run: Menu -> Programming -> StackEdit -To run in a terminal: ~/stackedit/StackEdit diff --git a/apps/StackEdit/install b/apps/StackEdit/install new file mode 100755 index 00000000000..96768c506c0 --- /dev/null +++ b/apps/StackEdit/install @@ -0,0 +1,16 @@ +#!/bin/bash + +"${DIRECTORY}/manage" install-if-not-installed 'Chromium' || error "Chromium is required but it failed to install!" + +sudo mkdir -p /usr/local/share/applications +echo "Creating menu shortcut..." +echo "[Desktop Entry] +Name=StackEdit +GenericName=Markdown editor +Comment=A chromium webapp for the stackedit markdown editor +Exec=chromium-browser %U --user-data-dir=$HOME/.config/webapps/stackedit --app=https://stackedit.io/app# +Icon=$(dirname "$0")/icon-64.png +Terminal=false +StartupNotify=true +Type=Application +Categories=Development;IDE;" | sudo tee /usr/local/share/applications/stackedit.desktop || error "Failed to create menu shortcut!" diff --git a/apps/StackEdit/install-32 b/apps/StackEdit/install-32 deleted file mode 100755 index f6fb5432969..00000000000 --- a/apps/StackEdit/install-32 +++ /dev/null @@ -1,19 +0,0 @@ -#!/bin/bash -cd $HOME -echo "Downloading..." -wget https://github.com/Itai-Nelken/Nativefier-WebApps/releases/download/v3.0/StackEdit-linux-armv7l.tar.xz || error 'Failed to Download!' -echo "extracting..." -tar -xf StackEdit-linux-armv7l.tar.xz || error "Failed to extract!" -echo "Renaming folder..." -mv ~/StackEdit-linux-armv7l ~/stackedit || error "Failed to rename folder!" -echo "Creating menu shortcut..." -echo "[Desktop Entry] -StartupNotify=true -Terminal=false -Type=Application -Name=StackEdit -Exec="$HOME/stackedit/StackEdit" -Path="$HOME/stackedit" -Icon="$HOME/pi-apps/apps/StackEdit/icon-64.png" -Categories=Development;IDE;" > ~/.local/share/applications/stackedit.desktop || error "Failed to create menu shortcut!" -rm -f StackEdit-linux-armv7l.tar.xz diff --git a/apps/StackEdit/install-64 b/apps/StackEdit/install-64 deleted file mode 100755 index 4fb57ae6b3d..00000000000 --- a/apps/StackEdit/install-64 +++ /dev/null @@ -1,19 +0,0 @@ -#!/bin/bash -cd $HOME -echo "Downloading..." -wget https://github.com/Itai-Nelken/Nativefier-WebApps/releases/download/v3.0/StackEdit-linux-arm64.tar.xz || error 'Failed to Download!' -echo "extracting..." -tar -xf StackEdit-linux-arm64.tar.xz || error "Failed to extract!" -echo "Renaming folder..." -mv ~/StackEdit-linux-arm64 ~/stackedit || error "Failed to rename folder!" -echo "Creating menu shortcut..." -echo "[Desktop Entry] -StartupNotify=true -Terminal=false -Type=Application -Name=StackEdit -Exec="$HOME/stackedit/StackEdit" -Path="$HOME/stackedit" -Icon="$HOME/pi-apps/apps/StackEdit/icon-64.png" -Categories=Development;IDE;" > ~/.local/share/applications/stackedit.desktop || error "Failed to create menu shortcut!" -rm -f StackEdit-linux-arm64.tar.xz diff --git a/apps/StackEdit/uninstall b/apps/StackEdit/uninstall index 04bb4908612..e89d59dfc7f 100755 --- a/apps/StackEdit/uninstall +++ b/apps/StackEdit/uninstall @@ -1,6 +1,4 @@ #!/bin/bash -echo "removing ~/stackedit..." -rm -rf ~/stackedit || error "Failed to remove ~/stackedit!" -echo "removing menu shortcut..." -rm -f ~/.local/share/applications/stackedit.desktop || error "Failed to remove menu shortcut!" -echo "DONE!" + +sudo rm -f /usr/local/share/applications/stackedit.desktop +purge_packages || exit 1 diff --git a/apps/WhatsApp/credits b/apps/WhatsApp/credits index 8907be3f021..3460872914e 100644 --- a/apps/WhatsApp/credits +++ b/apps/WhatsApp/credits @@ -1,3 +1 @@ -Apps compiled using Nativefier and DEB packages hosted by cycool29 -Nativefier made by jiahaog. -Thanks to Botspot for help with debugging the menu shortcut and for creating pi-apps! +theofficialgman diff --git a/apps/WhatsApp/description b/apps/WhatsApp/description index 63a60e69a5b..871605ea2c9 100644 --- a/apps/WhatsApp/description +++ b/apps/WhatsApp/description @@ -1,7 +1,5 @@ -Nativefier Whatsapp Web webapp +Whatsapp Web webapp -A simple Whatsapp Web chromium webapp wrapped in electron with nativefier. -it has a tray icon, so it doesn't take space on the taskbar, but keeps running in the background. +A simple Whatsapp Web chromium webapp. To run: Menu -> Internet -> Whatsapp Web -To run in a terminal: /opt/WhatsApp/WhatsApp diff --git a/apps/WhatsApp/install b/apps/WhatsApp/install new file mode 100755 index 00000000000..46ebfb89af0 --- /dev/null +++ b/apps/WhatsApp/install @@ -0,0 +1,17 @@ +#!/bin/bash + +"${DIRECTORY}/manage" install-if-not-installed 'Chromium' || error "Chromium is required but it failed to install!" + +sudo mkdir -p /usr/local/share/applications +echo "Creating menu button..." +echo "[Desktop Entry] +Name=WhatsApp +GenericName=Online Messaging +Comment=A chromium webapp for the WhatsApp messaging service +Exec=chromium-browser %U --user-data-dir=$HOME/.config/webapps/WhatsApp --app=https://web.whatsapp.com +Icon=$(dirname "$0")/icon-64.png +Type=Application +StartupNotify=false +StartupWMClass=WhatsApp +Categories=Internet;Chat;Network +Keywords=whatsapp;" | sudo tee /usr/local/share/applications/WhatsApp.desktop || error "Failed to create menu shortcut!" diff --git a/apps/WhatsApp/install-32 b/apps/WhatsApp/install-32 deleted file mode 100755 index 7ebb6cfb6d1..00000000000 --- a/apps/WhatsApp/install-32 +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/bash - -version=24.0 - -install_packages https://github.com/cycool29/whatsapp-for-linux/releases/download/${version}/whatsapp_${version}_armhf.deb || exit 1 diff --git a/apps/WhatsApp/install-64 b/apps/WhatsApp/install-64 deleted file mode 100755 index 534802821f8..00000000000 --- a/apps/WhatsApp/install-64 +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/bash - -version=24.0 - -install_packages https://github.com/cycool29/whatsapp-for-linux/releases/download/${version}/whatsapp_${version}_arm64.deb || exit 1 diff --git a/apps/WhatsApp/uninstall b/apps/WhatsApp/uninstall index 238a43e0bef..07350a9bb52 100755 --- a/apps/WhatsApp/uninstall +++ b/apps/WhatsApp/uninstall @@ -1,3 +1,4 @@ #!/bin/bash +rm -f /usr/local/share/applications/WhatsApp.desktop purge_packages || exit 1 diff --git a/etc/categories b/etc/categories index e000e607af4..210582dab8a 100644 --- a/etc/categories +++ b/etc/categories @@ -170,7 +170,7 @@ Snap Store|Tools Sonic Pi|Multimedia SpeedTest-CLI|Internet Sphero SDK|Programming -StackEdit|hidden +StackEdit|Programming Steam|Games Steam Link|Games StepMania|Games