From ca0f62fad34e450977c738695070b77e39e1d1b0 Mon Sep 17 00:00:00 2001 From: Dmytro Serdiuk Date: Sat, 30 Nov 2019 12:11:09 +0200 Subject: [PATCH] Support active rebase process during `deliver-work` execution It happens that there are conflicts during the rebase of the latest HEAD into the current work branch. And once they are solved, the `deliver-work` execution one more time allows continuing current rebase and delivering work. --- docs/commands.md | 5 +++-- libexec/git-elegant-deliver-work | 14 ++++++++++---- libexec/git-elegant-polish-work | 3 ++- libexec/plugins/rebase | 6 ++++++ tests/git-elegant-deliver-work.bats | 9 +++++++++ 5 files changed, 30 insertions(+), 7 deletions(-) create mode 100644 libexec/plugins/rebase diff --git a/docs/commands.md b/docs/commands.md index b8ad1bb..b1817c2 100644 --- a/docs/commands.md +++ b/docs/commands.md @@ -141,8 +141,9 @@ git elegant acquire-repository usage: git elegant deliver-work [branch-name] ``` -Updates the current branch by rebasing the default upstream branch. Then, -it pushes HEAD to the appropriate upstream branch. +Updates the current branch by rebasing the default upstream branch. If there is +a rebase in progress, the command will continue it instead of initiation a new +one. Then, it pushes HEAD to the appropriate upstream branch. By default, the name of remote branch is equal to the local one. If a local branch has an upstream branch configured, it will be used as a remote branch. diff --git a/libexec/git-elegant-deliver-work b/libexec/git-elegant-deliver-work index fbae086..4b8eb61 100644 --- a/libexec/git-elegant-deliver-work +++ b/libexec/git-elegant-deliver-work @@ -15,8 +15,9 @@ MESSAGE command-description() { cat<