2020-02-21 11:07:19 -05:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
#
|
|
|
|
# Before running this script make sure that Flathub repo is added:
|
|
|
|
#
|
|
|
|
# flatpak remote-add --user --if-not-exists \
|
|
|
|
# flathub https://flathub.org/repo/flathub.flatpakrepo
|
|
|
|
|
|
|
|
set -euo pipefail
|
|
|
|
|
|
|
|
IFS=$'\n\t'
|
|
|
|
SCRIPT_DIR="$(dirname "$(readlink -f "${BASH_SOURCE[0]}")")"
|
|
|
|
GIT_ROOT="$SCRIPT_DIR/.."
|
|
|
|
|
2020-11-22 07:43:06 -05:00
|
|
|
XDG_DATA_DIRS="${XDG_DATA_DIRS:-/usr/local/share/:/usr/share/}"
|
|
|
|
|
2020-02-21 11:07:19 -05:00
|
|
|
IGNORED_APPS=(
|
|
|
|
# apps without icons:
|
2023-05-29 06:57:23 -04:00
|
|
|
cc.nift.nsm
|
2021-06-01 12:00:23 -04:00
|
|
|
com.github.nihui.waifu2x-ncnn-vulkan
|
2023-01-04 12:18:43 -05:00
|
|
|
com.riverbankcomputing.PyQt.BaseApp
|
2021-03-06 09:11:51 -05:00
|
|
|
dev.paullee.scraterpreter.Scrape
|
|
|
|
dev.paullee.scraterpreter.Scrapec
|
2020-02-21 11:07:19 -05:00
|
|
|
io.atom.electron.BaseApp
|
|
|
|
io.elementary.BaseApp
|
|
|
|
io.elementary.Loki.BaseApp
|
2021-03-06 09:11:51 -05:00
|
|
|
io.github.erkin.ponysay
|
2020-02-21 11:07:19 -05:00
|
|
|
io.gitlab.sdl_jstest.sdl2_jstest
|
|
|
|
io.gitlab.sdl_jstest.sdl_jstest
|
2021-03-06 09:11:51 -05:00
|
|
|
io.liri.BaseApp
|
2020-02-21 11:07:19 -05:00
|
|
|
io.qt.qtwebengine.BaseApp
|
|
|
|
io.qt.qtwebkit.BaseApp
|
2021-03-06 09:11:51 -05:00
|
|
|
net.sourceforge.fspclient
|
2023-01-04 12:18:43 -05:00
|
|
|
org.chromium.Chromium.BaseApp
|
2020-02-21 11:07:19 -05:00
|
|
|
org.electronjs.Electron2.BaseApp
|
|
|
|
org.flathub.flatpak-external-data-checker
|
|
|
|
org.flatpak.Builder
|
2021-03-06 09:11:51 -05:00
|
|
|
org.flatpak.flat-manager-client
|
2023-01-04 12:18:43 -05:00
|
|
|
org.freedesktop.appstream.cli
|
2020-02-21 11:07:19 -05:00
|
|
|
org.freedesktop.appstream-glib
|
|
|
|
org.freedesktop.GlxInfo
|
2020-05-13 05:19:24 -04:00
|
|
|
org.freedesktop.LinuxAudio.BaseExtension
|
2020-09-01 06:40:33 -04:00
|
|
|
org.freedesktop.Platform.ClInfo
|
|
|
|
org.freedesktop.Platform.GlxInfo
|
|
|
|
org.freedesktop.Platform.VaInfo
|
|
|
|
org.freedesktop.Platform.VulkanInfo
|
2021-03-11 02:14:46 -05:00
|
|
|
org.genivi.DLTViewer
|
2021-03-06 09:11:51 -05:00
|
|
|
org.godotengine.godot.BaseApp
|
2021-12-01 14:31:04 -05:00
|
|
|
org.gnome.NautilusPreviewer
|
2021-03-06 09:11:51 -05:00
|
|
|
org.mosh.mosh
|
2021-01-01 03:39:00 -05:00
|
|
|
org.mozilla.firefox.BaseApp
|
2021-03-06 09:11:51 -05:00
|
|
|
org.nuspell.Nuspell
|
|
|
|
org.sugarlabs.BaseApp
|
2021-07-01 14:54:51 -04:00
|
|
|
radio.k0swe.Kel_Agent
|
2021-02-26 09:07:26 -05:00
|
|
|
se.emijoh.mpw
|
2020-02-21 11:07:19 -05:00
|
|
|
# apps with icons that do not match with App ID:
|
2021-03-06 09:11:51 -05:00
|
|
|
cat.xtec.clic.JClic
|
2020-02-21 11:07:19 -05:00
|
|
|
com.github.utsushi.Utsushi
|
|
|
|
com.wps.Office
|
|
|
|
net.openra.OpenRA
|
2021-03-06 09:11:51 -05:00
|
|
|
org.freeorion.FreeOrion
|
2020-02-21 11:07:19 -05:00
|
|
|
org.homelinuxserver.vance.biblereader
|
2023-01-04 12:18:43 -05:00
|
|
|
org.kde.kcolorchooser
|
2021-03-06 09:11:51 -05:00
|
|
|
org.kde.okteta
|
2023-01-04 12:18:43 -05:00
|
|
|
org.kde.kdiff3
|
2020-02-21 11:07:19 -05:00
|
|
|
org.libreoffice.LibreOffice
|
|
|
|
org.vranki.spectral
|
|
|
|
)
|
|
|
|
|
|
|
|
flathub_apps_list="$(mktemp -u)"
|
|
|
|
papirus_icons_list="$(mktemp -u)"
|
|
|
|
|
|
|
|
_cleanup() {
|
|
|
|
rm -f "$flathub_apps_list" "$papirus_icons_list"
|
|
|
|
}
|
|
|
|
|
|
|
|
trap _cleanup EXIT HUP INT TERM
|
|
|
|
|
2020-11-22 06:49:53 -05:00
|
|
|
env XDG_DATA_DIRS="$HOME/.local/share/flatpak/exports/share:/var/lib/flatpak/exports/share:$XDG_DATA_DIRS" \
|
2020-02-21 11:07:19 -05:00
|
|
|
flatpak remote-ls --app --columns app flathub | sort -u > "$flathub_apps_list"
|
|
|
|
git -C "$GIT_ROOT" ls-tree master:Papirus/64x64/apps --name-only |
|
|
|
|
sed 's/\.svg$//' | sort > "$papirus_icons_list"
|
|
|
|
|
|
|
|
while read -r app_id; do
|
|
|
|
[[ "${IGNORED_APPS[*]//$app_id/}" == "${IGNORED_APPS[*]}" ]] || continue
|
|
|
|
if [ -n "${MARKDOWN:-}" ]; then
|
|
|
|
# shellcheck disable=SC2016
|
2023-09-07 06:01:36 -04:00
|
|
|
printf ' - [ ] `%s` <kbd>[GitHub](%s)</kbd> <kbd>[Flathub](%s)</kbd>\n' \
|
|
|
|
"$app_id" "https://github.com/flathub/$app_id" "https://flathub.org/apps/details/$app_id"
|
2020-02-21 11:07:19 -05:00
|
|
|
else
|
|
|
|
printf '%s\n' "$app_id"
|
|
|
|
fi
|
|
|
|
done < <(comm -23 "$flathub_apps_list" "$papirus_icons_list")
|