Created
August 24, 2015 15:32
-
-
Save bigandy/5257875c1b619d65c85d to your computer and use it in GitHub Desktop.
pwgen Bash Function
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pass() { | |
if [ -n "$1" ] | |
then | |
pwgen -sy $1 1 |pbcopy |pbpaste; echo " Has been copied to clipboard" | |
else | |
pwgen -sy 40 1 |pbcopy |pbpaste; echo "Has been copied to clipboard" | |
fi | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment