A collection of shell scripts to make my live easier.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

13 lines
291 B

#!/bin/sh
function rand_printable() {
local ECHO="/bin/echo"
local TR="/usr/bin/tr"
local HEAD="/usr/bin/head"
${ECHO} -n "`</dev/urandom ${TR} -dc \ -\&\(-~ | ${HEAD} -c${1:-512}`"
}
test "X$(basename -- "$0")" = "Xrand_printable" && rand_printable "$@"
# vim: set ft=sh ts=4 sw=4: