Subject: bug#63469: 29.0.90; project.el doesn't add menu-bar entries

From: Eli Zaretskii <[email-masked]>
Date: Fri, 19 May 2023 13:44:39 +0300

> From: Juri Linkov <[email-masked]>
> Cc: Eli Zaretskii <[email-masked]>,  Spencer Baugh <[email-masked]>,
>   [email-masked]
> Date: Fri, 19 May 2023 09:56:31 +0300
> 
> This mode is intended for anyone who wants to show the menu
> only in project-supported buffers.  To do this, they need to
> enable `global-project-mode':
> 
> ```patch
> diff --git a/lisp/progmodes/project.el b/lisp/progmodes/project.el
> index 7c51778d5d4..e6dc7aea9ca 100644
> --- a/lisp/progmodes/project.el
> +++ b/lisp/progmodes/project.el
> @@ -1883,5 +1883,30 @@ project-switch-project
>      (let ((project-current-directory-override dir))
>        (call-interactively command))))
>  
> +(easy-menu-define project-mode-menu project-prefix-map
> +  "Menu for `project-mode' buffers."
> +  '("Project"
> +    ["List buffers" project-list-buffers
> +     :help "List project buffers"]
> +    ;; ...
> +    ))
> +
> +;;;###autoload
> +(define-minor-mode project-mode
> +  "Toggle display of project menu in the project-aware buffers."
> +  :lighter " Pro"
> +  :keymap (define-keymap "<menu-bar>" project-mode-menu))

If this mode is only for showing the menu, then at least the mode's
name should reflect that.

And once again: I don't think I see the justification to have a minor
mode whose only job is to show a menu-bar menu.  I'm not even sure why
we need to have a project-mode at all: AFAIU the project.el features
are always available, so no mode is needed.