From f5ca593405cca4aa9f20a3da1ec7e4da9c204042 Mon Sep 17 00:00:00 2001 From: Alex Date: Fri, 12 Apr 2024 13:35:09 +0300 Subject: [PATCH] Don't show non-merged revisions table after a successful auto-commit --- CHANGELOG.md | 2 +- src/SVNBuddy/Command/MergeCommand.php | 7 ++++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 06cea2c..1c9193c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,7 +10,7 @@ This project adheres to [Semantic Versioning](http://semver.org/). ... ### Fixed -... +- The non-merged revision table was shown after a successful auto-commit, when merge conflict was resolved. ## [0.7.0] - 2024-04-12 ### Added diff --git a/src/SVNBuddy/Command/MergeCommand.php b/src/SVNBuddy/Command/MergeCommand.php index 3c6744b..0c29a36 100644 --- a/src/SVNBuddy/Command/MergeCommand.php +++ b/src/SVNBuddy/Command/MergeCommand.php @@ -284,7 +284,12 @@ protected function execute(InputInterface $input, OutputInterface $output) if ( $revisions ) { $revisions = array_intersect($revisions, $this->_usableRevisions); - if ( !$revisions && !$this->performCommit() ) { + // Auto-commit instead of failing. + if ( !$revisions && $this->performCommit() ) { + return; + } + + if ( !$revisions ) { throw new CommandException(\sprintf( 'Requested revisions are %s', $this->isReverseMerge() ? 'not yet merged' : 'already merged'