6 How to run it
Read the tutorial. Build it yourself is the other way to read this part.
just setupA new user of tally does not know which commands to run, or in which order. The README gets a section, "Run it", that says how to run tally, its tests and its report. The code does not change.
A patch to README.md.
At the end of README.md, the new section "Run it" gives the two commands to run first, just setup and then
tally on the corpus. Under them, it names the option --top, the tests and the report.
uv run tally --top 3 data/corpus.txt
just testThe command prints the three most common words of the corpus, and the tests pass. tally is finished.
What changed
README.md: the commands that a new user needs first, in the order to run them. 10 lines added. The file.- look at
## Run it
- look at
The diff of README.md
@@ -1,3 +1,13 @@
# tally
Count the words in a text.
+
+## Run it
+
+Make the environment, the corpus and the report first. Then count the words of a file:
+
+ just setup
+ uv run tally data/corpus.txt
+
+`uv run tally --top 10 data/corpus.txt` prints only the ten most common words. `just test` runs the tests, and
+`just report` writes the ten most common words of the corpus to `build/top.txt`.