From patchwork Tue Jan 2 19:57:39 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Britton Kerin X-Patchwork-Id: 13509336 Received: from aa.d.sender-sib.com (aa.d.sender-sib.com [185.41.28.128]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 7013715EB9 for ; Tue, 2 Jan 2024 19:58:00 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=aa.d.sender-sib.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=sendinblue.com header.i=@sendinblue.com header.b="XT8TETw1" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sendinblue.com; q=dns/txt; s=mail; bh=paGFajYSK01CCuuL6N8nXExiJZKJPbdxSNTjqLj48Cg=; h=from:subject:date:to:cc:mime-version:content-transfer-encoding:in-reply-to:references:x-csa-complaints:list-unsubscribe-post; b=XT8TETw1L8hD5tMbu/VZyFTIsc9sZpTjA2I9lM+0PPR8YEhJHFX+Fmpzft5ubLhdfu+Eh0t6Q7VF BXAANkKCLoEBP06Z0VEzMlUndaChlm+cbbNULN8Pp9YV8M3WERdqboLI9vABxBbVCp43apVYC6pv pAqxOveYYZQ4QBTraYI= Received: by smtp-relay.sendinblue.com with ESMTP id ac2d9b41-be28-45b8-9113-da59a85d791e; Tue, 02 January 2024 19:57:53 +0000 (UTC) X-Mailin-EID: MjQyODY0MDE0fmdpdEB2Z2VyLmtlcm5lbC5vcmd%2BPDIwMjQwMTAyMTk1NzQ0LjQ3ODUwMy0yLWJyaXR0b24ua2VyaW5AZ21haWwuY29tPn5hYS5kLnNlbmRlci1zaWIuY29t Date: Tue, 2 Jan 2024 10:57:39 -0900 Subject: [RFC PATCH 1/6] completion: complete new old actions, start opts Received: by brittons-large-Vivobook (Postfix, from userid 1000) id BA93B520263; Tue, 2 Jan 2024 10:57:50 -0900 (AKST) Cc: Britton Leo Kerin X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240102195744.478503-1-britton.kerin@gmail.com> References: <20240102195744.478503-1-britton.kerin@gmail.com> Precedence: bulk X-Mailing-List: git@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: Origin-messageId: <20240102195744.478503-2-britton.kerin@gmail.com> To: X-sib-id: qzd6UUIkvhX59XAz_WefTgjhL-Z9_BVnWo6OGeX_q-Ov2e1TXgCrRfpJ-NXcdv_uIBRYmP0s_s2eMR6OCnxVLiM5-5RzihIErR0GZqkUXBQPtee3lF1q_LDFMgyiI971fcfkXUFU754aYHYbDFzN4NNbVnI2gd3BGjQnS7qyrT4b X-CSA-Complaints: csa-complaints@eco.de List-Unsubscribe-Post: List-Unsubscribe=One-Click Feedback-ID: 185.41.28.128:6940237_-1:6940237:Sendinblue From: "Britton Leo Kerin" Signed-off-by: Britton Leo Kerin --- contrib/completion/git-completion.bash | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash index 185b47d802..15d22ff7d9 100644 --- a/contrib/completion/git-completion.bash +++ b/contrib/completion/git-completion.bash @@ -1449,7 +1449,7 @@ _git_bisect () { __git_has_doubledash && return - local subcommands="start bad good skip reset visualize replay log run" + local subcommands="start bad new good old terms skip reset visualize replay log run help" local subcommand="$(__git_find_on_cmdline "$subcommands")" if [ -z "$subcommand" ]; then __git_find_repo_path @@ -1462,7 +1462,20 @@ _git_bisect () fi case "$subcommand" in - bad|good|reset|skip|start) + start) + case "$cur" in + --*) + __gitcomp "--term-new --term-bad --term-old --term-good --first-parent --no-checkout" + return + ;; + *) + ;; + esac + ;; + esac + + case "$subcommand" in + bad|new|good|old|reset|skip|start) __git_complete_refs ;; *)