Created
June 30, 2016 18:47
-
-
Save RELATO/17796c22e88db2a53cf94de91bb75e38 to your computer and use it in GitHub Desktop.
Script para alterar o mapa de caracteres do Ubuntu UTF-8 para ISO-8859-1 (LATIN1)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#https://www.vivaolinux.com.br/script/Alterando-Ubuntu-de-UTF8-para-ISO88591-(LATIN1) | |
#!/bin/bash | |
# Script para alterar o mapa de caracteres do Ubuntu UTF-8 para ISO-8859-1 (LATIN1) | |
# @uthor Denilson Martins, [email protected] | |
# 03/03/2010 | |
# /etc/environment | |
echo -e "LANG=\"pt_BR"\" >> /etc/environment | |
echo -e "LANGUAGE=\"pt_BR"\" >> /etc/environment | |
# /etc/default/locale | |
sed 's/LANG="pt_BR.UTF-8"/LANG="pt_BR"/' /etc/default/locale >> /etc/default/locale | |
sed -i '1,2d' /etc/default/locale | |
# /etc/locale.alias | |
echo "pt_BR pt_BR.ISO-8859-1" >> /etc/locale.alias | |
# /var/lib/locales/supported.d/ | |
echo -e "pt_BR.ISO-8859-1 ISO-8859-1" >> /var/lib/locales/supported.d/local | |
sed -i '1d' /var/lib/locales/supported.d/local | |
echo -e "pt_PT.ISO-8859-1 ISO-8859-1" >> /var/lib/locales/supported.d/pt | |
echo -e "pt_BR.ISO-8859-1 ISO-8859-1" >> /var/lib/locales/supported.d/pt | |
sed -i '1,2d' /var/lib/locales/supported.d/pt | |
# Comandos | |
localedef pt_BR -i pt_BR -f ISO-8859-1 | |
localedef pt_BR.ISO-8859-1 -i pt_BR -f ISO-8859-1 | |
localedef pt_BR.ISO8859-1 -i pt_BR -f ISO-8859-1 | |
dpkg-reconfigure locales | |
locale-gen -purge | |
locale-gen |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
https://andykdocs.de/development/Ubuntu