Hacker News new | ask | show | jobs
by alanning 3963 days ago
Thank you, this is really helpful.

Could anyone contribute a version for OSX?

2 comments

If you have homebrew you can just install the 'gnu-sed' package and then change the function to call 'gsed' instead.
Here's my terribly hackish version for BSD userlands (briefly tested on FreeBSD, may work on OS X):

    #!/bin/sh
    eg () {
        man $1 | grep '^E.EX.XA' -A 1000 | grep '^[A-Z]' -m 2 -B 1000 -A 0 | sed '$d' | $PAGER
    }
    eg $1