Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reducing absolut path length in fzf match #4

Open
aMOPel opened this issue Apr 16, 2021 · 5 comments
Open

Reducing absolut path length in fzf match #4

aMOPel opened this issue Apr 16, 2021 · 5 comments
Assignees
Labels
enhancement New feature or request

Comments

@aMOPel
Copy link

aMOPel commented Apr 16, 2021

/home/user/work/project/src/file.end

To
Either compression of the first few
~/w/p/src/file.end
Or a max length
...roject/src/file.end
Or some mix, where either is appropriate

@LoricAndre LoricAndre self-assigned this Apr 16, 2021
@LoricAndre LoricAndre added the enhancement New feature or request label Apr 16, 2021
@LoricAndre
Copy link
Owner

Honestly this is a lot of work and I'm not sure I'll do it... Right now I can just take the output from fzf (I still modify it a bit but it's minimal), but by adding that I have to shorten the paths then expanding them afterwards, which means controlling that they are unique and I can already see the next issues...
I'm leaving the issue open but I don't think I'll work on it unless there is a real need

@aMOPel
Copy link
Author

aMOPel commented Apr 17, 2021

i mean cant you make a map or 2 parallel arrays or smth, one where you have your nice expanded paths, and one where you have the reduced paths, and you pipe that one into the term and keep the other one, and afterwards you can identify the right expanded path by some id or the array index?

@LoricAndre
Copy link
Owner

This would require a refactor, right now I'm pretty much just piping the result from fzf into neovim

@aMOPel
Copy link
Author

aMOPel commented Apr 17, 2021

i see, is that why you also dont want to add highlighting to the lines in fzf?

@LoricAndre
Copy link
Owner

Yes basically, I'll see if I can work on this next week

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants