forked from adolfopa/miscutils
Delete rr script
Use instead `rr` in the `kshutils` repository.
This commit is contained in:
2
Makefile
2
Makefile
@@ -1,7 +1,7 @@
|
|||||||
prefix=$$HOME/opt/pkg/miscutils
|
prefix=$$HOME/opt/pkg/miscutils
|
||||||
target_bin=${prefix}/bin
|
target_bin=${prefix}/bin
|
||||||
target_man=${prefix}/share/man/man1
|
target_man=${prefix}/share/man/man1
|
||||||
bin=bwrap hppt mkgmap newp osc p rot rr scmfmt ts upcasetl unpage
|
bin=bwrap hppt mkgmap newp osc p rot scmfmt ts upcasetl unpage
|
||||||
install:
|
install:
|
||||||
install -d ${target_bin} ${target_man}
|
install -d ${target_bin} ${target_man}
|
||||||
install -c ${bin} ${target_bin}
|
install -c ${bin} ${target_bin}
|
||||||
|
|||||||
16
rr
16
rr
@@ -1,16 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
[ $# -eq 0 ] && echo "usage: $0 command ..." && exit 64
|
|
||||||
tmp1=$(mktemp $0.XXXXXXXXXX)
|
|
||||||
tmp2=$(mktemp $0.XXXXXXXXXX)
|
|
||||||
trap "rm $tmp1 $tmp2; exit 0" 1 2 15
|
|
||||||
while "$@" >$tmp2
|
|
||||||
do
|
|
||||||
if ! diff $tmp1 $tmp2
|
|
||||||
then
|
|
||||||
cp $tmp2 $tmp1
|
|
||||||
else
|
|
||||||
echo -n "."
|
|
||||||
fi
|
|
||||||
sleep 2
|
|
||||||
done
|
|
||||||
rm $tmp1 $tmp2
|
|
||||||
30
rr.1
30
rr.1
@@ -1,30 +0,0 @@
|
|||||||
.Dd Jun 10, 2022
|
|
||||||
.Dt RR 1
|
|
||||||
.Os
|
|
||||||
.Sh NAME
|
|
||||||
.Nm rr
|
|
||||||
.Nd Repeteadly run a command until it exits with a non zero status
|
|
||||||
.Sh SYNOPSIS
|
|
||||||
.Nm
|
|
||||||
.Ar cmd Op Ar arg ...
|
|
||||||
.Sh DESCRIPTION
|
|
||||||
Run command
|
|
||||||
.Ar cmd arg ...
|
|
||||||
repeteadly until it fails.
|
|
||||||
.Pp
|
|
||||||
In every run, compare its stdout with the one from the previous run.
|
|
||||||
If there has been any change, print a diff;
|
|
||||||
otherwise, display a dot to indicate progress.
|
|
||||||
.Sh EXIT STATUS
|
|
||||||
.Ex -std
|
|
||||||
.Sh EXAMPLES
|
|
||||||
.Bd -literal -offset indent
|
|
||||||
$ rr pgrep -f foo
|
|
||||||
0a1,2
|
|
||||||
> 6871
|
|
||||||
> 25428
|
|
||||||
\&...^C
|
|
||||||
$
|
|
||||||
.Ed
|
|
||||||
.Sh AUTHORS
|
|
||||||
.An Adolfo Perez Alvarez Aq Mt adolfopa@sdf.org
|
|
||||||
Reference in New Issue
Block a user