GNU bug report logs -
#78099
[PATCH] Make 'project-remember-project' interactive
Previous Next
Full log
View this message in rfc822 format
On 30/04/2025 03:38, Elijah Gabe Pérez wrote:
>> On 27/04/2025 23:18, Elijah Gabe Pérez wrote:
>>> + (interactive)
>> Something like
>>
>> (interactive (list (project-current t)))
>>
>> should allow to keep PR a required argument.
> Thanks, done:
How about this? Modulo reindentation.
diff --git a/lisp/progmodes/project.el b/lisp/progmodes/project.el
index 27b69277e81..e7ae7d282ab 100644
--- a/lisp/progmodes/project.el
+++ b/lisp/progmodes/project.el
@@ -1933,12 +1933,18 @@ project-remember-project
If project PR satisfies `project-list-exclude', then nothing is done.
Save the result in `project-list-file' if the list of projects
has changed, and NO-WRITE is nil."
- (let ((root (project-root pr)))
- (unless (seq-some (lambda (r)
+ (interactive (list (project-current t)))
+ (let ((root (project-root pr))
+ (interact (called-interactively-p 'any)))
+ (if (seq-some (lambda (r)
(if (functionp r)
(funcall r pr)
(string-match-p r root)))
project-list-exclude)
+ (when interact
+ (message "Current project is blacklisted!"))
+ (when interact
+ (message "Current project remembered"))
(project--remember-dir root no-write))))
(defun project--remove-from-project-list (project-root report-message)
This bug report was last modified 19 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.