forked from JeffersonLab/hdpm
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsetup.csh
More file actions
39 lines (39 loc) · 1.42 KB
/
setup.csh
File metadata and controls
39 lines (39 loc) · 1.42 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
# tcsh: Get julia binary for 64-bit Linux and put it in PATH
# Make alias for running hdpm.jl
# usage: source setup.csh
echo "Linux (64-bit): Hall-D Package Manager setup"
echo "Run the 'hdpm' command in the current working directory."
alias hdpm 'julia src/hdpm.jl'
setenv JULIA_LOAD_PATH `pwd`/src
set JLPATH=/group/halld/Software/ExternalPackages/julia-latest/bin
if ( -e ${JLPATH}/julia ) then
echo "You appear to be on the JLab CUE; Will try to use group installation of julia."
echo $PATH | grep -q $JLPATH
if ( $? != 0 ) then
echo "Putting julia in your PATH."
setenv PATH ${JLPATH}:$PATH; goto end
else
echo "You already have julia in your PATH."; goto end
endif
endif
set VER=0.3.11
set JLPATH=`pwd`/pkgs/deps/julia-$VER/bin
if ( -e ${JLPATH}/julia ) then
echo "julia-$VER directory already exists; nothing to download."
echo $PATH | grep -q $JLPATH
if ( $? != 0 ) then
echo "Putting julia in your PATH."
setenv PATH ${JLPATH}:$PATH; goto end
else
echo "You already have julia in your PATH."; goto end
endif
endif
echo "Downloading julia-$VER."
curl -OL https://julialang.s3.amazonaws.com/bin/linux/x64/0.3/julia-$VER-linux-x86_64.tar.gz
mkdir -p pkgs/deps/julia-$VER
tar -xzf julia-$VER-linux-x86_64.tar.gz -C pkgs/deps/julia-$VER --strip-components=1
rm -f julia-$VER-linux-x86_64.tar.gz
echo "Putting julia in your PATH."
setenv PATH ${JLPATH}:$PATH
end:
echo "Good to go!"