Skip to content

Instantly share code, notes, and snippets.

@forelabs
Created September 25, 2019 08:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save forelabs/9d421b0432230ea70673fa2eaa9fdab3 to your computer and use it in GitHub Desktop.
Save forelabs/9d421b0432230ea70673fa2eaa9fdab3 to your computer and use it in GitHub Desktop.
password generator
function genpasswd() {
local l=$1
[ "$l" == "" ] && l=32
tr -dc "!$#;,.%()A-Za-z0-9_" < /dev/urandom | head -c ${l} | xargs
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment