From a457914ebf16ef622e7236859b3f830c7702d2d4 Mon Sep 17 00:00:00 2001 From: JGZYES Date: Wed, 2 Sep 2026 21:43:02 +0800 Subject: [PATCH] fix(git.php): repair broken string literal in clone-fail message (parse error) --- web/git.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web/git.php b/web/git.php index 5bc03b1..5744a79 100644 --- a/web/git.php +++ b/web/git.php @@ -19,7 +19,7 @@ if (isset($_GET['action']) && $_GET['action'] === 'init') { $cmd = 'git clone --depth 1 ' . escapeshellarg($REPO_URL) . ' ' . escapeshellarg($REPO_DIR) . ' 2>&1'; $out = (string)@shell_exec($cmd); if (is_dir($REPO_DIR . '/.git')) echo 'OK'; - else echo '克隆失败:' . substr($out, 0, 220) . "\n(请确保 PHP 对 ' . $REPO_DIR . ' 可写:chmod -R 775 ' . $REPO_DIR . ' 或其父目录;或设 PMM_SRC_DIR)'; + else echo '克隆失败:' . substr($out, 0, 220) . "\n(请确保 PHP 对 " . $REPO_DIR . " 可写:chmod -R 775 " . $REPO_DIR . " 或其父目录;或设 PMM_SRC_DIR)"; } else { $out = (string)@shell_exec('git -C ' . escapeshellarg($REPO_DIR) . ' pull --depth 1 2>&1'); echo 'OK (pull: ' . substr(trim($out), 0, 80) . ')';