mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-29 16:54:04 +02:00
translation: Load msgmerge path from config or default to /usr/bin/env msgmerge
refs #9615
This commit is contained in:
parent
219dcdda37
commit
7160eb600a
@ -242,7 +242,12 @@ class GettextTranslationHelper
|
|||||||
private function updateTranslationTable()
|
private function updateTranslationTable()
|
||||||
{
|
{
|
||||||
if (is_file($this->tablePath)) {
|
if (is_file($this->tablePath)) {
|
||||||
shell_exec(sprintf('/usr/bin/msgmerge --update %s %s 2>&1', $this->tablePath, $this->templatePath));
|
shell_exec(sprintf(
|
||||||
|
'%s --update %s %s 2>&1',
|
||||||
|
$this->getConfig()->get('translation', 'msgmerge', '/usr/bin/env php'),
|
||||||
|
$this->tablePath,
|
||||||
|
$this->templatePath
|
||||||
|
));
|
||||||
} else {
|
} else {
|
||||||
if ((!is_dir(dirname($this->tablePath)) && !@mkdir(dirname($this->tablePath), 0755, true)) ||
|
if ((!is_dir(dirname($this->tablePath)) && !@mkdir(dirname($this->tablePath), 0755, true)) ||
|
||||||
!rename($this->templatePath, $this->tablePath)) {
|
!rename($this->templatePath, $this->tablePath)) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user