diff options
author | Colin Guthrie <colin@mageia.org> | 2012-02-16 14:37:20 +0000 |
---|---|---|
committer | Colin Guthrie <colin@mageia.org> | 2012-02-16 14:37:20 +0000 |
commit | 0b388682796677bb8f508f7e18f43b8cda003b8f (patch) | |
tree | 28f14b5c853dff1171c66142fded6101d1ea0c66 /trunk/get-password | |
parent | bd15ccffc636ff060e4f1d77dcf59fcd584fa8c8 (diff) | |
download | rpm-helper-0b388682796677bb8f508f7e18f43b8cda003b8f.tar rpm-helper-0b388682796677bb8f508f7e18f43b8cda003b8f.tar.gz rpm-helper-0b388682796677bb8f508f7e18f43b8cda003b8f.tar.bz2 rpm-helper-0b388682796677bb8f508f7e18f43b8cda003b8f.tar.xz rpm-helper-0b388682796677bb8f508f7e18f43b8cda003b8f.zip |
version 0.24.6v0.24.6
Diffstat (limited to 'trunk/get-password')
-rwxr-xr-x | trunk/get-password | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/trunk/get-password b/trunk/get-password new file mode 100755 index 0000000..caa783a --- /dev/null +++ b/trunk/get-password @@ -0,0 +1,11 @@ +#!/bin/sh +# $Id$ +# helper script for rpm scriptlets to get a random password + +if [ -n "$1" ]; then + length=$1 +else + length=8 +fi + +perl -e "@c = (a..z,A..Z,0..9); print map { @c[rand @c] } 0..$length" |