rosshemsley / iOpener

Open files from path, with completion, listings and history. Similar to Emacs find file.
GNU General Public License v2.0
55 stars 19 forks source link

absolute path at end of current path should find existing dir #30

Open michaeldurland opened 8 years ago

michaeldurland commented 8 years ago

Hi, I love iOpener! I have a small enhancement request: If I enter an absolute path at the end of the current path, then it should resolve to the new path instead of trying to append to the existing path. e.g. I hit ctrl+o and get: /data/projects/my_project/ which is where the current file is located. So far so good. Now I want to open a file in my home directory, say my .bashrc file. I want to be able to type it right at the iOpener prompt like this: /data/projects/my_project/~/.bashrc But iOpener thinks this path doesn't exist, well, because it doesn't exist. The enhancement is to recognize when an absolute path is being entered and trigger resolving to just that path instead of trying to use the entire path in the prompt. So the above should resolve to just "~/.bashrc" and be able to find an open the file. Currently I have to backspace over the existing path to enter the absolute path I want. Same for non-home directories. e.g. start with: /data/projects/my_project/ and type at the end to get: /data/projects/my_project//tools/config/my_file.cfg should resolve to just "/tools/config/my_file.cfg". The tab key should do the resolution too to prompt files in the new directory. e.g.: /data/projects/my_project//tools/config/ should prompt to show files in the /tools/config directory. Thanks! Michael

DeeeeLAN commented 5 years ago

I am interested in this enhancement as well. Emacs behaves by ignoring the previous path if it finds // or /~ in the entry field.

DeeeeLAN commented 5 years ago

Fixed in #36 if it ever gets merged.