Create TreeScript from a Text file that contains tree-like file information.
Project description
Treescriptify-Text
Convert a File containing Tree-like information into TreeScript!
How To Use
Run the main script with a file name as the first positional argument.
treescriptify-text <file-name>
The output is printed to standard out (displayed in the command line output).
What you can do with this
- Pipe the output to a file.
- Copy the output and paste it where you need to.
- Look at it to get a clear picture of your directory tree.
How To Install
You can manually install a release (if you want), or use pip.
pip install treescriptify-text
Types of Valid Input
This will work on commonly encountered tree-like text, such as that produced by the tree command.
It doesn't do anything special to decode the input.
- Infers depth in the tree using the amount of indentation before the file name
- Infers parent directory from depth
Additional Considerations
If a name in the tree does not contain a file extension, and there is no slash character, it may still be treated as a directory.
Issues and Contributions
If you encounter a tree-like input that is reasonable and should be handled correctly but isn't, please provide the tree-like input in a new issue.
To improve the speed of resolving your issue, provide one or more test cases that demonstrate the failure. Use the existing test cases as a baseline for how to structure your tests.
Most Importantly
Enjoy using Treescriptify-Text and feel good every time that it works for you.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file treescriptify_text-0.3.tar.gz
.
File metadata
- Download URL: treescriptify_text-0.3.tar.gz
- Upload date:
- Size: 19.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.0.0 CPython/3.12.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4c6f99834052c6f4d0108ef52bc817d5b8a18f86410b1e77fe6c7da50272fc6b |
|
MD5 | 17f0477196d872f5c473d182ae25f0b3 |
|
BLAKE2b-256 | f85cf1164991dd90a23567aec5702d37750a4a1f0502e4d6717cad5cd757ef7a |
File details
Details for the file treescriptify_text-0.3-py3-none-any.whl
.
File metadata
- Download URL: treescriptify_text-0.3-py3-none-any.whl
- Upload date:
- Size: 19.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.0.0 CPython/3.12.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 67aa56e184545867ac6387ed0215ff8d736d4cb54495766d53d6bded705b0224 |
|
MD5 | 32906e7766c2b04a7d8c5c92f508965c |
|
BLAKE2b-256 | 2543bd72b7fa7fd7f19f6137906ddbd1dad18b22616c446548005b815ac1f108 |