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#63469: 29.0.90; project.el doesn't add menu-bar entries Date: Thu, 29 Jun 2023 20:31:02 +0300 Organization: LINKOV.NET Message-ID: <86edlu2nyx.fsf@mail.linkov.net> References: <86zg4kt6iu.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="316"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/30.0.50 (x86_64-pc-linux-gnu) Cc: 63469@debbugs.gnu.org To: Spencer Baugh Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Jun 29 19:59:21 2023 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 1qEvvL-000ARs-Nf for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 29 Jun 2023 19:59:19 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qEvv7-0001J2-2I; Thu, 29 Jun 2023 13:59:05 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qEvv5-0001Is-CP for bug-gnu-emacs@gnu.org; Thu, 29 Jun 2023 13:59:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qEvv5-0005P6-3i for bug-gnu-emacs@gnu.org; Thu, 29 Jun 2023 13:59:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qEvv4-0001uq-IM for bug-gnu-emacs@gnu.org; Thu, 29 Jun 2023 13:59:02 -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, 29 Jun 2023 17:59:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 63469 X-GNU-PR-Package: emacs Original-Received: via spool by 63469-submit@debbugs.gnu.org id=B63469.16880615297341 (code B ref 63469); Thu, 29 Jun 2023 17:59:02 +0000 Original-Received: (at 63469) by debbugs.gnu.org; 29 Jun 2023 17:58:49 +0000 Original-Received: from localhost ([127.0.0.1]:53980 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qEvul-0001uD-7L for submit@debbugs.gnu.org; Thu, 29 Jun 2023 13:58:49 -0400 Original-Received: from relay7-d.mail.gandi.net ([217.70.183.200]:54915) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qEvug-0001tu-J2 for 63469@debbugs.gnu.org; Thu, 29 Jun 2023 13:58:41 -0400 X-GND-Sasl: juri@linkov.net X-GND-Sasl: juri@linkov.net Original-Received: by mail.gandi.net (Postfix) with ESMTPSA id C6D4E20002; Thu, 29 Jun 2023 17:58:31 +0000 (UTC) In-Reply-To: (Spencer Baugh's message of "Thu, 29 Jun 2023 11:30:06 -0400") 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-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:264284 Archived-At: > OK, here is such a patch: Thanks, one comment: > + (bindings--define-key menu [project-dired] > + '(menu-item "Open Root Directory Of Project..." project-dired > + :enable (menu-bar-non-minibuffer-window-p) > + :help "Read the root directory of the current project, to operate on its files")) There is an ellipsis at the end of the menu item that indicates that the command reads a directory from the minibuffer. So maybe a better command would be 'project-find-dir' that reads a directory like its counterpart 'project-find-file' reads a file: > (bindings--define-key menu [dired] > '(menu-item "Open Directory..." dired > :enable (menu-bar-non-minibuffer-window-p) > :help "Read a directory, to operate on its files")) > + (bindings--define-key menu [project-open-file] > + '(menu-item "Open File In Project..." project-find-file > + :enable (menu-bar-non-minibuffer-window-p) > + :help "Read an existing file in the current project into an Emacs buffer")) > (bindings--define-key menu [open-file] > '(menu-item "Open File..." menu-find-file-existing > :enable (menu-bar-non-minibuffer-window-p) > @@ -1746,6 +1760,10 @@ menu-bar-encryption-decryption-menu > > (defvar menu-bar-shell-commands-menu > (let ((menu (make-sparse-keymap "Shell Commands"))) > + (bindings--define-key menu [project-interactive-shell] > + '(menu-item "Run Shell Interactively In Project Root" project-shell This will make the menu item too wide. Would it be possible to omit the word "Interactively". I don't know why it's used in "Run Shell Interactively", but "Run Shell In Project Root" looks much nicer. > (bindings--define-key menu [interactive-shell] > '(menu-item "Run Shell Interactively" shell > :help "Run a subshell interactively")) > (bindings--define-key menu [compile] > - '(menu-item "Compile..." compile > - :help "Invoke compiler or Make, view compilation errors")) > + '(menu-item "Compile Buffer Directory..." compile > + :help "Invoke compiler or Make in current buffer's directory, view errors")) I think the text of the menu item "Compile Buffer Directory..." is too hard to understand. Probably better to retain the old text.