clone.sh 347 B

123456789101112131415161718192021
  1. #!/bin/bash
  2. BASEDIR=$(dirname "$0")
  3. cd "${BASEDIR}" || exit 1
  4. BASEDIR=$(pwd)
  5. source config.sh
  6. if [ -f config/config_local.sh ]; then
  7. source config/config_local.sh
  8. fi
  9. set -x
  10. if [ ! -d "${UPSTREAM_DIR}" ]; then
  11. git clone "${UPSTREAM_REPO}" "${UPSTREAM_DIR}"
  12. fi
  13. if [ ! -d "${PMC_DIR}" ]; then
  14. git clone "${PMC_REPO}" "${PMC_DIR}"
  15. fi