diff --git a/specfem3d/compile.sh b/specfem3d/compile.sh index 690679ff7900de34bfdae18909a6f052b1e8e60d..17d6db5887b853b618f00ccef4f90ba7f13e6876 100755 --- a/specfem3d/compile.sh +++ b/specfem3d/compile.sh @@ -21,19 +21,28 @@ Untar(){ echo "==> Untar " #Clone the repository cd $install_dir - #git -c http.sslVerify=false clone https://github.com/geodynamics/specfem3d_globe.git - cd specfem3d_globe/ - # Checkout of 31 ocotbre 2017 version - #git checkout b1d6ba966496f269611eff8c2cf1f22bcdac2bd9 - - # Checkout v7.0.2, last version : unstable : tested on differents architectures and all simulations failed - #git checkout v7.0.2 + git -c http.sslVerify=false clone https://github.com/geodynamics/specfem3d_globe.git + code=$? + if [[ $code != "0" ]]; then + echo "Git clone failed, try a hard copy:" + Copy + break 1 + else + cd specfem3d_globe/ + # Checkout of 31 ocotbre 2017 version + git checkout b1d6ba966496f269611eff8c2cf1f22bcdac2bd9 + + # Checkout v7.0.2, last version : unstable : tested on differents architectures and all simulations failed + #git checkout v7.0.2 + fi + cd $ueabs_dir +} - #Copy sources +Copy(){ + # Copy sources (Edit source_dir if needed) source_dir=$HOME/git/specfem3d_globe echo "Copy source" cp -r $source_dir $install_dir - cd $ueabs_dir } Install(){