Windows 10, Emacs 25.1, Helm

I want to find text "test3". So I use helm-occur

enter image description here

As result I get 5 candidates. Nice.

Now I want to edit text direct in buffer helm-occur.

How I can do this?


Install the package wgrep-helm, then

  1. Save the occur result to a separate buffer with C-x C-s (helm-moccur-run-save-buffer)
  2. Change to wgrep mode with C-c C-p (wgrep-change-to-wgrep-mode)
  3. Edit the buffer like a normal buffer
  4. Apply the changes with C-x C-s (wgrep-finish-edit)

By the way, the above is documented via C-h m (helm-help).

| improve this answer | |
  • I need direct edit "Helm-occur" AND as result the buffer "text.txt" to change "on fly". Is it possible? – a_subscriber Aug 15 '18 at 12:16
  • Maybe better use package "Emacs-wgrep" because "wgrep-helm" was closed ? – a_subscriber Aug 15 '18 at 12:26
  • @Alexei The package name is wgrep-helm, which is provided by the project Emacs-wgrep. – xuchunyang Aug 15 '18 at 12:59
  • Can one put C-x C-s to action list? And how to bind C-c C-p in the "save buffer" mode? – theldoria Aug 15 '18 at 14:11
  • @theldoria C-x C-s is a normal Emacs command, not a helm action. It doesn't make sense to add it to the action list. C-c C-p is the default binding out of box (assuming you are a package.el user and having the package wgrep-helm installed.). – xuchunyang Aug 15 '18 at 15:31

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.