Skip to content

Commit 7bb1a92

Browse files
committed
add error if both input directory are the same
1 parent f477b47 commit 7bb1a92

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

juhpc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,10 @@ check_var "JULIAUP_INSTALLDIR" "JUHPC_SETUP_INSTALLDIR"
145145
check_dir "$JUHPC_SETUP_INSTALLDIR"
146146
mkdir -p "$JUHPC_SETUP_INSTALLDIR" || { error "failed to create directory: $JUHPC_SETUP_INSTALLDIR"; }
147147

148+
if [[ "$JULIAUP_INSTALLDIR" == "$JUHPC_SETUP_INSTALLDIR" ]]; then
149+
error "JULIAUP_INSTALLDIR and JUHPC_SETUP_INSTALLDIR cannot have the same value."
150+
fi
151+
148152

149153
# Download and install julia in /tmp using juliaup
150154

0 commit comments

Comments
 (0)