File tree Expand file tree Collapse file tree 2 files changed +26
-0
lines changed Expand file tree Collapse file tree 2 files changed +26
-0
lines changed Original file line number Diff line number Diff line change 1+ root = true
2+
3+ [* ]
4+ indent_style = space
5+ indent_size = 4
6+ charset = utf-8
7+ trim_trailing_whitespace = true
8+ insert_final_newline = true
Original file line number Diff line number Diff line change @@ -10,3 +10,21 @@ CLI tools for managing output formatting
1010
1111Have formatters that I can re-use in projects to format errors.
1212Some code is copied from phpstan. See [ #4122 ] ( https://github.com/phpstan/phpstan/issues/4122 )
13+
14+ ## Example usages
15+
16+ ### Read/Write files
17+
18+ ``` php
19+ use CodeLts\CliTools\File\FileReader;
20+ use CodeLts\CliTools\File\FileWriter;
21+
22+ $fileName = 'myFile.txt';
23+
24+ FileWriter::write(
25+ $fileName,
26+ 'the contents of your file'
27+ );
28+
29+ FileReader::read($fileName);// -> the contents of your file
30+ ```
You can’t perform that action at this time.
0 commit comments