diff options
author | Tom Ryder <tom@sanctum.geek.nz> | 2016-08-03 17:57:47 +1200 |
---|---|---|
committer | Tom Ryder <tom@sanctum.geek.nz> | 2016-08-03 18:03:38 +1200 |
commit | 8783a7ba4fccb5f8bb178241a98392cb4b6f6f6c (patch) | |
tree | 9323cf3529ba1c809beed46256889b8ee88c6d0d /bin/rnda | |
parent | Allow numerator and denominator in myb(1) (diff) | |
download | dotfiles-8783a7ba4fccb5f8bb178241a98392cb4b6f6f6c.tar.gz dotfiles-8783a7ba4fccb5f8bb178241a98392cb4b6f6f6c.zip |
Add rnds(1)
Low-quality random seed attempt.
Diffstat (limited to 'bin/rnda')
-rwxr-xr-x | bin/rnda | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -4,6 +4,7 @@ if [ "$#" -eq 0 ] ; then printf >&2 'rnda: No args given\n' exit 1 fi -argi=$(rndi 1 "$#") || exit +seed=$(rnds) +argi=$(rndi 1 "$#" "$seed") || exit shift "$((argi-1))" printf '%s\n' "$1" |