dotfiles

$HOME is where the <3 is
git clone git://git.alexkarle.com/dotfiles.git
Log | Files | Refs | Submodules | README | LICENSE

wiseman (366B) [raw]


      1 #!/bin/sh
      2 # wiseman -- for the plumber, use the correct man for plan9 vs unix
      3 set -e
      4 die() {
      5 	echo "$*" 1>&2
      6 	exit 1
      7 }
      8 
      9 [ -z "$1" ] && die "usage: wiseman SECTION NAME"
     10 [ -z "$2" ] && die "usage: wiseman SECTION NAME"
     11 
     12 section="$1"
     13 page="$2"
     14 
     15 if [ -e "$PLAN9/man/man$section/$page.$section" ]; then
     16 	9 man "$section" "$page"
     17 else
     18 	/usr/bin/man "$section" "$page"
     19 fi