Add translations info

master
Артемий 3 years ago
parent 8af2971473
commit e4d0d5c29c

@ -1,7 +1,7 @@
#!/bin/bash
set -e
source "${SHARE_DIR_ROOT}/common.sh"
source "${DESTDIR}/usr/share/linux-infosec-setupper/common.sh"
_mk_pwquality_conf() {
local failed=0
@ -149,3 +149,4 @@ EOF
if [ "$enforce_for_root" == 1 ]; then echo "enforce_for_root"; fi
if [ "$local_users_only" == 1 ]; then echo "local_users_only"; fi
}
_mk_pwquality_conf --gecoscheck 3

@ -21,6 +21,10 @@ error() {
echo '' 1>&2
}
# Translations
TEXTDOMAIN=linux-infosec-setupper
TEXTDOMAINDIR=/usr/share/locale
# $1 - value
# $2 - param name
# (optional) $3 - anything, trigger check for non-negative

@ -21,7 +21,15 @@ for i in gecoscheck enforce_for_root local_users_only dictcheck usercheck enforc
# The variables have the same name as the lines in the config
eval 'if [[ $'$i' == 1 ]]; then declare $i=TRUE; else declare $i=FALSE; fi'
done
var="$(yad --title=$"linux-infosec-setupper" --form --text=$"Password policies setup" --image=/usr/share/icons/hicolor/48x48/apps/gcr-key.png --scroll --width=800 --height=800 --button=$"Load defaults!view-refresh:3" --button=$"yad-save:0" --button=$"yad-close:1" \
var="$(yad --title=$"linux-infosec-setupper" --form \
--text-align=center \
--bool-fmt=T \
--text=$"<span size='xx-large' weight='bold'>Password policies setup</span>" \
--image=/usr/share/icons/hicolor/48x48/apps/gcr-key.png \
--scroll \
--width=800 \
--height=800 \
--button=$"Load defaults!view-refresh:3" --button=$"yad-save:0" --button=$"yad-close:1" \
--field=$"Number of characters in the new password that must not be present in the old password::LBL" "!" \
--field=$"Value (difok)::NUM" "$difok!1..9999!1" \
--field=$"Minimum acceptable size for the new password:LBL" "!" \

@ -1,6 +1,7 @@
#!/bin/bash
set -e
. common.sh
source "${DESTDIR}/usr/share/linux-infosec-setupper/common.sh" # || . ./common.sh
# $1 - action
# $2 - param name

Loading…
Cancel
Save