Terminal-based typing test.

Related tags

Command-line ttyper
Overview

ttyper

Crates.io GitHub Workflow Status Dependency Status GitHub issues License

Ttyper is a terminal-based typing test built with Rust and tui-rs.

Recording

installation

With Cargo:

cargo install ttyper

usage

For usage instructions, you can run ttyper --help. Currently available languages are english100, english200, and english1000.

examples

command test contents
ttyper 50 of the 200 most common english words
ttyper -w 100 100 of the 200 most common English words
ttyper -w 100 -l english1000 100 of the 1000 most common English words
ttyper text.txt contents of text.txt split at whitespace
Comments
  • Add keywise WPM and accuracy data to the results

    Add keywise WPM and accuracy data to the results

    We would likely only show some of the worst keys so that users can know what to work on without getting a useless dump of information.

    This shouldn't be difficult to implement as the actual data is already present in the Results struct.

    enhancement good first issue 
    opened by max-niederman 6
  • [bug]

    [bug] "Worst Keys" not shown on results screen

    I am using version 0.3.1, I installed ttyper just a few hours ago, and I can't see worst keys on the results screen.

    Here is a screenshot: Screenshot 2021-12-17 at 12 15 49 AM

    Since this literally has 0% accuracy, there is no reason to not have worst keys. Even in all of my previous runs with different accuracies (varying between 80%-96%), I haven't seen anything against the worst keys column.

    Please let me know if you need me to share any system information or something. Thanks.

    opened by codelixir 5
  • an easy way to restart without refactoring the entire codebase

    an easy way to restart without refactoring the entire codebase

    Pressing Tab twice to restart (with new contents too). If you press something when you press Tab for the first time, it will exit.

    It's not a bug, it's a feature.

    opened by khanghugo 5
  • Add ability to restart the test without quitting the program

    Add ability to restart the test without quitting the program

    When testing, I often go off to a bad start and want to restart the test. Currently, I have to quit ttyper with Ctrl+C and then again start it. It'll be great if there was a shortcut like Ctrl+R to restart the test (just like refreshing the page in online browser-based tests)

    opened by MagnumDingusEdu 5
  • Add Cargo-less installation methods

    Add Cargo-less installation methods

    Ideally there should be a way to install on at least some machines without cargo. This will need an installation script to install the language files in lieu of build.rs.

    Some alternative installation methods which would be good to include are:

    • sh installation script w/ prebuilt binaries
    • AUR package

    For prebuilt binaries, it would be ideal to setup GitHub workflows or similar so that no manual work is needed.

    enhancement good first issue 
    opened by max-niederman 5
  • thread 'main' panicked at 'Error reading language file.

    thread 'main' panicked at 'Error reading language file.

    Hey, Im getting the following error since the latest update upon launching ttyper:

    thread 'main' panicked at 'Error reading language file. Make sure Luthien's config dir isn't missing.: Os { code: 2, kind: NotFound, message: "No such file or directory" }', src/main.rs:59:53
    note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
    

    The used installation method was this AUR package I created.

    enhancement 
    opened by dr460nf1r3 4
  • Don't randomize text to have real life situation

    Don't randomize text to have real life situation

    I really would like to use a real life text, like a blog article to have real sentences under real circumstances. But if I copy a text to a text file, ttyper randomizes every new line in the file.

    The reason to have real life text is that it would be much more realistic to learn real sentences and another nice thing to do are competitions, because if there is the same text, the conditions are the same for all.

    opened by therealmaxmoon 3
  • Make it colorblind friendly

    Make it colorblind friendly

    I really like ttyper The simplicity, straightforwardness, pure typing and stats at the end! Love it!

    But I have severe problems when there is a typo midway through the word. As a colorblind person, I cannot easily distinguish scales of red so well, so when the word is half yellow half green, it is very hard to distinguish where the cursor is (or even realize if a word is fully "OK" or the last character is yellow). To understand the cases that I mean, maybe you can try setting your colors to green OK and green ONGOING, it gets really tricky at the end of words especially!! Well, since I'm probably not alone here, and about 10% of the male population might have the same feeling, I'm creating this PR.

    Basically, a word will never be half green half yellow. Either fully green, half green and half blue (far enough), or fully red. But you might ask "full green or full red? isn't that a problem?". Well, generally yes. But red looks a look darker than green in full blown RGB (#ff0000 vs #00ff00). I think it has to do with humans having a lot more receptors for green than any other color ¯\(ツ)/¯, but I'm no doctor. I just know what I see 😄

    I thought this PR was simple enough, unintrusive enough, and doesn't really break the simple straightforward feel. (BTW, the extra line change was just an automatic cargo fmt) I hope this is ok with you

    opened by m-lima 3
  • for  #28

    for #28

    • change tab to the restart key when done with the test
    • escape to quit mid test will quit instantly
    • also write csv with a really unappealing name

    I leave some comments in the code so if there is anything needed to change then yea.

    Here is what the CSV file looks like. image

    opened by khanghugo 3
  • Add support for portuguese language

    Add support for portuguese language

    Hi,

    I'm a native Portuguese speaker and I use your package almost daily. I'd love to have support for my language, so I made this PR based on the most common portuguese words.

    opened by gesteves91 2
  • Exiting / Restarting Test

    Exiting / Restarting Test

    How do I exit the test without pressing ctrl+c? I am referring to when I am in the test still typing. I also would be like to restart the test before i finish it. Thank you.

    opened by bcatalfo 1
  • Add the most common 1000 and 10000 german words

    Add the most common 1000 and 10000 german words

    • Added the most common 1000 and 10000 German words (residing in resources/runtime/language/german1000 and resources/runtime/language/german10000), respectively
    • Update README to include these options
    opened by leo848 0
  • backspace deletes whole words while ctrl-backspace deletes characters

    backspace deletes whole words while ctrl-backspace deletes characters

    my terminal (uxterm) is sending ^H on backspace and ^? on ctrl-backspace i use stty erase \^H to make all programs handle backspace correctly this program doesn't seem to be doing the same

    i'm having issues trying to find proper information on how terminal character codes work but from what i can tell ^H is backspace and ^? is delete

    opened by SArpnt 0
  • Changing language directory to data directory

    Changing language directory to data directory

    Making the language directory to data seems more logical then the configuration directory.

    TODO

    If this gets accepted it might be necessary to create a function to move old language directory to the new location.

    opened by elyashivhazan 0
  • Error when .config/ttyper/language directory does not exist

    Error when .config/ttyper/language directory does not exist

    $ ttyper --list-languages
    thread 'main' panicked at 'Couldn't get installed languages under config directory.: Os { code: 2, kind: NotFound, message: "No such file or directory" }', src/main.rs:219:14
    note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
    

    The error disappears once I create $HOME/.config/ttyper/language .

    My expectation, in order of preference:

    • No error. Just display an empty list because no languages are installed (or just the included ones, see #54 )
    • A more user friendly error that explains what directory to create
    opened by omarkohl 0
Releases(v1.0.0)
Owner
Max Niederman
Hi, I'm Max.
Max Niederman
yet another typing test, but crab flavoured

toipe A trusty terminal typing tester for the tux. Usage Install cargo install toipe Run typing test toipe looks best on a nice terminal (such as Ala

Samyak Sarnayak 431 Dec 20, 2022
Coppers is a custom test harnass for Rust that measures the energy usage of your test suite.

Coppers Coppers is a test harness for Rust that can measure the evolution of power consumptions of a Rust program between different versions with the

Thijs Raymakers 175 Dec 4, 2022
✨Sleek typing tui written in rust

thokr ✨ sleek typing tui written in rust Installation Cargo $ cargo install thokr Docker $ docker run -it coloradocolby/thokr Arch Linux Install thokr

Colby Thomas 440 Dec 30, 2022
✨ sleek typing tui with visualized results and historical logging

thokr ✨ sleek typing tui with visualized results and historical logging Usage For detailed usage run thokr -h. thokr 0.4.1 sleek typing tui with visua

colby thomas 440 Dec 30, 2022
This CLI will help you improve your typing accuracy and speed

This CLI will help you improve your typing accuracy and speed! Improve your personal bests and look back on your previous records in a graph. All in the convenience of your own terminal!

Mitchel Wijt 8 May 25, 2023
Typing accuracy practice app.

booktyping booktyping is a simple commandline tool for practicing typing accuracy while reading a book. installation booktyping has only been tested o

null 3 Dec 10, 2023
create and test the style and formatting of text in your terminal applications

description: create and test the style and formatting of text in your terminal applications docs: https://docs.rs/termstyle termstyle is a library tha

Rett Berg 18 Jul 3, 2021
Test whether a given stream is a terminal

is-terminal Test whether a given stream is a terminal is-terminal is a simple utility that answers one question: Is this a terminal? A "terminal", als

Dan Gohman 19 Dec 31, 2022
Simple test app based on rust-psp

PSP Test App Simple test app based on rust-psp. Demonstrating the usage of C libs. Build Download and unzip the prebuilt PSPSDK (built from clang-psp)

Yifeng Wang 4 Nov 28, 2022
Simple grammar-based test case generator

tree-splicer tree-splicer is a simple grammar-based test case generator. It parses a number of input files using tree-sitter grammars, and produces ne

Langston Barrett 5 Mar 19, 2023
A simple, fast, and easy to use Solidity test generator based on the Branching Tree Technique.

bulloak A simple, fast, and easy to use Solidity test generator based on the Branching Tree Technique. Installing cargo install bulloak Usage Basic Us

Alexander González 38 Aug 7, 2023
A terminal ASCII media player. View images, gifs, videos, webcam, YouTube, etc.. directly in the terminal as ASCII art.

Terminal Media Player View images, videos (files or YouTube links), webcam, etc directly in the terminal as ASCII. All images you see below are just m

Max Curzi 36 May 8, 2023
ask.sh: AI terminal assistant that can read and write your terminal directly!

ask.sh: AI terminal assistant that read from & write to your terminal ask.sh is an AI terminal assistant based on OpenAI APIs such as GPT-3.5/4! What'

hmirin 5 Jun 20, 2023
A simple and efficient terminal UI implementation with ratatui.rs for getting quick insights from csv files right on the terminal

CSV-GREP csv-grep is an intuitive TUI application writting with ratatui.rs for reading, viewing and quickly analysing csv files right on the terminal.

Anthony Ezeabasili 16 Mar 10, 2024
A tui to test regexes on the rust regex crate

regex-tui Structure src/ ├── app.rs -> holds the states and renders the widgets ├── event.rs -> handles the terminal events (key press, mouse cl

null 1 Oct 21, 2021
A common library and set of test cases for transforming OSM tags to lane specifications

osm2lanes See discussion for context. This repo is currently just for starting this experiment. No license chosen yet. Structure data tests.json—tests

A/B Street 29 Nov 16, 2022
Black-box integration tests for your REST API using the Rust and its test framework

restest Black-box integration test for REST APIs in Rust. This crate provides the [assert_api] macro that allows to declaratively test, given a certai

IOmentum 10 Nov 23, 2022
Sanctity is an acronym for rust ansi16 color test utility

sanctity ?? sanctity is an acronym for rust ansi16 color test utility. It prints your own text or the default text in all of the 16 terminal colors.

null 1 Apr 6, 2022
trigger io::Error's in test, and annotate their source

fault-injection docs Similar to the try! macro or ? operator, but externally controllable to inject faults during testing. Unlike the try! macro or ?

Komora 18 Dec 16, 2022