Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Posting-Version: version B 2.10.1 6/24/83; site cbscc.UUCP
Path: utzoo!watmath!clyde!bonnie!akgua!whuxlm!whuxl!houxm!ihnp4!cbosgd!cbsck!cbscc!lvc
From: lvc@cbscc.UUCP (Larry Cipriani)
Newsgroups: net.sources
Subject: some ksh aliases and functions
Message-ID: <3833@cbscc.UUCP>
Date: Fri, 5-Oct-84 08:22:38 EDT
Article-I.D.: cbscc.3833
Posted: Fri Oct  5 08:22:38 1984
Date-Received: Thu, 11-Oct-84 05:56:01 EDT
Organization: AT&T Bell Laboratories , Columbus
Lines: 44

Would anyone have any ksh functions/aliases they'd like to post.
Here's some I use all the time; fairly simple minded but very useful.
These use Unix* 5.0 commands.

alias -x ag='alias | fgrep'
alias -x all='find . -print'
alias -x l='ls -l'
alias -x lp='/usr/bin/lp -dcent'
alias -x lpstat='/usr/bin/lpstat -o | grep -v "^-0"'
alias -x news='readnews -n cb.general scc.general \
	scc.darn scc.generic net.sources'
alias -x profile='. ~/.profile'
alias -x reset='. ~/.aliases'
alias -x smail='/usr/mail/PCS/bin/smail +edit'
alias -x ti='/usr/bin/lp -dti'
alias -x ul='print -n "User load:" ; who | wc -l'
alias -x wg='who | grep'
alias -x which='print "You are on cbscc"'
alias -x xpr='/usr/lbin/xpr -!Ehjw120'

#	look for a string in the password file (this will need to be
#	modified for use on non-SCCS password files)

function whois
{
    for i in ${*}
	do
	    grep ${i} /etc/passwd | \
		sed -e s/.*:unix-// -e s/:$// -e s/5947[0-9].*://p
	done
}

#	make a directory && change to it && pwd

function mc
{
	case ${#} in
	    1 ) mkdir ${1} && cd ${1} && pwd
		;;
	    * ) print - "usage: mc directory"
		;;
	esac
}