From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs Subject: bug#50344: C-x v keybinding for vc-print-branch-log Date: Thu, 02 Sep 2021 21:43:13 +0300 Organization: LINKOV.NET Message-ID: <87mtoux1ha.fsf@mail.linkov.net> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="22929"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (x86_64-pc-linux-gnu) To: 50344@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Sep 02 20:46:24 2021 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mLrjD-0005oc-AO for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 02 Sep 2021 20:46:23 +0200 Original-Received: from localhost ([::1]:55704 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mLrjC-0005ft-5X for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 02 Sep 2021 14:46:22 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:46334) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mLris-0005fX-86 for bug-gnu-emacs@gnu.org; Thu, 02 Sep 2021 14:46:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:58731) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mLris-0006WS-0l for bug-gnu-emacs@gnu.org; Thu, 02 Sep 2021 14:46:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mLrir-0002MV-Uv for bug-gnu-emacs@gnu.org; Thu, 02 Sep 2021 14:46:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Juri Linkov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 02 Sep 2021 18:46:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 50344 X-GNU-PR-Package: emacs X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.16306083099017 (code B ref -1); Thu, 02 Sep 2021 18:46:01 +0000 Original-Received: (at submit) by debbugs.gnu.org; 2 Sep 2021 18:45:09 +0000 Original-Received: from localhost ([127.0.0.1]:42043 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mLri1-0002LL-IB for submit@debbugs.gnu.org; Thu, 02 Sep 2021 14:45:09 -0400 Original-Received: from lists.gnu.org ([209.51.188.17]:59104) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mLrhy-0002LD-M6 for submit@debbugs.gnu.org; Thu, 02 Sep 2021 14:45:09 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:46168) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mLrhy-0005bP-Cg for bug-gnu-emacs@gnu.org; Thu, 02 Sep 2021 14:45:06 -0400 Original-Received: from relay5-d.mail.gandi.net ([217.70.183.197]:55631) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mLrhw-0005eP-8k for bug-gnu-emacs@gnu.org; Thu, 02 Sep 2021 14:45:06 -0400 Original-Received: (Authenticated sender: juri@linkov.net) by relay5-d.mail.gandi.net (Postfix) with ESMTPSA id DC2691C0003 for ; Thu, 2 Sep 2021 18:44:59 +0000 (UTC) Received-SPF: pass client-ip=217.70.183.197; envelope-from=juri@linkov.net; helo=relay5-d.mail.gandi.net X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:213300 Archived-At: While vc-print-branch-log is a frequently used command, it still has no keybinding in vc-prefix-map. But it has a keybinding in vc-dir-mode-map. Many keys are already shared between vc-prefix-map and vc-dir-mode-map, e.g.: (defvar vc-dir-mode-map ;; VC commands (define-key map "v" #'vc-next-action) ;; C-x v v (define-key map "=" #'vc-diff) ;; C-x v = (define-key map "D" #'vc-root-diff) ;; C-x v D (define-key map "i" #'vc-register) ;; C-x v i (define-key map "+" #'vc-update) ;; C-x v + (define-key map "P" #'vc-push) ;; C-x v P (define-key map "l" #'vc-print-log) ;; C-x v l (define-key map "L" #'vc-print-root-log) ;; C-x v L (define-key map "I" #'vc-log-incoming) ;; C-x v I (define-key map "O" #'vc-log-outgoing) ;; C-x v O Also vc-dir-mode-map has branch keys: (let ((branch-map (make-sparse-keymap))) (define-key map "B" branch-map) (define-key branch-map "c" #'vc-create-tag) (define-key branch-map "l" #'vc-print-branch-log) (define-key branch-map "s" #'vc-retrieve-tag)) So it makes sense to copy branch keys from vc-dir-mode-map to vc-prefix-map: diff --git a/lisp/vc/vc-hooks.el b/lisp/vc/vc-hooks.el index 4b3c829a2c..d039c400c5 100644 --- a/lisp/vc/vc-hooks.el +++ b/lisp/vc/vc-hooks.el @@ -865,6 +865,9 @@ vc-prefix-map (let ((map (make-sparse-keymap))) (define-key map "a" #'vc-update-change-log) (define-key map "b" #'vc-switch-backend) + (define-key map "Bc" #'vc-create-tag) + (define-key map "Bl" #'vc-print-branch-log) + (define-key map "Bs" #'vc-retrieve-tag) (define-key map "d" #'vc-dir) (define-key map "g" #'vc-annotate) (define-key map "G" #'vc-ignore)