Skip to content

Commit

Permalink
Use constant as version base for patch releases
Browse files Browse the repository at this point in the history
  • Loading branch information
caendesilva committed Oct 30, 2023
1 parent e0adc39 commit 2a57c60
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions monorepo/DevTools/src/MonorepoReleaseCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,12 @@ protected function askForNewVersion(): void
{
$this->newVersionType = $this->choice('What type of release is this?', static::VERSION_TYPES, 1);

if ($this->newVersionType && ($this->currentVersion !== 'v' . HydeKernel::VERSION)) {
$this->info('Updating base to use framework constant');
$this->currentVersion = 'v'.HydeKernel::VERSION;
$this->currentVersionParts = explode('.', ltrim($this->currentVersion, 'v'));
}

$major = $this->currentVersionParts[0];
$minor = $this->currentVersionParts[1];
$patch = $this->currentVersionParts[2];
Expand Down

0 comments on commit 2a57c60

Please sign in to comment.