Skip to content

πŸ—ƒ Branching Out the Linux Way. A Bash script to output a detailed directory tree.

License

Notifications You must be signed in to change notification settings

apple-fritter/DirecTree

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

3 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

DirecTree

This script recursively traverses through a specified directory (or defaults to / if no directory is provided) and generates a file tree representation using Unicode characters to depict the hierarchy.

The generated file tree is output to a text file named tree.txt, which is saved in the same directory as the script.

Usage

Clone the repository:

git clone https://github.com/apple-fritter/DirecTree.git

Navigate to the project directory:

cd DirecTree

Run the script:

./tree.sh

If you want to specify a different directory, you can provide the path as an argument:

./tree.sh /path/to/directory

The file tree will be generated, and a file named tree.txt will be created in the same directory as the script.

Example Output

Below is an example output generated by the script:

. (current directory)
β”œβ”€β”€β”€ documents
β”‚   β”œβ”€β”€β”€ text_documents
β”‚   β”‚   β”œβ”€β”€β”€ notes.txt
β”‚   β”‚   └─── draft.txt
β”‚   └─── spreadsheets
β”‚       β”œβ”€β”€β”€ budget.xlsx
β”‚       └─── expenses.xlsx
└─── pictures
    β”œβ”€β”€β”€ vacation
    β”‚   β”œβ”€β”€β”€ beach.jpg
    β”‚   └─── mountains.jpg
    β”œβ”€β”€β”€ family
    β”‚   β”œβ”€β”€β”€ reunion.jpg
    β”‚   └─── wedding.jpg
    └─── pets
        β”œβ”€β”€β”€ cat.jpg
        └─── dog.jpg

This software is provided "as is" and without warranty of any kind, express or implied, including but not limited to the warranties of merchantability, fitness for a particular purpose and noninfringement. In no event shall the authors or copyright holders be liable for any claim, damages or other liability, whether in an action of contract, tort or otherwise, arising from, out of or in connection with the software or the use or other dealings in the software.

The authors do not endorse or support any harmful or malicious activities that may be carried out with the software. It is the user's responsibility to ensure that their use of the software complies with all applicable laws and regulations.

License

These files released under the MIT License.

About

πŸ—ƒ Branching Out the Linux Way. A Bash script to output a detailed directory tree.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages