_Fasttyper_ is minimalistic typing test based on user provided exercising text. It supports both reading from text files and stdin supporting wide range of usecases. The goal was to create it as simple as it can be, without any additional bloatware functionalities. That means that _Fasttyper_ doesn't come with build in test generator and you have to provide your own scripts generating tests. Some examples of such scrips are providen in [Usage section](#usage).
With installation of fasttyper you should have new executable - `fasttyper`. It takes two optional positional arguments, amount of words and language (like in [Monkeytype's](https://github.com/Miodec/monkeytype): english, english_1k etc). Default amount of words is 25 and language is english. To run fasttyper simply call:
Fasttyper by default looks for config file in: `$HOME/.config/fasttyper/config.json`. You can provide different location for config file with `--config` argument, for example: `--config=~/.fasttyper.json`. Config has to be a json dict. Avalibe keys:
- **user_input_valid_color** - integer, terminal color for valid text, by default it is 3
- **user_input_invalid_color** - integer, terminal color for invalid text, by default it is 2
- **reference_text_color** - integer, terminal color for reference text, by default it is 8
- **stats_color** - integer, terminal color for stats text, by default it is 5
- **summary_datafile** - datafile storing all stats, by default it is ~/.cache/fasttyper/datafile.csv
- **top_margin_percentage** - integer, percentage of screen used for top margin, by default 30
- **left_margin_percentage** - integer, percentage of screen used for left (and right) margin, by default 10
- **lines_on_screen** - integer, number of lines to display on screen, by default 3
Program also allows user to pipe text into it. Keep in mind, it only supports spaces and new line characters, so you won't be able to table tabs. For example, you can run _Fasttyper_ on fortune generated quote changing tabulators to spaces with sed:
You can use another similar projects set of words as well, for example to create test with 20 random words from [Monkeytype's](https://github.com/Miodec/monkeytype) english 100 dictionary use:
To exit you can either finish test, use `KeyboardInterrupt` (CTRL+C) or tap **tab**. After you finish test, there will be summary printed, use enter to exit from it.
Some terminal emulators send different values for key presses of backspace and ctrl+backspace. To fix it, simply add `b` flag like that: `python3 -m fasttyper -b`.
# Hiding cursor
To hide the cursor, simply add `n` flag like that: `python3 -m fasttyper -n`.
This shell function shuffles N words from cached word list, and if given word list doesnt exist it download's it. It runs in loop, but does exit from it if you exit fasttyper with CTRL+C.