From 87a7075bfff9dedb8a3c4fce274692ab79358cc3 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Eric=20M=C3=BCller?= <mueller@kip.uni-heidelberg.de>
Date: Wed, 28 Feb 2024 16:08:15 +0100
Subject: [PATCH] feat: fetch before install

---
 install_spack_env.sh | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/install_spack_env.sh b/install_spack_env.sh
index b354b43b..f0065f98 100644
--- a/install_spack_env.sh
+++ b/install_spack_env.sh
@@ -77,6 +77,12 @@ rm $SPACK_ROOT/var/spack/environments/$EBRAINS_SPACK_ENV/spack.lock || echo "No
 
 # activate environment
 spack env activate $EBRAINS_SPACK_ENV
+
+# fetch all sources
+spack concretize --fresh --test root
+spack fetch --dependencies --missing
+rm $SPACK_ROOT/var/spack/environments/$EBRAINS_SPACK_ENV/spack.lock
+
 # install the environment, use 2 jobs to reduce the amount of required RAM
 spack install -y -j2 --fresh --test root
 
-- 
GitLab