doc: initial port of README

Signed-off-by: Brian McGee <brian@bmcgee.ie>
This commit is contained in:
Brian McGee 2024-05-03 14:15:08 +01:00
parent f5c81e64ec
commit 2c45d23bfc
Signed by: brianmcgee
GPG Key ID: D49016E76AD1E8C0

View File

@ -34,15 +34,15 @@ Its main features are:
- **Providing a unified CLI and output**
- You dont need to remember which formatters are necessary for each project.
Once you specify the formatters in the config file, you can trigger all of them with one command and get a
- Once you specify the formatters in the config file, you can trigger all of them with one command and get a
standardized output.
- **Running all the formatters in parallel**
- A standard script loops over your folders and runs each formatter
consequentially. In contrast, `treefmt` runs formatters in parallel. This way, the formatting job takes less time.
- A standard script loops over your folders and runs each formatter sequentially.
- In contrast, `treefmt` runs formatters in parallel. This way, the formatting job takes less time.
- **Tracking file changes**
- When formatters are run in a script, they process all the files they encounter, no matter
whether the code has changed. This unnecessary work can be eliminated if only the changed files are formatted.
`treefmt` caches the changed files and marks them for re-formatting.
- When formatters are run in a script, they process all the files they encounter, regardless of whether or not
they have changed.
- `treefmt` tracks file changes, and only attempts to format a files which have changed.
To reformat the whole source tree, just type `treefmt` in any folder. This is a fast and simple formatting solution.