Skip to content

ivy-alt-done wipes out buffer when called via M-x from nested minibuffer #924

@dpathakj

Description

@dpathakj

The suggestion in README.md to enable recursive minibuffers (via (setq enable-recursive-minibuffers t) led me to think that commands like M-x should be usable from within the swiper minibuffer.

However, I saw something I didn't expect when I tried this.

  1. I engaged swiper (C-s), and navigated to a completion.
  2. From within that swiper minibuffer, I typed M-x (bound to counsel-M-x) to call ivy-alt-done (I'd forgotten the hotkey)
  3. The entire contents of the buffer that I was on before I started swiper (that is, the buffer I was searching in with swiper) were replaced with the text "ivy-alt-done".

Instead, what I wanted was for ivy-alt-done to be called in the swiper minibuffer I left.

This is reproducible with a minimal setup (emacs -Q, etc.).

This seems like exactly the sort of use case that recursive minibuffers would help with. I see that some commands play with enable-recursive-minibuffers but counsel-M-x isn't one of them. Is that an easy fix?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions