Update PHP_CodeSniffer ruleset: PSR2 → PSR12

This commit is contained in:
Zach Borboa
2023-06-30 01:23:37 -07:00
parent 9bd4776b73
commit cd924d10c3
115 changed files with 269 additions and 80 deletions
+4 -2
View File
@@ -7,13 +7,15 @@ $current_version = Curl\Curl::VERSION;
list($major, $minor, $patch) = explode('.', $current_version);
$new_version = implode('.', [$major, $minor, (string)((int)$patch += 1)]);
foreach ([
foreach (
[
[
__DIR__ . '/../src/Curl/Curl.php',
'/const VERSION = \'(?:\d+.\d+.\d+)\';/',
'const VERSION = \'' . $new_version . '\';',
],
] as $info) {
] as $info
) {
list($filepath, $find, $replace) = $info;
$data = preg_replace($find, $replace, file_get_contents($filepath));
file_put_contents($filepath, $data);