#!/bin/csh -f

if ($#argv == 0) then
  echo "Usage: swapauxs fileroot [extension ...]"
  exit 1
endif

if ($#argv == 1) then
  set exts = (aux glo idx index lof lot toc)
else
  set exts = ($argv[2-])
endif

foreach ext ($exts)
  swap $1.${ext}hold $1.$ext >/dev/null
end
