mirror of
https://github.com/oSoWoSo/DistroHopper.git
synced 2024-08-14 22:46:53 +00:00
make copying translation optional
This commit is contained in:
parent
94f6908076
commit
76f3e44cc4
1 changed files with 7 additions and 2 deletions
5
dh
5
dh
|
@ -427,9 +427,14 @@ function translate() {
|
||||||
meld "$DH_CONFIG_DIR"/locale/dh-source.pot "$DH_CONFIG_DIR"/locale/distrohopper-"$lang".pot
|
meld "$DH_CONFIG_DIR"/locale/dh-source.pot "$DH_CONFIG_DIR"/locale/distrohopper-"$lang".pot
|
||||||
echo $"Generating .mo file..."
|
echo $"Generating .mo file..."
|
||||||
msgfmt -o "$DH_CONFIG_DIR"/locale/distrohopper-"$lang".mo "$DH_CONFIG_DIR"/locale/distrohopper-"$lang".pot
|
msgfmt -o "$DH_CONFIG_DIR"/locale/distrohopper-"$lang".mo "$DH_CONFIG_DIR"/locale/distrohopper-"$lang".pot
|
||||||
|
echo $"Do you want copy $lang translation to '/usr/share/local' as ROOT? (y/n)"
|
||||||
|
read response
|
||||||
|
if [[ "$response" =~ ^[Yy]$ ]]; then
|
||||||
echo $"Copying translation to '/usr/share/local'..."
|
echo $"Copying translation to '/usr/share/local'..."
|
||||||
sudo cp "$DH_CONFIG_DIR"/locale/distrohopper-"$lang".mo /usr/share/locale/"$lang"/LC_MESSAGES/distrohopper.mo
|
sudo cp "$DH_CONFIG_DIR"/locale/distrohopper-"$lang".mo /usr/share/locale/"$lang"/LC_MESSAGES/distrohopper.mo
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
# run --------------------------------------
|
# run --------------------------------------
|
||||||
set_variables
|
set_variables
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue