From 3a1c1a6b99be76d4a9d933292a04b67d5809159a Mon Sep 17 00:00:00 2001 From: andrewpollack Date: Mon, 30 Aug 2021 03:16:37 -0700 Subject: [PATCH] merge branch closes window (#882) fixes #876 --- CHANGELOG.md | 1 + src/components/branchlist.rs | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index cd48d7a9..54f0a2ba 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -16,6 +16,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - added scrollbar to revlog [[@ashvin021](https://github.com/ashvin021)] ([#868](https://github.com/extrawurst/gitui/issues/868)) ## Fixed +- fix merging branch not closing branch window [[@andrewpollack](https://github.com/andrewpollack)] ([#876](https://github.com/extrawurst/gitui/issues/876)) - fix commit msg being broken inside tag list ([#871](https://github.com/extrawurst/gitui/issues/871)) - fix filetree file content not showing tabs correctly ([#874](https://github.com/extrawurst/gitui/issues/874)) diff --git a/src/components/branchlist.rs b/src/components/branchlist.rs index 868061af..e5fd184e 100644 --- a/src/components/branchlist.rs +++ b/src/components/branchlist.rs @@ -362,12 +362,13 @@ impl BranchListComponent { !self.branches.is_empty() } - fn merge_branch(&self) -> Result<()> { + fn merge_branch(&mut self) -> Result<()> { if let Some(branch) = self.branches.get(usize::from(self.selection)) { sync::merge_branch(CWD, &branch.name)?; + self.hide(); self.queue.push(InternalEvent::Update(NeedsUpdate::ALL)); }