tree (command)

From Wikipedia, the free encyclopedia
Jump to navigation Jump to search

Developer(s)Steve Baker, Digital Research, Microsoft, IBM, Dave Dunfield
Operating systemUnix, Unix-like, MS-DOS, FlexOS, 4690 OS, PTS-DOS, FreeDOS, OS/2, Microsoft Windows, ReactOS

In computing, tree is a recursive directory listing command or program that produces a depth-indented listing of files. It is available in Unix and Unix-like systems, as well as MS-DOS, FlexOS[1], 4690 OS[2], PTS-DOS,[3] FreeDOS[4], OS/2, Microsoft Windows[5], and ReactOS.


With no arguments, tree lists the files in the current directory. When directory arguments are given, tree lists all the files or directories found in the given directories each in turn. Upon completion of listing all files and directories found, tree returns the total number of files and directories listed. There are options to change the characters used in the output, and to use color output.[6]

The Tree Unix utility was developed by Steve Baker.[7] The FreeDOS version was developed by Dave Dunfield.[8]


$ tree path/to/folder/
├── a-first.html
├── b-second.txt
├── subfolder
│   ├── readme.txt
│   ├── code.cpp
│   └── code.h
└── z-last-file.txt

1 directories, 6 files

See also[edit]


  1. ^
  2. ^
  3. ^ "PTS-DOS 2000 Pro User Manual" (PDF). Buggingen, Germany: Paragon Technology GmbH. 1999. Archived (PDF) from the original on 2018-05-12. Retrieved 2018-05-12.
  4. ^
  5. ^
  6. ^ "tree(1) - Linux man page". Linux man pages. Retrieved February 22, 2017.
  7. ^ Steve Baker. "The Tree Command for Linux Homepage". Center for Biological Computing, Indiana State University Department of Life Sciences.
  8. ^

External links[edit]