5

With ido-find-file, if the file I am looking is not in current directory but in the parents directory, it can automatically find it as candidate. I am not sure if helm can do the same thing?

  • How do you do that with ido-find-file? It doesn't work for me. If you want something like that, use Helm and Projectile. – Tu Do May 12 '15 at 2:51
  • @TuDo It's the Ido Auto-Merge feature which can be controlled using the ido-auto-merge-work-directories-length var. – Kaushal Modi May 12 '15 at 4:31
  • @TuDo, I am using Emacs 25 and all by default setup for ido. I am reading Helm Wiki and find how to find file in the subdirectory not parents. The directory is not under version control so don't thing Projectile would help. – Enze Chi May 12 '15 at 5:00
  • I don't think helm-find-files can do that and never will, since that behaviour of ido-find-file is confusing since it takes me to random location uncontrollably. You can use C-c h or M-p to list all visited directories though. – Tu Do May 12 '15 at 5:09
3

As mentioned by others in the comments, this probably isn't gong to happen. But I'll make a few suggestions that I hope might help you work with helm the way you want to.

This may be obvious, but if you are using helm-find-file, you can press Alt+Backspace. It sounds like you may know that already, but don't want to have to do it.

I tend to rely more on helm-for-files instead, and not think about what directory I am in at all. If your search string is only one word, any candidate in the parent directory will hopefully appear under the locate heading.

Finally, you may want to look further into projectile over here. You don't need to put a folder under version control to make it a project, just create an empty .projectile file in any parent directory you want to include.

1

Assuming your project is under Version Control, use vc-root-dir to find the root of the project.

If you look at helm-find function's implementation, it uses helm-find-1 for the actual call to the find utility. So you can crank up your own interactive find function:

(defun helm-find-root ()
  (interactive)
  (helm-find-1 (vc-root-dir)))

Sprinkle it up with other goodies for best results.

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.