|
From: | Spyros Roum |
Subject: | Re: Add completion to compilation-read-command |
Date: | Wed, 25 Dec 2024 18:02:45 +0000 |
Juri Linkov wrote:
-(defun compilation-read-command (command) +(defun compilation-prompt-read-shell-command (command) (read-shell-command "Compile command: " command (if (equal (car compile-history) command) '(compile-history . 1) 'compile-history))) +(defun compilation-prompt-read-command-with-completion (command) + (completing-read "Compile command: " compile-history + nil nil command + (if (equal (car compile-history) command) + '(compile-history . 1) + 'compile-history)))Thanks. The only problem I see is that the function name doesn't indicate that it's completing on compile-history. Probably a better name would be: compilation-read-command-with-history-completion I see what you are saying, however, I do like the current
`compilation-prompt` prefix on If I were to keep both the `-prompt` prefix, and the
`history-completion` suffix, Instead, I suggest the name
`compilation-prompt-read-with-history-completion` Effectively dropping the word `command`. I think
`compilation-prompt` is enough and `command` doesn't add |
[Prev in Thread] | Current Thread | [Next in Thread] |