summaryrefslogtreecommitdiff
path: root/README.md
blob: f5da09082e298fbf572c21c86d11e6a6de0739c4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
# spreed - speed reader

`spreed` is a simple speed reader.

# Usage

`spreed` reads plain text from stdin with a default speed of 250 WPM.

## Calling

```sh
echo "this is some test text." | spreed
```

```sh
spreed < text.txt
```

## Options

WPM may be set in one of two ways:

env:
```sh
env SPREED_WPM=400 spreed < text.txt
```

argument:
```sh
spreed 400 < text.txt
```

Note: Argument takes precedence over environment variable.

## Quirks

`spreed` attempts to pause at the end of a sentence.
This word should stay visible for twice as long as normal words.

# Limitations

- WPM is hard-coded to not exceed 1800.
 - This was chosen arbitrarily.
 - The program could certainly handle faster, however 1800 WPM is 30fps.
 - If you have a use-case requiring >1800 WPM, please submit a patch with an explanation and I will review.
- Does __*not*__ handle anything other than plain text (no pdf, epub, etc).
- Writes 48 columns wide
 - There are ~10 columns of padding at the start of the line.
 - Words longer than the remaining ~37 characters will be split between multiple lines.
- Preliminary support for languages other than English
 - May not behave as expected, especially in regards to punctuation.
- May not behave as expected on 32-bit systems (untested).

# Installation

Generate and edit config.h to customize program settings.

```sh
make config.h
```

Default installation is to `/usr/local/bin/spreed`

To install to a custom location (e.g. $HOME/.bin), do:
```sh
make clean install BIN=.bin DESTDIR=$HOME PREFIX=
```