From ca6e984ecf5372783f3f9ed0d67f3e91ef90f9e7 Mon Sep 17 00:00:00 2001 From: Dima <9010963+message-dimke@users.noreply.github.com> Date: Mon, 23 Sep 2024 11:00:39 +0300 Subject: [PATCH] Fixing phpcs issues with spaces and @throws missing. --- .../src/Commands/Branch.php | 3 ++- .../src/Commands/Release.php | 22 +++++++++---------- 2 files changed, 13 insertions(+), 12 deletions(-) diff --git a/packages/php/woorelease-extension/src/Commands/Branch.php b/packages/php/woorelease-extension/src/Commands/Branch.php index 349e179b..13ff7cfa 100644 --- a/packages/php/woorelease-extension/src/Commands/Branch.php +++ b/packages/php/woorelease-extension/src/Commands/Branch.php @@ -29,7 +29,7 @@ class Branch extends Command { * * @var string|null */ - protected static $defaultName = 'branch'; + protected static $defaultName = 'branch'; // phpcs:ignore WordPress.NamingConventions.ValidVariableName /** * Configures the current command. @@ -53,6 +53,7 @@ protected function configure() { * @param OutputInterface $output Output. * * @return int Exit code. + * @throws Exception When the command has failed. */ protected function execute( InputInterface $input, OutputInterface $output ) { try { diff --git a/packages/php/woorelease-extension/src/Commands/Release.php b/packages/php/woorelease-extension/src/Commands/Release.php index 63488d0a..00aaa1f3 100644 --- a/packages/php/woorelease-extension/src/Commands/Release.php +++ b/packages/php/woorelease-extension/src/Commands/Release.php @@ -55,17 +55,17 @@ protected function configure() { */ protected function execute( InputInterface $input, OutputInterface $output ) { try { - $logger = Logger::instance( $output ); - $github_url = $input->getArgument( 'github_url' ); - $version = $input->getOption( 'product_version' ); - $wc_tested = $input->getOption( 'wc_tested' ); - $wp_tested = $input->getOption( 'wp_tested' ); - $prerelease = $input->getOption( 'prerelease' ); - $generate_changelog = $input->getOption( 'generate_changelog' ); - $nvm_use = $input->getOption( 'nvm_use' ); - $default_branch = $input->getOption( 'default_branch' ); - $release = ! $this->simulate; - $reauth = false !== $input->getOption( 'svn_reauth' ); + $logger = Logger::instance( $output ); + $github_url = $input->getArgument( 'github_url' ); + $version = $input->getOption( 'product_version' ); + $wc_tested = $input->getOption( 'wc_tested' ); + $wp_tested = $input->getOption( 'wp_tested' ); + $prerelease = $input->getOption( 'prerelease' ); + $generate_changelog = $input->getOption( 'generate_changelog' ); + $nvm_use = $input->getOption( 'nvm_use' ); + $default_branch = $input->getOption( 'default_branch' ); + $release = ! $this->simulate; + $reauth = false !== $input->getOption( 'svn_reauth' ); list( $product, $gh_org, $branch ) = Utils::parse_product_info( $github_url );