diff --git a/app/neato.php b/app/neato.php index 11d7f78..96a5769 100644 --- a/app/neato.php +++ b/app/neato.php @@ -33,6 +33,7 @@ require 'OS/neato_' . ucfirst($os['id']) . '.php'; $auto = (in_array('-y', $argv)) ? true : false; $mark = (in_array('-marksafe', $argv)) ? true : false; +$skipdeploy = (in_array('-skipdeploy', $argv)) ? true : false; $file = $argv[1]; if (is_string_found($argv[1], 'http://') || is_string_found($argv[1], 'https://')) { @@ -75,12 +76,16 @@ if (file_exists($cwd . '/deploy_' . $file.'.php')) { } if (file_exists($cwd . '/deploy_' . $file.'.sum')) { - $sum = read_file($cwd . '/deploy_' . $file.'.sum'); - if ($shasum === xor_encrypt($sum, $pk)) { - $check_for_harm = false; + if ($skipdeploy) { + unlink($cwd . '/deploy_' . $file.'.sum'); } else { - echo "Danger: SUM of Script has been modified!"; - exit(1); + $sum = read_file($cwd . '/deploy_' . $file.'.sum'); + if ($shasum === xor_encrypt($sum, $pk)) { + $check_for_harm = false; + } else { + echo "Danger: SUM of Script has been modified!"; + exit(1); + } } } @@ -88,6 +93,11 @@ if (file_exists($cwd . '/deploy_' . $file.'.php')) { save_sha($shasum); } + if ($skipdeploy) { + echo "Skipping Deploy php file..."; + exit(0); + } + if ($check_for_harm) { do_harm_checker($shasum); }