Atualização dos Menus do Wine
Publicado por Rafael em 08/10/2017
[ Hits: 2.585 ]
#!/bin/sh
wine="wine"
rm="/bin/rm"
iterate_start_menu ()
{
local menu_dir
local oldIFS
menu_dir=$1
# don't use space as field-separator otherwise "paths with spaces" will fail to parse correctly
oldIFS=$IFS
IFS=?
echo "menu_dir=${menu_dir}"
# add a trailing slash to the directory name, then the glob wildcard
for entry in ${menu_dir}/*; do
if [ -f "$entry" ]; then
echo "Link: $entry";
"$wine" winemenubuilder "$entry" 2>/dev/null
elif [ -d "$entry" ]; then
echo "Directory: $entry";
iterate_start_menu "$entry"
else
echo "Empty: $entry";
fi
done
IFS=$oldIFS
}
# Delete current user-defined wine menus
"$rm" -f $HOME/.config/menus/applications-merged/wine*
"$rm" -rf $HOME/.local/share/applications/wine
# Rebuild Start Menu for all prefixes starting with ".wine-" or ".wine" itself
for prefix in "$HOME/".wine-* "$HOME/".wine; do
WINEPREFIX="$prefix"
export WINEPREFIX
# do not use a trailing / at the end of the directory name
iterate_start_menu "${WINEPREFIX}/drive_c/windows/profiles/*/Start Menu"
done
##Finalizar a atualização
export WINEPREFIX="$prefix"; find $WINEPREFIX/drive_c/ -name "*.lnk" -exec wine winemenubuilder '{}' \;
Linux Omni-bot Autosetup 2011, programinha que facilita o uso do Omni-bot
Funções ZZ é uma coletânea com 111 miniaplicativos
LibreOffice - Acessando arquivos recentes pelo Unity Launcher
Gentoo binário em 2026: UEFI, LUKS, Btrfs e Systemd
Trabalhando Nativamente com Logs no Linux
Jogando Daikatana (Steam) com Patch 1.3 via Luxtorpeda no Linux
LazyDocker – Interface de Usuário em Tempo Real para o Docker
Servidor vs Computador Convencional
Como administrar uma rede Linux através da ferramenta Webmin
Como escanear portas de um servidor através da ferramenta Nmap e como alterar a porta do SSH.
Marcando e desmarcando pacotes para atualização, instalação e remoção no Debian e agregados
Is LMS Technology the Key to Solving Brazil’s Online Education Challen... (0)
Audio Failure on Acer Aspire AS4738 – Intel 5 Series HD Audio (Linux M... (0)









