Guest User

Untitled

a guest
Dec 19th, 2018
100
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.60 KB | None | 0 0
  1. find . -path '*/*/*' -prune -o -type d -print
  2.  
  3. find . ( -name . -o -prune ) -extra-conditions-and-actions
  4.  
  5. find . ! -name . -prune -extra-conditions-and-actions
  6.  
  7. find . ( ! -path './*/*' -o -prune ) -extra-conditions-and-actions
  8.  
  9. $ locale charmap
  10. UTF-8
  11. $ find . -maxdepth 2
  12. .
  13. ./St?phane
  14. ./St?phane/Chazelas
  15. ./Stéphane
  16. ./Stéphane/Chazelas
  17. ./John
  18. ./John/Smith
  19. $ find . ( ! -path './*/*' -o -prune )
  20. .
  21. ./St?phane
  22. ./St?phane/Chazelas
  23. ./St?phane/Chazelas/age
  24. ./St?phane/Chazelas/gender
  25. ./St?phane/Chazelas/address
  26. ./Stéphane
  27. ./Stéphane/Chazelas
  28. ./John
  29. ./John/Smith
  30.  
  31. LC_ALL=C find . ( ! -path './*/*' -o -prune ) -extra-conditions-and-actions
  32.  
  33. $ LC_ALL=C find . ( ! -path './*/*' -o -prune )
  34. .
  35. ./St?phane
  36. ./St?phane/Chazelas
  37. ./St??phane
  38. ./St??phane/Chazelas
  39. ./John
  40. ./John/Smith
  41.  
  42. find some/dir/. ! -name . -prune ...
  43.  
  44. find some/dir/. ( ! -path '*/./*/*' -o -prune ) ...
  45.  
  46. (cd -P -- "$dir" && find . ...)
  47.  
  48. find . -condition1 -action1 -condition2 -action2
  49.  
  50. find . -contition1 -action1 -o -condition2 -action2
  51.  
  52. find . ( ! -condition1 -o -action1 ) -condition2 -action2
  53.  
  54. $ find dir1 dir2 -name myfile -maxdepth 1
  55.  
  56. -regex '(<list of paths | delimited>)/<filename>'
  57.  
  58. $ find dir1 dir2 -name myfile -regextype awk -regex '(dir1|dir2)/myfile' # GNU
  59. $ find -E dir1 dir2 -name myfile -regex '(dir1|dir2)/myfile' # MacOS BSD
  60.  
  61. $ find dir1 dir2 -name myfile -maxdepth 1 # GNU
  62.  
  63. -regex '(<list of paths | delimited>)/<anything that's not a slash>$'
  64.  
  65. $ find dir1 dir2 -name myfile -regextype awk -regex '(dir1|dir2)/[^/]*$' # GNU
  66. $ find -E dir1 dir2 -name myfile -regex '(dir1|dir2)/[^/]*$' # MacOS BSD
Add Comment
Please, Sign In to add comment