Simplify locales installation
This commit is contained in:
parent
c52c9df6db
commit
177e1e356d
@ -28,12 +28,9 @@ package() {
|
||||
install -D -m644 ${_pkgname}.desktop ${pkgdir}/etc/skel/.config/autostart/${_pkgname}.desktop
|
||||
install -D -m644 ${_pkgname}.desktop ${pkgdir}/usr/share/applications/${_pkgname}.desktop
|
||||
install -D -m755 "src/manjaro_hello.py" "${pkgdir}/usr/bin/${_pkgname}"
|
||||
cd "po"
|
||||
for lang in $(ls -1 | sed -e 's/\..*$//'); do
|
||||
if [ ${lang} != ${_pkgname} ]
|
||||
then
|
||||
install -d -m755 ${pkgdir}/usr/share/locale/${lang}/LC_MESSAGES
|
||||
msgfmt -c -o "${pkgdir}/usr/share/locale/${lang}/LC_MESSAGES/${_pkgname}.mo" ${lang}.po
|
||||
fi
|
||||
cd po
|
||||
for lang in $(ls *.po); do
|
||||
install -d -m755 ${pkgdir}/usr/share/locale/${lang::-3}/LC_MESSAGES
|
||||
msgfmt -c -o "${pkgdir}/usr/share/locale/${lang::-3}/LC_MESSAGES/${_pkgname}.mo" ${lang}
|
||||
done
|
||||
}
|
||||
|
@ -4,12 +4,9 @@
|
||||
rm -rf locale
|
||||
mkdir locale
|
||||
cd po
|
||||
for lang in $(ls -1 | sed -e 's/\..*$//'); do
|
||||
if [ $lang != "manjaro-hello" ]
|
||||
then
|
||||
mkdir -p ../locale/$lang/LC_MESSAGES
|
||||
msgfmt -c -o ../locale/$lang/LC_MESSAGES/manjaro-hello.mo $lang.po
|
||||
fi
|
||||
for lang in $(ls *.po); do
|
||||
mkdir -p ../locale/${lang::-3}/LC_MESSAGES
|
||||
msgfmt -c -o ../locale/${lang::-3}/LC_MESSAGES/manjaro-hello.mo $lang
|
||||
done
|
||||
cd ..
|
||||
python src/manjaro_hello.py
|
||||
|
Loading…
Reference in New Issue
Block a user