Expunge revision histories.
[shells] / ushell.1
CommitLineData
173be297 1.\" -*-nroff-*-
ed36b0a2 2.TH ushell 1 "20 April 1999" "Local tools"
3.SH NAME
4ushell \- display a user's shell
5.SH SYNOPSIS
6.B ushell
7.I user
8.SH USAGE
9Writes the named user's default shell to standard output. This is
10useful in scripts sometimes. In particular, it's handy in global
11.B xdm/Xstartup
12scripts for checking whether users have sensible shells:
13.sp 1
14.RS 5
15.nf
16.ft B
17SHELL=`ushell $USER`
18case $SHELL in
19 */banned)
20 xmessage -file $HOME/.banned
21 exit 1
22 ;;
23 *)
24 if ! grep -q "^$SHELL" /etc/shells; then
25 xmessage "You're not allowed to log in this way."
26 exit 1
27 fi
28 ;;
29esac
30.fi
31.ft R
32.SH BUGS
33None planned.
34.SH SEE ALSO
35.BR banned (8),
36.BR chrootsh (8).
37.SH AUTHOR
38Mark Wooding (mdw@nsict.org)