5 replies
December 2023

RicRax

Hello! I am having this problem with fzf_cd whenever i cd:

ind: unknown predicate -LE' shortest: command not found in command substitution called on line 32 of file ~/.config/fish/functions/fcd_ffmark.fish in function 'fcd_ffmark' with arguments 'A1' in command substitution in function '__fuzzy_cd_chdir' with arguments 'A1' in function 'cd' with arguments 'A1' ~/.config/fish/functions/fcd_ffmark.fish (line 32): Unknown command set found (shortest $results) ^~~~~~~~~~~~~~~~~~^ in function 'fcd_ffmark' with arguments 'A1' in command substitution in function '__fuzzy_cd_chdir' with arguments 'A1' in function 'cd' with arguments 'A1' find: unknown predicate -LE’
shortest: command not found
in command substitution
called on line 40 of file ~/.config/fish/functions/fcd_ffmark.fish
in function ‘fcd_ffmark’ with arguments ‘A1’
in command substitution
in function ‘__fuzzy_cd_chdir’ with arguments ‘A1’
in function ‘cd’ with arguments ‘A1’
~/.config/fish/functions/fcd_ffmark.fish (line 40): Unknown command
set found (shortest $results)
^~~~~~~~~~~~~~~~~~^
in function ‘fcd_ffmark’ with arguments ‘A1’
in command substitution
in function ‘__fuzzy_cd_chdir’ with arguments ‘A1’
in function ‘cd’ with arguments ‘A1’

could you offer any help maybe? thank you!

1 reply
December 2023 ▶ RicRax

ttscoff BrettTerpstra.com Supporter

You need the helper function shortest which is in a separate file. Did you install using fisher/omf, or did you drop the function in from the repo?

December 2023

RicRax

I installed it trough fisher. I saw that on the fisher version the file is called differently, so I changed it. However it’s giving me an error when calling the find function in the fcd_ffmar.fish here “set -l results (find -LE -s “$MARKPATH” -iregex “$MARKPATH/$regex” -type d -maxdepth 1 | head -n 1 | tr -d “\n”)”

It says there is no flag -LE and -s

December 2023

RicRax

I looked into it and apparently, those flags only exist on the macOS version of the find function, not on the linux version ( I am using Linux mint). I am not a scripting expert, would you maybe know how to substitute the flags to make it work on linux too?

1 reply
December 2023 ▶ RicRax

ttscoff BrettTerpstra.com Supporter

-L follows symlinks, which would be vital if you were using it to work with jump. And -E should probably exist on the linux version, it causes the expression to be interpreted as regex. I’ve never tested it on anything but Mac, so not sure what all would need to be replaced.