Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ivy-completing-read with require-match doesn't permit ivy-use-selectable-prompt #3059

Open
plantarum opened this issue Oct 17, 2024 · 0 comments

Comments

@plantarum
Copy link

Note: I think this is a duplicate/regression of #1924

I'm using Ivy Version: 0.14.2, GNU Emacs 31.0.50

I've run into a conflict between completing-read and ivy-completing-read.

completing-read takes the argument REQUIRE-MATCH, the definition of which includes:

REQUIRE-MATCH can take the following values:

  • t means that the user is not allowed to exit unless the input is (or
    completes to) an element of COLLECTION or is null.

That is, if REQUIRE-MATCH is set to t, I can select any of the targets, or the empty string. To demonstrate, try this:

(message "You selected: %s"
	 (completing-read "test: " '("one" "two" "three") nil t))

When I use ivy-mode, I set ivy-use-selectable-prompt to t, which should allow me to select the empty prompt. However, it seems that the function ivy--prompt-selectable-p over-rides this user setting when the call to completing-read sets the REQUIRE-MATCH argument to t.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant