#! /bin/csh -f # -------------------------------------------------------------------------- # Make a file that contains the usernames of all the students in the course, # per the course roster data obtained from the Schedule Lookup page. # -------------------------------------------------------------------------- set rostersFolder = Rosters # Get data from here set listOfStudents = ${cwd}/students # Put result here set temp = /tmp/tempRosters cd $rostersFolder echo -n "" >! $temp foreach f (`/bin/ls`) awk 'NR > 4 {print}' $f >> $temp end cat $temp \ | sed 's/",.*$//' \ | sed 's/"//' \ | sort -u \ >! $listOfStudents /bin/rm -f $temp