ajeetdsouza / zoxide

A smarter cd command. Supports all major shells.
MIT License
20.54k stars 523 forks source link

.fzf/install fails if previous installation .bashrc changes are just commented out #669

Closed ssteinerx closed 5 months ago

ssteinerx commented 6 months ago

I was reinstalling fzf after deciding my package manager's version was too far out of date.

I had just commented out the .bashrc changes like so:

#  This is a note about the fact that I commented out fzf to reinstall from a git checkout - [ -f ~/.fzf.bash ] && source ~/.fzf.bash

When running ~/.fzf/install again, I got the message:

 - [ -f ~/.fzf.bash ] && source ~/.fzf.bash
    - Already exists: line #189 

Unfortunately, the message was correct, but it only searched for the text and didn't check to see that it wasn't commented out leaving it commented out and fzf not "installed" since the fzf executable wasn't linked into $PATH, completion not loaded, and key bindings not set.

I looked at append_line() in the install script and determined that attempting to submit a fix would be counterproductive.

ajeetdsouza commented 5 months ago

This seems to be an issue with fzf, please post it on their issue tracker.

ssteinerx commented 5 months ago

Sorry about that. I ended up in the wrong place, my apologies.