From 6f91b67cf342c6a849b7d93d24924e80f1b7d714 Mon Sep 17 00:00:00 2001 From: Tom Ryder Date: Fri, 9 Sep 2016 21:28:10 +1200 Subject: Add rot13(6df) --- .gitignore | 1 + Makefile | 3 ++- README.markdown | 1 + games/rot13.sed | 3 +++ man/man6/rot13.6df | 20 ++++++++++++++++++++ 5 files changed, 27 insertions(+), 1 deletion(-) create mode 100755 games/rot13.sed create mode 100644 man/man6/rot13.6df diff --git a/.gitignore b/.gitignore index bab3eb65..1e9e814f 100644 --- a/.gitignore +++ b/.gitignore @@ -12,6 +12,7 @@ bin/tot bin/unf games/acq games/kvlt +games/rot13 games/zs git/gitconfig gnupg/gpg.conf diff --git a/Makefile b/Makefile index 6353688c..d8e61785 100644 --- a/Makefile +++ b/Makefile @@ -97,6 +97,7 @@ clean distclean : bin/unf \ games/acq \ games/kvlt \ + games/rot13 \ games/zs \ git/gitconfig \ gnupg/gpg.conf \ @@ -209,7 +210,7 @@ install-finger : install -pm 0644 -- finger/project "$(HOME)"/.project install -pm 0644 -- finger/pgpkey "$(HOME)"/.pgpkey -install-games : games/acq games/kvlt games/zs check-games install-games-man +install-games : games/acq games/kvlt games/rot13 games/zs check-games install-games-man install -m 0755 -d -- "$(HOME)"/.local/games for name in games/* ; do \ [ -x "$$name" ] || continue ; \ diff --git a/README.markdown b/README.markdown index 2d943a9e..5b833ad8 100644 --- a/README.markdown +++ b/README.markdown @@ -476,6 +476,7 @@ There's some silly stuff in `install-games`: * `kvlt(6df)` translates input to emulate a style of typing unique to black metal communities on the internet. * `rndn(6df)` implements an esoteric random number generation algorithm. +* `rot13(6df)` rotates the Latin letters in its input. * `xyzzy(6df)` teleports to a marked location on the filesystem. * `zs(6df)` prepends "z" case-appropriately to every occurrence of "s" in the text on its standard input. diff --git a/games/rot13.sed b/games/rot13.sed new file mode 100755 index 00000000..7fb8fac9 --- /dev/null +++ b/games/rot13.sed @@ -0,0 +1,3 @@ +# Latin ROT-13 cipher +y/abcdefghijklmnopqrstuvwxyz/nopqrstuvwxyzabcdefghijklm/ +y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/NOPQRSTUVWXYZABCDEFGHIJKLM/ diff --git a/man/man6/rot13.6df b/man/man6/rot13.6df new file mode 100644 index 00000000..9856e61c --- /dev/null +++ b/man/man6/rot13.6df @@ -0,0 +1,20 @@ +.TH ROT13 6df "September 2016" "Manual page for rot13" +.SH NAME +.B rot13 +\- Latin ROT13 cipher +.SH USAGE +.B rot13 +.br +.B rot13 +file +.br +.B rot13 +file1 file2 file3 +.br +.B rot13 < file +.SH DESCRIPTION +.B rot13 +implements the ROT13 Caesar cipher for the Latin letters with sed(1), both +upper and lowercase. +.SH AUTHORS +Tom Ryder -- cgit v1.2.3