My build of nnn with minor changes
選択できるのは25トピックまでです。 トピックは、先頭が英数字で、英数字とダッシュ('-')を使用した35文字以内のものにしてください。

fzopen 431 B

1234567891011121314151617
  1. #!/usr/bin/env sh
  2. # Description: Fuzzy find a file in directory subtree with fzy
  3. # Opens in $VISUAL or $EDITOR if text
  4. # Opens other type of files with xdg-open
  5. #
  6. # Shell: POSIX compliant
  7. # Author: Arun Prakash Jana
  8. entry="$(find . -type f 2>/dev/null | fzy)"
  9. case "$(file -biL "$entry")" in
  10. *text*)
  11. "${VISUAL:-$EDITOR}" "$entry" ;;
  12. *)
  13. xdg-open "$entry" >/dev/null 2>&1 ;;
  14. esac