Tree (command) explained
tree |
Developer: | Steve Baker, DR, Microsoft, IBM, Itautec, Datalight, Toshiba, Dave Dunfield, Asif Bahrainwala |
Programming Language: | Unix-like, FreeDOS, ReactOS: C |
Operating System: | Unix, Unix-like, MS-DOS, PC DOS, FlexOS, SISNE plus, ROM-DOS, 4690 OS, PTS-DOS, OS/2, eComStation, ArcaOS, Windows, DR DOS, FreeDOS, ReactOS |
Platform: | Cross-platform |
Genre: | Command |
License: | Unix, Unix-like, FreeDOS, ReactOS: GPLv2 |
In computing, tree
is a recursive directory listing command or program that produces a depth-indented listing of files. Originating in PC- and MS-DOS, it is found in Digital Research FlexOS,[1] IBM/Toshiba 4690 OS,[2] PTS-DOS,[3] FreeDOS,[4] IBM OS/2,[5] Microsoft Windows,[6] and ReactOS. A version for Unix and Unix-like systems is also available.
The tree
command is frequently used as part of a technical support scam, where the command is used to occupy the command prompt screen, while the scammer, pretending to be technical support, types additional text that is supposed to look like output of the command.[7]
Overview
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.
The command is available in MS-DOS versions 3.2 and later and IBM PC DOS releases 2 and later.[8] Digital Research DR DOS 6.0,[9] Itautec SISNE plus,[10] and Datalight ROM-DOS[11] include an implementation of the command.
The Tree Command for Linux was developed by Steve Baker.[12] The FreeDOS version was developed by Dave Dunfield[13] and the ReactOS version was developed by Asif Bahrainwala. All three implementations are licensed under the GNU General Public License.
The Tree command is also available in macOS as a formula installed via the command line Homebrew package manager.[14]
Example
$ tree path/to/folder/path/to/folder/├── a-first.html├── b-second.html├── subfolder│ ├── readme.html│ ├── code.cpp│ └── code.h└── z-last-file.html
1 directories, 6 files
See also
Further reading
- Book: Cooper. Jim. Special Edition Using MS-DOS 6.22, Third Edition. 2001. Que Publishing. 978-0789725738.
- Book: Kathy Ivens. Brian Proffit. 1993. OS/2 Inside & Out. Osborne McGraw-Hill. 978-0078818714.
- Book: John Paul Mueller. 2007. Windows Administration at the Command Line for Windows Vista, Windows 2003, Windows XP, and Windows 2000. John Wiley & Sons. 978-0470165799.
External links
Notes and References
- Book: FlexOS User's Guide. Version 1.3. November 1986. Digital Research. 1073-2003-001. 2018-09-16. 2019-09-25. https://web.archive.org/web/20190925131719/http://bitsavers.org/pdf/digitalResearch/flexos/1073-2003_FlexOS_Users_Guide_V1.3_Nov86.pdf. dead.
- https://archive.org/details/4690OSV6r2UsersGuide/page/n169
- Web site: PTS-DOS 2000 Pro User Manual . . Buggingen, Germany . 1999 . 2018-05-12 . live . https://web.archive.org/web/20180512094512/http://download.paragon-software.com/doc/manual_dos_eng.pdf . 2018-05-12.
- Web site: FreeDOS group -- FreeDOS Base. FreeDOS on ibiblio.org.
- Web site: JaTomes Help - OS/2 Commands. 2019-07-27. 2019-04-14. https://web.archive.org/web/20190414130029/http://www.jatomes.com/Help/Os2Cmd.php#TREE. dead.
- Web site: Tree. Microsoft Docs. 3 February 2023 .
- Web site: The World of the Technical Support Scam. 2016-11-09. The State of Security. en-US. 2019-12-29.
- Book: Wolverton. Van. Running MS-DOS Version 6.22 (20th Anniversary Edition), 6th Revised edition. 2003. Microsoft Press. 0-7356-1812-7.
- https://www.4corn.co.uk/archive/docs/DR%20DOS%206.0%20User%20Guide-opt.pdf DR DOS 6.0 User Guide Optimisation and Configuration Tips
- Web site: Itautec . Itautec . 2015-05-14 . SISNE plus - Referência Sumária . SISNE plus - Quick Reference Manual . live . https://web.archive.org/web/20190928211058/https://datassette.org/manuais/ibm-pc/sisne-plus-referencia-sumaria . 2019-09-28 . 2020-01-12 . Datassette . pt . COD 23987-01-4. https://web.archive.org/web/20190928211109/http://files3.datassette.org/manuais/sisne_plus_referencia_sumaria.pdf (86 pages)
- Web site: Datalight ROM-DOS User's Guide. www.datalight.com.
- Web site: Baker . Steve . Home - Old Man Programmer . 2024-01-26.
- Web site: FreeDOS Package -- Tree (FreeDOS Base). FreeDOS on ibiblio.org.
- Web site: Homebrew - Tree (Formala). Homebrew. 2024-05-14.