Localizador não interativo do Mozilla Thunderbird para Slackware
Publicado por Luís Fernando C. Cavalheiro (última atualização em 02/10/2015)
[ Hits: 3.607 ]
Homepage: https://github.com/lcavalheiro/
Download localiza_thunderbird.sh
Este script não interativo altera o SlackBuild mozilla-firefox-l10n de AlienBOB (disponível em http://taper.alienbase.nl/mirrors/people/alien/slackbuilds/mozilla-firefox-l10n/build/) para criar e instalar um pacote com a extensão .xpi necessária para localizar o Thunderbird atualmente instalado no computador para qualquer idioma (padrão: português do Brasil). Após a instalação ele removerá automaticamente as fontes baixadas para criar o pacote e o arquivo do pacote.
Após instalar o pacote vá no gerenciador de addons e ative o .xpi instalado em Languages.
#!/bin/bash
#
# ------------------------------- Legal notice -------------------------------
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
# Tradução não-oficial:
#
# Este programa é um software livre; você pode redistribuí-lo e/ou
# modificá-lo dentro dos termos da Licença Pública Geral GNU como
# publicada pela Fundação do Software Livre (FSF); na versão 3 da
# Licença, ou (na sua opinião) qualquer versão.
#
# Este programa é distribuído na esperança de que possa ser útil,
# mas SEM NENHUMA GARANTIA; sem uma garantia implícita de ADEQUAÇÃO
# a qualquer MERCADO ou APLICAÇÃO EM PARTICULAR. Veja a
# Licença Pública Geral GNU para maiores detalhes.
#
# Você deve ter recebido uma cópia da Licença Pública Geral GNU junto
# com este programa. Se não, veja <http://www.gnu.org/licenses/>.
#
# ------------------------------- Legal notice -------------------------------
#
# ----------------------------------------------------------------------------
#
###### Script: localiza_thunderbird.sh
###### Author: Luís Fernando C. Cavalheiro (pessoal at profcavalheiro dot com)
###### Version: 0.1 (20151002T16:53:54-0300)
#
# ----------------------------------------------------------------------------
#
# ----------------------------------------------------------------------------
#
# Only root user should be able to run this script
if [ "$(id -u)" != "0" ]; then
echo "This script must be run as root" 1>&2
exit 1
fi
#
# Set current dir as default:
CURRDIR=$(pwd)
#
# Automatically determine the architecture we're building on:
MARCH=$( uname -m )
if [ -z "$ARCH" ]; then
case "$MARCH" in
i?86) export ARCH=i686 ;;
x86_64) export ARCH=x86_64 ;;
# No support for other ARCHes...
*) echo "This architecture '$MARCH' is not supported."
exit 1
;;
esac
fi
#
# Grab which Thunderbird version is installed:
VERSION=$(thunderbird -v 2> /dev/null | grep Thunderbird | cut -d' ' -f3)
#
# Define to which language should Thunderbird be localized (default pt-BR):
PKGLANG=${PKGLANG:-pt-BR}
#
# Set package's build, type and tag:
BUILD=${BUILD:-1}
TAG=${TAG:-alien}
PKGTYPE=${PKGTYPE:-txz}
#
# Get the sources from AlienBOB's repo:
lftp -c 'open http://taper.alienbase.nl ; mirror mirrors/people/alien/slackbuilds/mozilla-firefox-l10n/build/ mozilla-thunderbird-l10n'
#
# Before packaging it we'll need some clever uses of sed...
cd $CURRDIR/mozilla-thunderbird-l10n
mv mozilla-firefox-l10n.SlackBuild mozilla-thunderbird-l10n.SlackBuild
sed -i -e 's/firefox/thunderbird/g' -e 's/Firefox/Thunderbird/g' -e 's/browser\/extensions/extensions/g' mozilla-thunderbird-l10n.SlackBuild
sed -i -e 's/firefox/thunderbird/g' -e 's/Firefox/Thunderbird/g' slack-desc
VERSION=$VERSION PKGLANG=$PKGLANG sh mozilla-thunderbird-l10n.SlackBuild
#
# Time to install package. First of all, check if we have slackpkg+
# installed, since we should use slackpkg to install/upgrade this
# package:
if [ -f /var/log/packages/slackpkg+-1.5.0-noarch-1mt ] ; then
# Good, we have slackpkg+ here. But are we installing or
# upgrading this package?
if [ -f /var/log/packages/mozilla-thunderbird-l10n* ] ; then
slackpkg upgrade file:/tmp/mozilla-thunderbird-l10n-${PKGLANG}-${VERSION}-${ARCH}-${BUILD}${TAG}.${PKGTYPE}
else
slackpkg install file:/tmp/mozilla-thunderbird-l10n-${PKGLANG}-${VERSION}-${ARCH}-${BUILD}${TAG}.${PKGTYPE}
fi
else
# That's ok, we don't have slackpkg+ installed. We ought to
# do it in the old fashioned way:
upgradepkg --install-new --reinstall /tmp/mozilla-thunderbird-l10n*t?z
fi
#
# Cleaning the mess
cd $CURRDIR
rm -rf $CURRDIR/mozilla-thunderbird-l10n /tmp/*
Automatizando a geração de relatórios do SARG
Gerador de Pacotes de Instalação
Browser - use rofi para acessar páginas na web
Nenhum comentário foi encontrado.
Como extrair chaves TOTP 2FA a partir de QRCODE (Google Authenticator)
Linux em 2025: Segurança prática para o usuário
Desktop Linux em alta: novos apps, distros e privacidade marcam o sábado
IA chega ao desktop e impulsiona produtividade no mundo Linux
Novos apps de produtividade, avanços em IA e distros em ebulição agitam o universo Linux
Como instalar o repositório do DBeaver no Ubuntu
Como instalar o Plex Media Server no Ubuntu
Digitando underscore com "shift" + "barra de espaços"
Como ativar a lixeira e recuperar aquivos deletados em um servidor Linux
Como mudar o nome de dispositivos Bluetooth via linha de comando
Programa fora de escala na tela do pc (18)
Fedora KDE plasma 42 X Módulo de segurança BB (Warsaw-2) (1)
O programa assinador digital (1)









