4 ms·
This was handy before oh-my-zsh but omz has functionality for this now that it's no longer necessary. pman() { man -t "${1}" | open -f -a /Syst
by hk1337 4y ago
This was handy before oh-my-zsh but omz has functionality for this now that it's no longer necessary.
pman()
{
man -t "${1}" | open -f -a /System/Applications/Preview.app
}
I like using this in conjunction with pbcopy to quickly generate a random password at given length
pwgen()
{
length=${1:-64}
charlist='0-9a-zA-Z~!@#$%^&*()_+-=:";<>?,./'
echo `cat /dev/random | tr -dc $charlist | head -c$length`
}
- neotek 4y ago>pman Oh man. I didn't know just how badly I needed this in my life, thank you!
- hk1337 4y agoIf you're using oh-my-zsh, the macOS plugin has "man-preview" that does the same thing, probably a little better. I updated mine to alias pman=man-preview
- lathiat 4y agoFor pwgen there is a great tool of the same name that does basically that. Just have to add -1 to get a single password by default it outputs a whole bunch so you can pick one which I prefer most of the time.