Skip to content

Commit

Permalink
Updates annotations to attributes
Browse files Browse the repository at this point in the history
  • Loading branch information
bomoko committed Nov 12, 2023
1 parent 64d29d4 commit 21cb816
Showing 1 changed file with 5 additions and 12 deletions.
17 changes: 5 additions & 12 deletions src/LagoonCommands.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
namespace Drush\Commands\drupal_integrations;

use Consolidation\SiteAlias\SiteAliasManagerAwareTrait;
use Drush\Attributes as CLI;
use Drush\Commands\DrushCommands;
use Drush\Drush;
use Drush\Exceptions\CommandFailedException;
Expand Down Expand Up @@ -86,11 +87,8 @@ public function __construct() {

/**
* Get all remote aliases from lagoon API.
*
* @command lagoon:aliases
*
* @aliases la
*/
#[CLI\Command(name: 'lagoon:aliases', aliases: ['la'])]
public function aliases() {
$this->preCommandChecks();
// Project still not defined, throw a warning.
Expand Down Expand Up @@ -124,31 +122,26 @@ public function aliases() {

/**
* Generate a JWT token for the lagoon API.
*
* @command lagoon:jwt
*
* @aliases jwt
*/
#[CLI\Command(name: 'lagoon:jwt', aliases: ['jwt'])]
public function generateJwt() {
$this->preCommandChecks();
$this->io()->writeln($this->getJwtToken());
}

/**
* Run pre-rollout tasks.
*
* @command lagoon:pre-rollout-tasks
*/
#[CLI\Command(name: 'lagoon:pre-rollout-tasks')]
public function preRolloutTasks() {
$this->preCommandChecks();
$this->runRolloutTasks('pre');
}

/**
* Run post-rollout tasks.
*
* @command lagoon:post-rollout-tasks
*/
#[CLI\Command(name: 'lagoon:post-rollout-tasks')]
public function postRolloutTasks() {
$this->preCommandChecks();
$this->runRolloutTasks('post');
Expand Down

0 comments on commit 21cb816

Please sign in to comment.