metalx1000

fzf example usage

Jun 1st, 2020
2,014
2
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 1.20 KB | None | 2 0
  1. #get files to work with
  2. wget -r "https://filmsbykris.com/scripts/2020/"
  3.  
  4. apt install fzf
  5. # or
  6. apt install git
  7. git clone --depth 1 https://github.com/junegunn/fzf.git ~/.fzf
  8. ~/.fzf/install
  9.  
  10. #list file
  11. fzf
  12.  
  13. #cat file
  14. cat "$(fzf)"
  15.  
  16. #find people info
  17. wget "https://filmsbykris.com/scripts/2020/people.txt"
  18. cat people.txt|fzf
  19. cat people.txt|fzf|cut -f3,5,8
  20. cat people.txt|fzf -m|cut -f3,5,8
  21.  
  22. #direct from website
  23. wget -qO- "https://filmsbykris.com/scripts/2020/employee.lst"|fzf|cut -d\| -f2
  24. wget -qO- "https://filmsbykris.com/scripts/2020/employee.lst"|fzf -m --prompt "Select Crew: "|cut -d\| -f2
  25.  
  26. apt install tmux
  27. tmux
  28. wget -qO- "https://filmsbykris.com/scripts/2020/employee.lst"|fzf-tmux -d 35% -m --prompt "Select Crew: "|cut -d\| -f2
  29.  
  30. #use to clipboard
  31. #code: https://pastebin.com/4haxFWPW
  32.  
  33. #fake email example
  34. clear;wget -qO- "https://filmsbykris.com/scripts/2020/auth.txt";read
  35.  
  36. #show vim buffer and file search
  37.  
  38. #use it as a menu for scripts
  39. echo -e "John\nJack\nJames\nSara\nSam"|fzf
  40. #in a script:
  41. https://filmsbykris.com/scripts/2020/fzf-names.sh
  42.  
  43. #use as a menu of functions in a script
  44. https://filmsbykris.com/scripts/2020/fzf-menu-example.sh
  45.  
  46. #show books and o for opening files
Add Comment
Please, Sign In to add comment