Created
November 25, 2017 22:57
-
-
Save victorboissiere/727bede2eaf7ff050b0e305b6d3fc03b to your computer and use it in GitHub Desktop.
Replace man with TLDR
This file contains 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
function man() | |
{ | |
OUTPUT="`tldr $1 2>&1`" | |
if [ $? -eq 0 ]; then | |
echo $OUTPUT | |
else | |
/usr/bin/man $1 | |
fi | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment