#!/bin/sh # This script creates the html document that displays your current # users on the mars/samba server in a nice html format base="/hamster/home/" # Base dir of home dirs echo "" echo "
(See how much diskspace is in use by the users)
" touch /tmp/ulist.tmp rm /tmp/ulist.tmp mv /etc/ohulist /etc/ohulist- touch /tmp/ulist.tmp for l in `ls $base/httpd/html`; do LNAME=`grep "^$l:" /etc/passwd | cut -f 5 -d : - | cut -f 1 -d , -` if [ $l = "ftp" ]; then LNAME=""; fi if [ $l = "gopher" ]; then LNAME=""; fia ### NNNB Please add simular lines not to display other kinds of autousers. if [ "$LNAME" != "" ]; then echo "$LNAME : $l" >> /tmp/ulist.tmp fi done cat /tmp/ulist.tmp | sort > /tmp/ulist2.tmp rm /tmp/ulist.tmp cat /tmp/ulist2.tmp | cut -f 2 -d : - > /tmp/ulist3.tmp rm /tmp/ulist2.tmp echo "
' echo -n "$LNAME | ' echo "$l@eng.rau.ac.za |