mirror of
https://github.com/junegunn/fzf.vim.git
synced 2025-12-06 20:54:28 +08:00
Fix preview.sh not running when the file path contains "binary" (#1055)
This commit is contained in:
@@ -28,8 +28,9 @@ if [ ! -r "$FILE" ]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
FILE_LENGTH=${#FILE}
|
||||
MIME=$(file --dereference --mime "$FILE")
|
||||
if [[ "$MIME" =~ binary ]]; then
|
||||
if [[ "${MIME:FILE_LENGTH}" =~ binary ]]; then
|
||||
echo "$MIME"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user