diff options
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | Makefile | 1 | ||||
-rw-r--r-- | README.markdown | 2 | ||||
-rw-r--r-- | bin/p.sh | 1 | ||||
-rw-r--r-- | man/man1/p.1df | 27 |
5 files changed, 32 insertions, 0 deletions
@@ -63,6 +63,7 @@ bin/mw bin/nlbr bin/onl bin/osc +bin/p bin/pa bin/paz bin/ped @@ -141,6 +141,7 @@ BINS = bin/ap \ bin/ped \ bin/pit \ bin/plmu \ + bin/p \ bin/pp \ bin/pph \ bin/pst \ diff --git a/README.markdown b/README.markdown index 6b0ff38e..c35d3790 100644 --- a/README.markdown +++ b/README.markdown @@ -507,6 +507,8 @@ Installed by the `install-bin` target: * `onl(1df)` crunches input down to one printable line. * `osc(1df)` implements a `netcat(1)`-like wrapper for `openssl(1)`'s `s_client` subcommand. +* `p(1df)` prints concatenated standard input; `cat(1)` as it should always + have been * `pa(1df)` prints its arguments, one per line. * `pp(1df)` prints the full path of each argument using `$PWD`. * `pph(1df)` runs `pp(1df)` and includes a leading `$HOSTNAME:`. diff --git a/bin/p.sh b/bin/p.sh new file mode 100644 index 00000000..5b59986e --- /dev/null +++ b/bin/p.sh @@ -0,0 +1 @@ +exec cat -- "${@:--}" diff --git a/man/man1/p.1df b/man/man1/p.1df new file mode 100644 index 00000000..2d291fc1 --- /dev/null +++ b/man/man1/p.1df @@ -0,0 +1,27 @@ +.TH P 1df "May 2017" "Manual page for p" +.SH NAME +.B p +\- print standard input to standard output +.SH SYNOPSIS +.B p +FILE1 [FILE2...] +.br +prog1 | +.B +p +.br +prog1 | +.B +p +FILE1 - FILE2 +.SH DESCRIPTION +.B p +prints concatenated standard input from files to, and nothing else; cat(1) as +it always should have been--no flags, and hence no need for end-of-options for +filenames that start with a dash. +.P +Quicker to type, too. +.SH SEE ALSO +cat(1) +.SH AUTHOR +Tom Ryder <tom@sanctum.geek.nz> |