#!/bin/sh 
#--------------------------- Shell MegaWave2 Macro --------------------------#
_sccsid="%Z%MegaWave %R%, %M% %I%, %G%";
_Func="Write the contributors of all MegaWave2 modules or macros"
_Prog="`basename $0`"
_Vers="1.1"
_Date="1997-2002"
_Auth="Jacques Froment";
_Usage="src_directory | sort -k 2 -u"
#----------------------------------------------------------------------------#
# This file is part of the MegaWave2 system macros. 
# MegaWave2 is a "soft-publication" for the scientific community. It has
# been developed for research purposes and it comes without any warranty.
# The last version is available at http://www.cmla.ens-cachan.fr/Cmla/Megawave
# CMLA, Ecole Normale Superieure de Cachan, 61 av. du President Wilson,
#       94235 Cachan cedex, France. Email: megawave@cmla.ens-cachan.fr 
#-----------------------------------------------------------------------------

if [ $# -ne 1 ]; then
  . .mw2_help_lg_com
fi

dir=$1
if [ ! -d $dir ]; then
  echo "Error: directory $dir not found !"
  exit 1
fi

for file in `ls ${dir}`
do
  if [ ! -d ${dir}/${file} ]; then
    (cd ${dir}; mwcontrib $file)
  else
#   echo "--> ${dir}/${file} <--" 1>&2
   mwcontrib_all ${dir}/${file} 
#   echo "<-- -->" 1>&2
  fi
done


exit 0




