Skip to content

Commit

Permalink
Merge pull request #1424 from hydephp/add-monorepo-tools
Browse files Browse the repository at this point in the history
Update internal releaser to use constant as version base for patch releases
  • Loading branch information
caendesilva authored Oct 30, 2023
2 parents e0adc39 + 8cc8fc4 commit 02f4fe6
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions monorepo/DevTools/src/MonorepoReleaseCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,14 @@ protected function askForNewVersion(): void
{
$this->newVersionType = $this->choice('What type of release is this?', static::VERSION_TYPES, 1);

if ($this->newVersionType === 'patch') {
if ($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 02f4fe6

Please sign in to comment.