Advertisement
Guest User

Untitled

a guest
Oct 13th, 2015
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.30 KB | None | 0 0
  1. Today I was just curious which directory holds the deepest file on my Linux PC.
  2.  
  3. The below command will print the dir with maximum depth.
  4.  
  5. >find / -type d | awk -F "/" -v slash=0 '{if (NF > slash) { slash=NF; DIR=$0}} END { print DIR":"slash}'
  6.  
  7. The result I got is 16 as max depth which was a ruby dir.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement