Commit 10584f54 authored by Mikhail Tergoev's avatar Mikhail Tergoev

fixed merge pot

parent 34e4bbc8
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
msgid "" msgid ""
msgstr "Project-Id-Version: PACKAGE VERSION\n" msgstr "Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2024-10-31 19:55+0500\n" "POT-Creation-Date: 2024-11-01 02:46+0500\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n" "Language-Team: LANGUAGE <LL@li.org>\n"
...@@ -1682,3 +1682,38 @@ msgstr "" ...@@ -1682,3 +1682,38 @@ msgstr ""
msgid "Please wait. downloading covers for" msgid "Please wait. downloading covers for"
msgstr "" msgstr ""
msgid "use"
msgstr ""
msgid "Forces all scripts to be updated to a working state\n"
" (helps if "
"PortProton is not working)"
msgstr ""
msgid "Reinstalls PortProton and resets all settings to default"
msgstr ""
msgid "Creates a files with translations .pot and .po"
msgstr ""
msgid "Debug scripts for PortProton\n"
" (saved log in"
msgstr ""
msgid "Check update scripts for PortProton"
msgstr ""
msgid "Launches the application immediately, requires the path to the .exe "
"file"
msgstr ""
msgid "After the variable, the path to the .exe file is required and then "
"the variables.\n"
" (List their "
"variables and values for example PW_MANGOHUD=1 PW_VKBASALT=0, etc.)"
msgstr ""
msgid "--autoinstall and the name of what needs to be installed is given in "
"the list below:"
msgstr ""
...@@ -8,7 +8,7 @@ msgid "" ...@@ -8,7 +8,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: \n" "Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2024-10-31 19:54+0500\n" "POT-Creation-Date: 2024-11-01 02:43+0500\n"
"PO-Revision-Date: 2024-10-26 13:58+0500\n" "PO-Revision-Date: 2024-10-26 13:58+0500\n"
"Last-Translator: \n" "Last-Translator: \n"
"Language-Team: \n" "Language-Team: \n"
...@@ -2181,6 +2181,47 @@ msgstr "" ...@@ -2181,6 +2181,47 @@ msgstr ""
msgid "Please wait. downloading covers for" msgid "Please wait. downloading covers for"
msgstr "Por favor, espera. Descargando portadas para" msgstr "Por favor, espera. Descargando portadas para"
msgid "use"
msgstr ""
msgid ""
"Forces all scripts to be updated to a working state\n"
" (helps if PortProton is "
"not working)"
msgstr ""
#, fuzzy
msgid "Reinstalls PortProton and resets all settings to default"
msgstr "Restaurar configuraciones predeterminadas"
msgid "Creates a files with translations .pot and .po"
msgstr ""
msgid ""
"Debug scripts for PortProton\n"
" (saved log in"
msgstr ""
#, fuzzy
msgid "Check update scripts for PortProton"
msgstr "Espere la actualización PortProton"
msgid ""
"Launches the application immediately, requires the path to the .exe file"
msgstr ""
msgid ""
"After the variable, the path to the .exe file is required and then the "
"variables.\n"
" (List their variables "
"and values for example PW_MANGOHUD=1 PW_VKBASALT=0, etc.)"
msgstr ""
msgid ""
"--autoinstall and the name of what needs to be installed is given in the "
"list below:"
msgstr ""
#~ msgid "" #~ msgid ""
#~ "A higher number of duplicate desktop files were found for this file." #~ "A higher number of duplicate desktop files were found for this file."
#~ "\\nShould I delete the extra ones or not?" #~ "\\nShould I delete the extra ones or not?"
......
...@@ -7,8 +7,8 @@ msgid "" ...@@ -7,8 +7,8 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: \n" "Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2024-10-31 19:54+0500\n" "POT-Creation-Date: 2024-11-01 02:43+0500\n"
"PO-Revision-Date: 2024-10-31 19:55+0500\n" "PO-Revision-Date: 2024-11-01 02:44+0500\n"
"Last-Translator: \n" "Last-Translator: \n"
"Language-Team: \n" "Language-Team: \n"
"Language: ru_RU\n" "Language: ru_RU\n"
...@@ -2168,6 +2168,55 @@ msgstr "SteamGridDB не отвечает, принудительно отклю ...@@ -2168,6 +2168,55 @@ msgstr "SteamGridDB не отвечает, принудительно отклю
msgid "Please wait. downloading covers for" msgid "Please wait. downloading covers for"
msgstr "Пожалуйста, подождите. Загрузка обложек для" msgstr "Пожалуйста, подождите. Загрузка обложек для"
msgid "use"
msgstr "использовать"
msgid ""
"Forces all scripts to be updated to a working state\n"
" (helps if PortProton is "
"not working)"
msgstr ""
"Принудительно обновляет все скрипты до рабочего состояния.\n"
" (помогает, если "
"PortProton не работает)"
msgid "Reinstalls PortProton and resets all settings to default"
msgstr "Переустанавливает PortProton и сбрасывает все настройки по умолчанию"
msgid "Creates a files with translations .pot and .po"
msgstr "Создает файлы с переводами .pot и .po"
msgid ""
"Debug scripts for PortProton\n"
" (saved log in"
msgstr ""
"Скрипты отладки для PortProton\n"
" (сохраняет лог в"
msgid "Check update scripts for PortProton"
msgstr "Проверьте скрипты обновления для PortProton"
msgid ""
"Launches the application immediately, requires the path to the .exe file"
msgstr "Запускает приложение сразу, требует путь к exe-файлу"
msgid ""
"After the variable, the path to the .exe file is required and then the "
"variables.\n"
" (List their variables "
"and values for example PW_MANGOHUD=1 PW_VKBASALT=0, etc.)"
msgstr ""
"После переменной необходимо указать путь к файлу .exe, а затем переменные.\n"
" (Перечислите их "
"переменные и значения, например PW_MANGOHUD=1 PW_VKBASALT=0 и т. д.)"
msgid ""
"--autoinstall and the name of what needs to be installed is given in the "
"list below:"
msgstr ""
"--autoinstall и название того, что необходимо установить, указано в списке "
"ниже:"
#~ msgid "" #~ msgid ""
#~ "A higher number of duplicate desktop files were found for this file." #~ "A higher number of duplicate desktop files were found for this file."
#~ "\\nShould I delete the extra ones or not?" #~ "\\nShould I delete the extra ones or not?"
......
...@@ -200,28 +200,17 @@ change_locale () { ...@@ -200,28 +200,17 @@ change_locale () {
export -f change_locale export -f change_locale
generate_pot () { generate_pot () {
sed 's/{translations\[/(gettext \"/g' functions_helper > functions_helper_tmp local FILES_FOR_GETTEXT i
sed -i 's/]}/")/g' functions_helper_tmp FILES_FOR_GETTEXT=(functions_helper start.sh setup.sh add_in_steam.sh help_info)
sed -i 's/eval_translations/gettext/g' functions_helper_tmp for i in ${FILES_FOR_GETTEXT[@]} ; do
sed 's/{translations\[/(gettext \"/g' "${PORT_SCRIPTS_PATH}/$i" > "${PORT_SCRIPTS_PATH}/${i}_tmp"
sed 's/{translations\[/(gettext \"/g' start.sh > start.sh_tmp sed -i 's/]}/")/g' "${PORT_SCRIPTS_PATH}/${i}_tmp"
sed -i 's/]}/")/g' start.sh_tmp sed -i 's/eval_translations/gettext/g' "${PORT_SCRIPTS_PATH}/${i}_tmp"
sed -i 's/eval_translations/gettext/g' start.sh_tmp done
sed 's/{translations\[/(gettext \"/g' setup.sh > setup.sh_tmp
sed -i 's/]}/")/g' setup.sh_tmp
sed -i 's/eval_translations/gettext/g' setup.sh_tmp
sed 's/{translations\[/(gettext \"/g' add_in_steam.sh > add_in_steam.sh_tmp
sed -i 's/]}/")/g' add_in_steam.sh_tmp
sed -i 's/eval_translations/gettext/g' add_in_steam.sh_tmp
#Когда присходит предупреждение: синтаксис $"..." запрещен по соображениям безопасности; используйте eval_gettext #Когда присходит предупреждение: синтаксис $"..." запрещен по соображениям безопасности; используйте eval_gettext
#и ругается на строку в которой нет перевода, можно использовать sed -i '//d' и убрать эту строку #и ругается на строку в которой нет перевода, можно использовать sed -i '//d' и убрать эту строку
#либо отредактировать сам код, чтобы не было такой ошибки (к примеру вместо двойных ковычек использовать в таком месте одинарные) #либо отредактировать сам код, чтобы не было такой ошибки (к примеру вместо двойных ковычек использовать в таком месте одинарные)
for lang in $LANGUAGES_LIST ; do
for lang in $LANGUAGES_LIST
do
echo "${lang}" echo "${lang}"
create_new_dir "${PORT_WINE_PATH}/data/locales/${lang}/LC_MESSAGES/" create_new_dir "${PORT_WINE_PATH}/data/locales/${lang}/LC_MESSAGES/"
LANG_PO="${PORT_WINE_PATH}/data/locales/${lang}/LC_MESSAGES/PortProton.po" LANG_PO="${PORT_WINE_PATH}/data/locales/${lang}/LC_MESSAGES/PortProton.po"
...@@ -233,6 +222,7 @@ generate_pot () { ...@@ -233,6 +222,7 @@ generate_pot () {
"data/scripts/setup.sh_tmp" \ "data/scripts/setup.sh_tmp" \
"data/scripts/functions_helper_tmp" \ "data/scripts/functions_helper_tmp" \
"data/scripts/add_in_steam.sh_tmp" \ "data/scripts/add_in_steam.sh_tmp" \
"data/scripts/help_info_tmp" \
-o "$TEMPLATE_POT" -o "$TEMPLATE_POT"
popd 1>/dev/null || fatal popd 1>/dev/null || fatal
if [[ -f "$LANG_PO" ]] ; then if [[ -f "$LANG_PO" ]] ; then
...@@ -248,6 +238,7 @@ generate_pot () { ...@@ -248,6 +238,7 @@ generate_pot () {
try_remove_file "${PORT_SCRIPTS_PATH}/setup.sh_tmp" try_remove_file "${PORT_SCRIPTS_PATH}/setup.sh_tmp"
try_remove_file "${PORT_SCRIPTS_PATH}/functions_helper_tmp" try_remove_file "${PORT_SCRIPTS_PATH}/functions_helper_tmp"
try_remove_file "${PORT_SCRIPTS_PATH}/add_in_steam.sh_tmp" try_remove_file "${PORT_SCRIPTS_PATH}/add_in_steam.sh_tmp"
try_remove_file "${PORT_SCRIPTS_PATH}/help_info_tmp"
try_remove_dir "${PW_CACHE_LANG_PATH}" try_remove_dir "${PW_CACHE_LANG_PATH}"
} }
export -f generate_pot export -f generate_pot
...@@ -2534,7 +2525,7 @@ pw_check_command () { ...@@ -2534,7 +2525,7 @@ pw_check_command () {
unset TIMEOUT_CMD unset TIMEOUT_CMD
return 1 return 1
else else
print_info "$S_CMD - found" # print_info "$S_CMD - found"
unset TIMEOUT_CMD unset TIMEOUT_CMD
return 0 return 0
fi fi
......
#!/bin/bash
files_from_autoinstall=$(ls "${PORT_SCRIPTS_PATH}/pw_autoinstall")
echo -e "${translations[use]}: [--repair] [--reinstall] [--autoinstall]
--repair ${translations[Forces all scripts to be updated to a working state
(helps if PortProton is not working)]}
--reinstall ${translations[Reinstalls PortProton and resets all settings to default]}
--generate-pot ${translations[Creates a files with translations .pot and .po]}
--debug ${translations[Debug scripts for PortProton
(saved log in]} $PORT_WINE_PATH/scripts-debug.log)
--update ${translations[Check update scripts for PortProton]}
--launch ${translations[Launches the application immediately, requires the path to the .exe file]}
--edit-db ${translations[After the variable, the path to the .exe file is required and then the variables.
(List their variables and values for example PW_MANGOHUD=1 PW_VKBASALT=0, etc.)]}
--autoinstall ${translations[--autoinstall and the name of what needs to be installed is given in the list below:]}
$(echo $files_from_autoinstall | awk '{for (i = 1; i <= NF; i++) {if (i % 10 == 0) {print ""} printf "%s ", $i}}')
"
...@@ -18,7 +18,6 @@ echo ' ...@@ -18,7 +18,6 @@ echo '
██║░░░░░╚█████╔╝██║░░██║░░░██║░░░██║░░░░░██║░░██║╚█████╔╝░░░██║░░░╚█████╔╝██║░╚███║ ██║░░░░░╚█████╔╝██║░░██║░░░██║░░░██║░░░░░██║░░██║╚█████╔╝░░░██║░░░╚█████╔╝██║░╚███║
╚═╝░░░░░░╚════╝░╚═╝░░╚═╝░░░╚═╝░░░╚═╝░░░░░╚═╝░░╚═╝░╚════╝░░░░╚═╝░░░░╚════╝░╚═╝░░╚══╝ ╚═╝░░░░░░╚════╝░╚═╝░░╚═╝░░░╚═╝░░░╚═╝░░░░░╚═╝░░╚═╝░╚════╝░░░░╚═╝░░░░╚════╝░╚═╝░░╚══╝
' '
$PW_DEBUG $PW_DEBUG
if [[ $(id -u) = 0 ]] \ if [[ $(id -u) = 0 ]] \
...@@ -366,68 +365,50 @@ fi ...@@ -366,68 +365,50 @@ fi
### CLI ### ### CLI ###
case "$1" in case "$1" in
'--help' ) --help)
files_from_autoinstall=$(ls "${PORT_SCRIPTS_PATH}/pw_autoinstall") # shellcheck source=/dev/null
echo -e " source "${PORT_SCRIPTS_PATH}/help_info"
use: [--repair] [--reinstall] [--autoinstall] exit 0
;;
--repair forces all scripts to be updated to a working state --reinstall)
(helps if PortProton is not working)
--reinstall reinstall files of the portproton to default settings
--autoinstall [script_frome_pw_autoinstall] autoinstall from the list below:
"
echo ${files_from_autoinstall}
echo "
--generate-pot generated pot file
"
echo "
--debug debug scripts for PortProton
(saved log in $PORT_WINE_PATH/scripts-debug.log)
"
echo "
--update check update scripts for PortProton
"
exit 0 ;;
'--reinstall' )
export PW_REINSTALL_FROM_TERMINAL=1 export PW_REINSTALL_FROM_TERMINAL=1
pw_reinstall_pp ;; pw_reinstall_pp
;;
'--autoinstall' ) --autoinstall)
export PW_YAD_SET="$2" export PW_YAD_SET="$2"
pw_autoinstall_from_db pw_autoinstall_from_db
exit 0 ;; exit 0
;;
'--generate-pot' ) --generate-pot)
generate_pot generate_pot
exit 0 ;; exit 0
;;
'--debug' ) --debug)
clear clear
export PW_DEBUG="set -x" export PW_DEBUG="set -x"
/usr/bin/env bash -c ${pw_full_command_line[@]} 2>&1 | tee "$PORT_WINE_PATH/scripts-debug.log" & /usr/bin/env bash -c ${pw_full_command_line[@]} 2>&1 | tee "$PORT_WINE_PATH/scripts-debug.log" &
exit 0 ;; exit 0
;;
'--server-file-access' ) --server-file-access)
echo echo
curl -s --list-only "https://cloud.linux-gaming.ru/log/$(date +20%y_%m)_file_access.log" | sort -V -k 2,2 \ curl -s --list-only "https://cloud.linux-gaming.ru/log/$(date +20%y_%m)_file_access.log" | sort -V -k 2,2 \
| sed 's/count=//g' | awk '{a=$1; $1=$2; $2=a} 1' | awk 'BEGIN {print "Count: Name:"} {print}' | column -t | sed 's/count=//g' | awk '{a=$1; $1=$2; $2=a} 1' | awk 'BEGIN {print "Count: Name:"} {print}' | column -t
echo echo
exit 0 ;; exit 0
;;
'--update' ) --update)
gui_pw_update ;; gui_pw_update
;;
'--launch' ) --launch)
portwine_launch portwine_launch
stop_portwine ;; stop_portwine
;;
'--edit-db' ) --edit-db)
# --edit-db /полный/путь/до/файла.exe PW_MANGOHUD=1 PW_VKBASALT=0 (и т.д) для примера # --edit-db /полный/путь/до/файла.exe PW_MANGOHUD=1 PW_VKBASALT=0 (и т.д) для примера
set_several_variables ${@:3} set_several_variables ${@:3}
edit_db_from_gui $keys_all edit_db_from_gui $keys_all
exit 0 ;; exit 0
;;
esac esac
### GUI ### ### GUI ###
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment