File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -197,6 +197,12 @@ info() {
197
197
echo -e "$(ENV["JUHPC"]) \$message" >&2
198
198
}
199
199
200
+ error() {
201
+ local message="\$1"
202
+ info "\e[1;31mERROR:\e[0m \$message"
203
+ exit 1
204
+ }
205
+
200
206
JULIAUP_EXE="$(ENV["JULIAUP_BINDIR"])/juliaup"
201
207
202
208
if [ ! -f "\$JULIAUP_EXE" ]; then
@@ -214,14 +220,16 @@ else
214
220
fi
215
221
""")
216
222
' > " $JULIAUP_WRAPPER "
223
+
224
+ if [ ! -s " $JULIAUP_WRAPPER " ]; then error " Juliaup wrapper is missing or empty." ; fi
217
225
chmod +x " $JULIAUP_WRAPPER "
218
226
219
227
info " ... done."
220
228
221
229
222
230
# Create an activation script that sets environment variables for juliaup, julia and HPC key packages
223
231
224
- info_start " Creating activation script"
232
+ info_start " Creating activate script"
225
233
226
234
export JULIAUP_DEPOT=" $JULIAUP_INSTALLDIR /depot"
227
235
export JULIA_DEPOT=" $JULIAUP_INSTALLDIR /depot"
@@ -257,6 +265,8 @@ $(haskey(ENV,"JUHPC_ADIOS2_HOME") && ENV["JUHPC_ADIOS2_HOME"] != "" ? """
257
265
""" : "")
258
266
""")' > " $ACTIVATE_SCRIPT "
259
267
268
+ if [ ! -s " $ACTIVATE_SCRIPT " ]; then error " Activate script is missing or empty." ; fi
269
+
260
270
info " ... done."
261
271
262
272
You can’t perform that action at this time.
0 commit comments