File tree Expand file tree Collapse file tree 8 files changed +50
-34
lines changed Expand file tree Collapse file tree 8 files changed +50
-34
lines changed Original file line number Diff line number Diff line change @@ -16,8 +16,9 @@ CODE is based around our standard Debian bookworm system at ITPcp and provides
16
16
17
17
## Getting Started
18
18
19
- If you haven't done so earlier, set up your SSH keys in ` ~/.ssh ` via ` ssh-keygen ` and
20
- add the content of ` id_rsa.pub ` to Gitlab and GitHub for authentication.
19
+ If you haven't done so earlier, set up your SSH keys in ` ~/.ssh ` via ` ssh-keygen `
20
+ with a ** blank passphrase** and add the content of ` id_rsa.pub ` to Gitlab and GitHub
21
+ for authentication.
21
22
22
23
### Perparing your machine
23
24
@@ -47,14 +48,20 @@ Run the setup script manually with
47
48
48
49
scripts/setup.sh
49
50
50
- The setup will install external dependencies and create and activate
51
+ The setup will install external dependencies and create
51
52
a Python virtual environment in the hidden ` .venv ` directory.
52
53
53
- If you work outside a container, also manually run
54
+ Finally, activate the environment with
55
+
56
+ source activate.sh
54
57
55
- source /path/to/code/activate.sh
58
+ To use this environment as a standard, edit your bashrc with
56
59
57
- and put this line in your bashrc.
60
+ code ~/.bashrc
61
+
62
+ and put as a last line
63
+
64
+ source <path to your code copy>/activate.sh
58
65
59
66
60
67
## Testing
Original file line number Diff line number Diff line change 2
2
3
3
module-whatis "MARS (2022)"
4
4
5
- prereq nvhpc/24.5
5
+ prereq nvhpc/24.1
6
6
7
7
setenv MARSHOME $env(CODE)/external/MARS/MarsQ_2022
8
8
prepend-path PATH $env(MARSHOME)
Original file line number Diff line number Diff line change 1
1
#! /bin/bash
2
+ set -e
2
3
3
- # Enable non-free packages
4
- sudo sed -i -e' s/ main$/ main contrib non-free non-free-firmware/g' \
5
- /etc/apt/sources.list.d/debian.sources
6
- sudo sed -i -e' s/ main$/ main contrib non-free non-free-firmware/g' \
7
- /etc/apt/sources.list
4
+ # src: https://stackoverflow.com/a/246128/16527499
5
+ SCRIPT_DIR=$( cd -- " $( dirname -- " ${BASH_SOURCE[0]} " ) " & > /dev/null && pwd )
8
6
9
- sudo apt-get update -y && apt-get upgrade -y -q --no-install-recommends
7
+ sudo apt-get update -y && sudo apt-get upgrade -y -q --no-install-recommends
10
8
11
- sudo $CODE /scripts/setup /debian/base.sh
12
- sudo $CODE /scripts/setup /debian/interactive.sh
13
- sudo $CODE /scripts/setup /debian/libs.sh
14
- sudo $CODE /scripts/setup /debian/octave.sh
15
- sudo $CODE /scripts/setup /debian/texlive.sh
16
- sudo $CODE /scripts/setup /debian/fonts.sh
9
+ sudo $SCRIPT_DIR /debian/base.sh
10
+ sudo $SCRIPT_DIR /debian/interactive.sh
11
+ sudo $SCRIPT_DIR /debian/libs.sh
12
+ sudo $SCRIPT_DIR /debian/octave.sh
13
+ sudo $SCRIPT_DIR /debian/texlive.sh
14
+ sudo $SCRIPT_DIR /debian/fonts.sh
Original file line number Diff line number Diff line change @@ -25,4 +25,6 @@ apt-get install -y -q --no-install-recommends \
25
25
python3-dev \
26
26
python3-pip \
27
27
python3-venv \
28
- nix-bin
28
+ nix-bin \
29
+ bash \
30
+ csh
Original file line number Diff line number Diff line change @@ -23,7 +23,8 @@ apt-get install -y -q --no-install-recommends \
23
23
libparmetis-dev \
24
24
libscotch-dev \
25
25
libzstd-dev \
26
- cppzmq-dev \
26
+ libgmp-dev \
27
+ libmpfr-dev \
27
28
uuid-dev \
28
29
petsc-dev \
29
30
slepc-dev \
Original file line number Diff line number Diff line change @@ -6,17 +6,7 @@ cd slatec
6
6
mkdir lib
7
7
curl -L https://www.netlib.org/slatec/slatec_src.tgz -o - | tar xz
8
8
9
- # Check the operating system
10
- if [[ " $( uname) " == " Darwin" ]]; then
11
- # macOS specific compiler flags
12
- CFLAGS=" -O2"
13
- elif [[ " $( uname) " == " Linux" ]]; then
14
- # Linux specific compiler flags
15
- CFLAGS=" -msse2 -mfpmath=sse"
16
- else
17
- # Default compiler flags for other operating systems
18
- CFLAGS=" "
19
- fi
9
+ CFLAGS=" -O2"
20
10
gfortran -c -Wall -Wtabs -mtune=generic $CFLAGS src/* .f
21
11
ar rcs libslatec.a * .o
22
12
rm * .o
@@ -27,7 +17,7 @@ echo ""
27
17
echo " Building Sundials..."
28
18
cd ..
29
19
git clone
[email protected] :LLNL/sundials.git
30
- cd sundials
20
+ cd sundials
31
21
git checkout v5.7.0
32
22
mkdir build
33
23
cd build
Original file line number Diff line number Diff line change
1
+ #! /bin/bash
2
+
3
+ install_lazygit () {
4
+ if ! command -v lazygit & > /dev/null; then
5
+ echo installing Lazygit...
6
+ LAZYGIT_VERSION=$( curl -s " https://api.github.com/repos/jesseduffield/lazygit/releases/latest" | grep -Po ' "tag_name": "v\K[^"]*' )
7
+ curl -Lo lazygit.tar.gz --output-dir /tmp " https://github.com/jesseduffield/lazygit/releases/latest/download/lazygit_${LAZYGIT_VERSION} _Linux_x86_64.tar.gz"
8
+ tar -xf /tmp/lazygit.tar.gz -C /tmp lazygit
9
+ mkdir -p $HOME /.local/bin
10
+ install /tmp/lazygit $HOME /.local/bin
11
+ rm /tmp/lazygit*
12
+ echo Lazygit installed
13
+ else
14
+ echo Lazygit already installed
15
+ fi
16
+ }
17
+
18
+ install_lazygit
Original file line number Diff line number Diff line change 1
1
#! /bin/bash
2
2
3
3
set -e
4
- module load nvhpc/24.5
4
+ module load nvhpc/24.1
5
5
git clone
[email protected] :plasma/codes/mars.git MARS
6
6
cd MARS/MarsQ_2022
7
7
make
You can’t perform that action at this time.
0 commit comments