In a documentation I saw screenshots of the tree command output like following:

enter image description here

In my case I created the filesystem like in the screenshot but in the examples, there were Files and Subfolders in all of the listed folders (Folder1, Folder3, Folder5 in the example) as well:

Real filesystem structure:

enter image description here

I know that - in this small scenario - I could use options for tree like following:

tree -I 'Folder1|Folder3|Folder5'

which would exclude those folders, but in a huge Filesystem I could exclude other subfolders with those wildcards, too.

Ergo I need a command where I can set a wildcard for special layers of the trees (-L option) and for special subdirectory paths.

The manual to tree didn't help me further (tree --help or this link).

Is this possible with tree or have those screenshots which I mentioned above been faked?

  • Which documentation are you following? I can't reproduce your first screenshot either so I'm curious. – HoD Oct 16 '15 at 8:08
  • It's not a doc of the tree command but one I am not allowed to publish here. Their is no prompt shown but just the output in the tree-structure and under the screenshot there is a reference to tree. It might be that it is impossible and just a manipulated screenshot – h0ch5tr4355 Oct 16 '15 at 8:12

Your Answer

 

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Browse other questions tagged or ask your own question.