|0.2.0||Oct 9, 2021|
|0.1.0||Oct 9, 2021|
#885 in Command line utilities
Lear is a command line “utility” that you can use to amuse yourself and your friends. Whenever you mistype
clear into the terminal,
lear will dutifully print out a passage from everyone’s favorite tragedy about a mad king.
To get started, type
lear into the console (preferably by accident).
To print a specific passage, use the
quote subcommand. It accepts the act, scene, starting line, and ending line as positional arguments. This example quotes lines 7–8 from Act 3, Scene 3.
$ lear quote 3 3 7 8 EDMUND Most savage and unnatural! GLOUCESTER Go to; say you nothing. There's a division betwixt ... (Lr. 3.3.7-8)
You can use the
contents command to print a table of contents, which will show you which acts and scenes are available, as well as how many lines they contain.
$ lear contents Act Scene Lines ------------------- 1 1 332 2 191 3 27 ...
If you have
cargo installed on your machine already,
lear can be installed with
$ cargo install lear
A homebrew installation is hopefully coming soon.
If you would like to contribute to this tool, please open an issue or submit a pull request