From 9a288c6264f5a013895e51b89be125ceff0b5fd4 Mon Sep 17 00:00:00 2001 From: Yoshinari Takaoka Date: Sun, 5 Nov 2023 11:09:15 +0900 Subject: [PATCH 1/3] [PHP 8.3] It is now possible to lint multiple files. --- features/commandline.xml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/features/commandline.xml b/features/commandline.xml index 1c5b3707af8d..fc1cca9a9975 100644 --- a/features/commandline.xml +++ b/features/commandline.xml @@ -546,6 +546,11 @@ string(15) "doesntmakesense" This option won't find fatal errors (like undefined functions). Use the to test for fatal errors too. + + + As of PHP 8.3.0, it is possible to check multiple files. + + This option does not work together with the From 909004bbf9b6efd6a06b0fd4b5b4c42e01ed2aaf Mon Sep 17 00:00:00 2001 From: Jim Winstead Date: Sat, 28 Sep 2024 18:15:04 -0700 Subject: [PATCH 2/3] Write-through -l documentation --- features/commandline.xml | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) diff --git a/features/commandline.xml b/features/commandline.xml index fc1cca9a9975..d7efee3bef3a 100644 --- a/features/commandline.xml +++ b/features/commandline.xml @@ -533,22 +533,26 @@ string(15) "doesntmakesense" --syntax-check - Provides a convenient way to perform only a syntax check - on the given PHP code. On success, the text + Syntax check but do not execute the given PHP code. The input from + standard input will be processed if no filenames are specified, otherwise + each filename will be checked. + On success, the text No syntax errors detected in <filename> is - written to standard output and the shell return code is - 0. On failure, the text Errors parsing - <filename> in addition to the internal parser error - message is written to standard output and the shell return code is set - to -1. + written to standard output. + On failure, the text Errors parsing <filename> + is written to standard output in addition to the internal parser error. + If any failures are found in the specified files (or standard input), + the shell return code is set to -1, otherwise the + shell return code is set to 0. - This option won't find fatal errors (like undefined functions). Use - the to test for fatal errors too. + This option won't find fatal errors (like undefined functions) that + require executing the code. - As of PHP 8.3.0, it is possible to check multiple files. + Before PHP 8.3.0, it was only possible to specify one filename to + be checked. From 4fe690291cb874838de0e9b4420555b21cb7f37e Mon Sep 17 00:00:00 2001 From: Jim Winstead Date: Mon, 30 Sep 2024 12:38:23 -0700 Subject: [PATCH 3/3] Apply suggestions from review Co-authored-by: Gina Peter Banyard --- features/commandline.xml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/features/commandline.xml b/features/commandline.xml index d7efee3bef3a..01613bf4898e 100644 --- a/features/commandline.xml +++ b/features/commandline.xml @@ -533,9 +533,9 @@ string(15) "doesntmakesense" --syntax-check - Syntax check but do not execute the given PHP code. The input from - standard input will be processed if no filenames are specified, otherwise - each filename will be checked. + Syntax check but do not execute the given PHP code. + The input from standard input will be processed if no filenames are specified, + otherwise each filename will be checked. On success, the text No syntax errors detected in <filename> is written to standard output. @@ -551,7 +551,7 @@ string(15) "doesntmakesense" - Before PHP 8.3.0, it was only possible to specify one filename to + Prior to PHP 8.3.0, it was only possible to specify one filename to be checked.