mabox-pipemenus/usr/bin/jgsoftware-pipe
2024-08-22 12:01:02 +02:00

89 lines
3.4 KiB
Bash
Executable File

#!/bin/bash
case $LANG in
pl*)
declare -a Internet=(chromium palemoon thunderbird filezilla deluge telegram-desktop rustdesk-bin)
declare -a Multimedia=(kodi vlc obs-studio audacious smplayer simplescreenrecorder)
declare -a Grafika=(gimp inkscape blender scribus)
declare -a Gry=(0ad warzone2100 wesnoth steam lutris )
declare -a Biuro=(abiword gnumeric)
declare -a Ebook=(calibre fbreader)
declare -a Backup=(timeshift)
declare -a Wirtualizacja=(virtualbox gnome-boxes)
declare -a categories=(Internet Multimedia Grafika Biuro Ebook Gry Backup Wirtualizacja)
INSTALL="Instaluj"
LAUNCH="Uruchom"
TITLE="Popularne programy"
INSTALL_PRINT="Instaluj manjaro printer"
CONFIGURE_PRINT="Konfiguracja drukarek"
REMOVE="Usuń to menu z panelu"
;;
es*)
declare -a Internet=(chromium palemoon thunderbird filezilla deluge telegram-desktop rustdesk-bin)
declare -a Multimedia=(kodi vlc obs-studio audacious smplayer simplescreenrecorder)
declare -a Graficos=(gimp inkscape blender scribus)
declare -a Juegos=(0ad warzone2100 wesnoth steam lutris)
declare -a Oficina=(abiword gnumeric)
declare -a LibrosE=(calibre fbreader)
declare -a Respaldo=(timeshift)
declare -a Virtualizacion=(virtualbox gnome-boxes)
declare -a categories=(Internet Multimedia Graficos Juegos Oficina LibrosE Respaldo Virtualizacion)
INSTALL="Instalar"
LAUNCH="Abrir"
TITLE="Programas populares"
INSTALL_PRINT="Instalar soporte de impresión"
CONFIGURE_PRINT="Configurar impresoras"
REMOVE="Eliminar este menú del panel"
;;
*)
declare -a Internet=(chromium palemoon thunderbird filezilla deluge telegram-desktop rustdesk-bin)
declare -a Multimedia=(kodi vlc obs-studio audacious smplayer simplescreenrecorder)
declare -a Graphics=(gimp inkscape blender scribus)
declare -a Games=(0ad warzone2100 wesnoth steam lutris)
declare -a Office=(abiword gnumeric)
declare -a Ebook=(calibre fbreader)
declare -a Backup=(timeshift)
declare -a Virtualization=(virtualbox gnome-boxes)
declare -a categories=(Internet Multimedia Graphics Office Ebook Games Backup Virtualization)
INSTALL="Install"
LAUNCH="Launch"
TITLE="Popular programs"
INSTALL_PRINT="Install Printing Support"
CONFIGURE_PRINT="Configure Printers"
REMOVE="Remove this menu from panel"
;;
esac
menus+=("^sep($TITLE)")
# Printing
if type 'system-config-printer' &> /dev/null; then
menus+=("$CONFIGURE_PRINT,gksu system-config-printer")
else
menus+=("$INSTALL_PRINT,pamac-installer manjaro-printer")
fi
menus+=("^sep()")
# All categories
for group in "${categories[@]}"; do
lst="$group[@]"
menus+=("${group},^checkout(${group})")
lines+=("^tag(${group})")
for element in "${!lst}"; do
if ! type "$element" &> /dev/null; then
lines+=("$INSTALL ${element^},pamac-installer $element")
else
lines+=("$LAUNCH ${element^},$element")
fi
done
done
menus+=("^sep()")
printf '%s\n' "${menus[@]}"
if [ $1 == "-r" ]; then
printf '%s\n' "<i>$REMOVE</i>,mb-setvar places_softwarepipe=false;mb-jgtools places"
fi
printf '%s\n' "${lines[@]}"
#echo "grafika,^checkout(grafika)"
#echo -e "^tag(grafika)\ngimp,czy\nblender\ninkscap"