#!/bin/sh
config() {
  NEW="$1"
  OLD="`dirname $NEW`/`basename $NEW .new`"
  # If there's no config file by that name, mv it over:
  if [ ! -r $OLD ]; then
    mv $NEW $OLD
  elif [ "`cat $OLD | md5sum`" = "`cat $NEW | md5sum`" ]; then # toss the redundant copy
    rm $NEW
  fi
  # Otherwise, we leave the .new copy for the admin to consider...
}
# Might need this later
#config etc/X11/fvwm2/system.fvwm2rc.new
( cd usr/bin ; rm -rf fvwm2 )
( cd usr/bin ; ln -sf fvwm fvwm2 )
( cd usr/bin ; rm -rf xpmroot )
( cd usr/bin ; ln -sf fvwm-root xpmroot )
( cd usr/man/man1 ; rm -rf fvwm2.1.gz )
( cd usr/man/man1 ; ln -sf fvwm.1.gz fvwm2.1.gz )
( cd usr/man/man1 ; rm -rf xpmroot.1.gz )
( cd usr/man/man1 ; ln -sf fvwm-root.1.gz xpmroot.1.gz )
( cd usr/libexec/fvwm/2.6.5 ; rm -rf FvwmAudio )
( cd usr/libexec/fvwm/2.6.5 ; ln -sf FvwmEvent FvwmAudio )
