DTREE(1) BSD General Commands Manual DTREE(1)
NAME
dtree -- Command line program to draw trees
SYNOPSIS
dtree [-hv]
dtree [-s set] [file]
DESCRIPTION
dtree is a simple command line program which reads a number of lines and
formats them as a tree using line drawing characters in several sets.
Each input line represents one node in a tree. The number of tabs at the
start of each input line determines the nesting level of that node. It
is intended for the root node to have no tabs at the start.
If the file is omitted, dtree will read from stdin. Any additional argu-
ments after file will be ignored.
Command line options
dtree -h Prints usage information.
dtree -s set
Selects the symbol set set. Allowed values for set are:
a (ASCII set), d (double-stroke set), and s (sin-
gle-stroke set, default).
dtree -v Prints version and commit date.
EXAMPLES
Format a tree using double-stroke box drawing characters:
printf "A\n\tB\n\t\tC\n\tD\n" | dtree -sd
tree(1) replacement:
find . -print | sed -E "s,[^/]+/,$(printf '\t'),g" | dtree
same, using ASCII characters:
find . -print | sed -E "s,[^/]+/,$(printf '\t'),g" | dtree -sa
SEE ALSO
tree(1)
AUTHORS
Strahinya Radich <contact@strahinja.org>, 2023
BSD October 02, 2023 BSD