Forked from quickshiftin/osx-brew-gnu-coreutils-man.sh
Last active
February 3, 2019 08:56
-
-
Save si9ma/43f5c0281955f4914b1a7704eb1b2f68 to your computer and use it in GitHub Desktop.
Running GNU coreutils via Homebrew on your Mac? Here's a one-liner to get the manpages working!
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
# Short of learning how to actually configure OSX, here's a hacky way to use | |
# GNU manpages for programs that are GNU ones, and fallback to OSX manpages otherwise | |
alias man='_() { echo $@; man -M $(brew --prefix)/opt/coreutils/libexec/gnuman $@ 1>/dev/null 2>&1; if [ "$?" -eq 0 ]; then man -M $(brew --prefix)/opt/coreutils/libexec/gnuman $@; else man $@; fi }; _' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment