aboutsummaryrefslogtreecommitdiff
path: root/README.md
blob: 701f8098ccaab2d59a86e12db7a706ffa245495d (plain) (blame)
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
# ordinal

Ordinal is a command-line utility to convert cardinal numbers into ordinal ones.
It’s functionality can be summed up nicely in the two following examples:

```sh
$ seq 20 | ordinal
1st
2nd
3rd
4th
5th
6th
7th
8th
9th
10th
11th
12th
13th
14th
15th
16th
17th
18th
19th
20th
```

```sh
$ date +'%-d of %B, %Y' | ordinal -p1
4th of October, 2023
```

For more details, read the `ordinal(1)` manual page.

## Installation

Installation is very simple:

```sh
$ make
$ sudo make install
```

If you do not have `flex` installed, you probably have `lex` instead so you can
try the following:

```sh
$ make LEX=lex LFLAGS= LDLIBS=-ll
```

If the above doesn’t work, send an email over to
`~mango/public-inbox@lists.sr.ht` describing your problem.