reconfig 357 B

12345678910111213141516171819202122
  1. #!/bin/bash
  2. die() {
  3. echo "#####"
  4. echo "$@"
  5. echo "#####"
  6. exit 1
  7. }
  8. if [[ $1 == "install" ]] ; then
  9. cd "${MY_INSTALLDIR}" || die
  10. files="lxr.conf $(ls ._cfg*lxr.conf 2>/dev/null)"
  11. sed -i \
  12. -e "s|/lxr|${VHOST_APPDIR}|" \
  13. -e "s|192.168.1.3/lxr|${VHOST_HOSTNAME}${VHOST_APPDIR}|" \
  14. ${files} || die
  15. elif [[ $1 = "clean" ]] ; then
  16. echo $1
  17. fi
  18. exit 0