From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1200 invoked by alias); 23 Sep 2016 06:48:46 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: X-Seq: 39423 Received: (qmail 1744 invoked from network); 23 Sep 2016 06:48:46 -0000 X-Qmail-Scanner-Diagnostics: from out2-smtp.messagingengine.com by f.primenet.com.au (envelope-from , uid 7791) with qmail-scanner-2.11 (clamdscan: 0.99.2/21882. spamassassin: 3.4.1. Clear:RC:0(66.111.4.26):SA:0(0.0/5.0):. Processed in 0.137181 secs); 23 Sep 2016 06:48:46 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=T_DKIM_INVALID autolearn=unavailable autolearn_force=no version=3.4.1 X-Envelope-From: d.s@daniel.shahaf.name X-Qmail-Scanner-Mime-Attachments: | X-Qmail-Scanner-Zip-Files: | Received-SPF: none (ns1.primenet.com.au: domain at daniel.shahaf.name does not designate permitted sender hosts) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= daniel.shahaf.name; h=date:from:message-id:subject:to:x-sasl-enc :x-sasl-enc; s=mesmtp; bh=5Zd76CRzyY5a8IhURiF+HD+T0Ag=; b=DlKHzw L8hBUEz3kpjJkCPg4v0xcIm+FKqhAlvZzXJFLDLCFb2E03NqGuX/dbg69A+PdNGC TQIVsexcQJHMYy/5W1UMPDeJx31aGvk412Qg1S0Y+VfKyGxjGXtlThzZhR7ZOpgV cw5D1Sit6ivXVALt/JebyJpDKsQI3+QaYb3Hs= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=date:from:message-id:subject:to :x-sasl-enc:x-sasl-enc; s=smtpout; bh=5Zd76CRzyY5a8IhURiF+HD+T0A g=; b=NbXS4TIqAGHsreHq3OQms1dZqN+7OrwmLMvNKFcAqIC2VFsxvp6aZMKaAy XTRv0WP5dMLLaUfE8G3GR89h7mO3gk/z90P8Pxu/ZmMExb0Ef8pVtFY9+cdwrMeu deX6aHVrdPctybqVp9Jo0L4XA4lMiMhXVCXSjmfTEzC5ZhdZI= X-Sasl-enc: MpdQJr1xCOzhKedAdGp5D3oAF0uYh4vvlCoUB9IlKp7d 1474613322 From: Daniel Shahaf To: zsh-workers@zsh.org Subject: [PATCH 1/2] vcs_info git: Produce nicer applied-string messages for 'exec' actions. Date: Fri, 23 Sep 2016 06:47:31 +0000 Message-Id: <1474613252-3229-1-git-send-email-danielsh@fujitsu.shahaf.local2> X-Mailer: git-send-email 2.1.4 This changes the behaviour on "unknown" git-rebase actions (those other than pick/reword/edit/fixup/squash/execute). --- Functions/VCS_Info/Backends/VCS_INFO_get_data_git | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/Functions/VCS_Info/Backends/VCS_INFO_get_data_git b/Functions/VCS_Info/Backends/VCS_INFO_get_data_git index 472c10d..18ba89a 100644 --- a/Functions/VCS_Info/Backends/VCS_INFO_get_data_git +++ b/Functions/VCS_Info/Backends/VCS_INFO_get_data_git @@ -213,8 +213,12 @@ elif [[ -d "${gitdir}/rebase-merge" ]]; then local p [[ -f "${patchdir}/done" ]] && for p in ${(f)"$(< "${patchdir}/done")"}; do - # remove action - git_patches_applied+=("${${(s: :)p}[2,-1]}") + # pick/edit/fixup/squash/reword: Add "$hash $subject" to $git_patches_applied. + # exec: Add "exec ${command}" to $git_patches_applied. + # (anything else): As 'exec'. + p=${p/(#s)(p|pick|e|edit|r|reword|f|fixup|s|squash) /} + p=${p/(#s)x /exec } + git_patches_applied+=("$p") done if [[ -f "${patchdir}/git-rebase-todo" ]] ; then git_patches_unapplied=(${(f)"$(grep -v '^$' "${patchdir}/git-rebase-todo" | grep -v '^#')"})