reddit / emacs

tree/directory package that only shows certain directory?

maxle0312 · 2022-06-29 10:07
Hi all, I am using treemacs to display my directories in a big project. I have treemacs spawned on the left window, then everything else belong to that directory can be launched on the right window, i.e. you press Enter on treemacs and it opens on the right. This works but whenever I need to open up another file in a different directory, treemacs automatically change its path. Eg. say I have treemacs open ~/myproject folder: I achieve this by open a file in ~/myproject and then launch treemacs. Now, if I open a different file in a different directory like ~/Desktop **and** my cursor is on that file, treemacs will then show whatever I have in ~/Desktop. Of course, if I focus my cursor on the file in ~/myproject, treemacs will show my project stuff again. This flickering is quite distracting with big project, and sometimes you just want to open a random unrelated file. Is there a different tree app or a settings in treemacs that does this? Please let me know.
columbcille · 2022-06-29 12:24
I was looking into same question and heard about persp-mode as a way to set perspectives. Haven’t tried it yet. https://github.com/Bad-ptr/persp-mode.el
Nippurdelagash · 2022-06-29 13:47
Have you tried disabling `treemacs-follow-mode` ?
deaddyfreddy · 2022-06-29 15:44
`M-x dired-jump`