|
|
@ -456,14 +456,12 @@ class EncryptTask extends AbstractTask { |
|
|
|
if (isset ( $this->mageConfig ['keeptemp'] )) { |
|
|
|
if (isset ( $this->mageConfig ['keeptemp'] )) { |
|
|
|
return; |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
Console::log('Deleting tempory files :', 0); |
|
|
|
Console::log('Deleting tempory files :', 1); |
|
|
|
$ret1 = $this->runCommandLocal ( 'rm -Rf ' . $this->ionSource, $out1 ); |
|
|
|
$ret1 = Console::executeCommand ( 'rm -Rf ' . $this->ionSource, $out1 ); |
|
|
|
$ret2 = $this->runCommandLocal ( 'rm ' . $this->projectFile, $out2 ); |
|
|
|
$ret2 = Console::executeCommand ( 'rm ' . $this->projectFile, $out2 ); |
|
|
|
if ($ret1 && $ret2) { |
|
|
|
if ($ret1 && $ret2) { |
|
|
|
Console::log('OK',0); |
|
|
|
|
|
|
|
return; |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
Console::log('Failed!', 1); |
|
|
|
|
|
|
|
throw new ErrorWithMessageException ( 'Error deleting temp files :' . $out1 . ' : ' . $out2, 40 ); |
|
|
|
throw new ErrorWithMessageException ( 'Error deleting temp files :' . $out1 . ' : ' . $out2, 40 ); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -475,7 +473,7 @@ class EncryptTask extends AbstractTask { |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
private function runIonCube() { |
|
|
|
private function runIonCube() { |
|
|
|
$cli = $this->encoder . ' --project-file ' . $this->projectFile . ' ' . $this->ionSource . DIRECTORY_SEPARATOR.'*'; |
|
|
|
$cli = $this->encoder . ' --project-file ' . $this->projectFile . ' ' . $this->ionSource . DIRECTORY_SEPARATOR.'*'; |
|
|
|
$ret = $this->runCommandLocal ( $cli, $out ); |
|
|
|
$ret = Console::executeCommand ( $cli, $out ); |
|
|
|
return $ret; |
|
|
|
return $ret; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -586,11 +584,11 @@ class EncryptTask extends AbstractTask { |
|
|
|
*/ |
|
|
|
*/ |
|
|
|
private function switchSrcToTmp() { |
|
|
|
private function switchSrcToTmp() { |
|
|
|
//echo "\nSwitching :" . $this->source . " -> To :" . $this->ionSource."\n"; |
|
|
|
//echo "\nSwitching :" . $this->source . " -> To :" . $this->ionSource."\n"; |
|
|
|
$ret = $this->runCommandLocal ( 'mv ' . $this->source . ' ' . $this->ionSource, $out ); |
|
|
|
$ret = Console::executeCommand ( 'mv ' . $this->source . ' ' . $this->ionSource, $out ); |
|
|
|
if (! $ret) { |
|
|
|
if (! $ret) { |
|
|
|
throw new ErrorWithMessageException ( 'Cant create tmp dir :' . $out, $ret ); |
|
|
|
throw new ErrorWithMessageException ( 'Cant create tmp dir :' . $out, $ret ); |
|
|
|
} |
|
|
|
} |
|
|
|
$ret = $this->runCommandLocal ( 'mkdir -p ' . $this->source, $out ); |
|
|
|
$ret = Console::executeCommand ( 'mkdir -p ' . $this->source, $out ); |
|
|
|
if (! $ret) { |
|
|
|
if (! $ret) { |
|
|
|
throw new ErrorWithMessageException ( 'Cant re-create dir :' . $out, $ret ); |
|
|
|
throw new ErrorWithMessageException ( 'Cant re-create dir :' . $out, $ret ); |
|
|
|
} |
|
|
|
} |
|
|
@ -821,6 +819,11 @@ tasks: |
|
|
|
override: dyf |
|
|
|
override: dyf |
|
|
|
keeptemp: |
|
|
|
keeptemp: |
|
|
|
encoder: ioncube_encoder54 |
|
|
|
encoder: ioncube_encoder54 |
|
|
|
|
|
|
|
checkencoding: true |
|
|
|
|
|
|
|
checkignorepaths: |
|
|
|
|
|
|
|
-/public/js/* |
|
|
|
|
|
|
|
-/public/css/* |
|
|
|
|
|
|
|
|
|
|
|
projfile: project.prj |
|
|
|
projfile: project.prj |
|
|
|
project: |
|
|
|
project: |
|
|
|
replace-target: |
|
|
|
replace-target: |
|
|
|