-
Notifications
You must be signed in to change notification settings - Fork 0
/
module
executable file
·52 lines (48 loc) · 2.46 KB
/
module
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
40
41
42
43
44
45
46
47
48
49
50
51
52
#%Module
proc ModulesHelp { } {
puts stderr "Usage: load this module once, run `conda init`, then use conda"
puts stderr "as normal."
puts stderr ""
puts stderr "This module provides an installation of miniforge that you can"
puts stderr "use that has been pre-configured with some common channels and"
puts stderr "installation directories in /software. It also audits your conda"
puts stderr "usage so that HGI can understand software usage to better help"
puts stderr "you in the future."
puts stderr ""
puts stderr "Basic usage starts with loading this module once, then doing an"
puts stderr "init:"
puts stderr "\$ module load HGI/common/conda"
puts stderr "\$ conda init"
puts stderr ""
puts stderr "Now close your terminal and make a new one. You'll now be in the"
puts stderr "base environment and can use conda as normal."
puts stderr "(Note that this is miniforge's default base environment, which"
puts stderr "has a minimum of things already installed in it.)"
puts stderr ""
puts stderr "By default your newley created environments will end up in"
puts stderr "/software/hgi/\[yourgroup\]/\[yourusername\], so they won't use"
puts stderr "up your quota and loading your software won't be slow."
puts stderr ""
puts stderr "Typical conda-like operations look like:"
puts stderr "\$ conda create --name \[yourenv\] biopython"
puts stderr "\$ conda activate \[yourenv\]"
puts stderr "\$ conda info --env"
puts stderr ""
puts stderr "To install a farm5 conda environment on farm22:"
puts stderr "farm5 \$ \[do what you used to do to prepare conda on farm5\]"
puts stderr "farm5 \$ conda activate \[yourenv\]"
puts stderr "farm5 \$ conda list --explicit --md5 > explicit_env.txt"
puts stderr "farm22 \$ module load HGI/common/conda && conda init"
puts stderr "farm22 \$ exit"
puts stderr "\$ ssh farm22-login"
puts stderr "farm22 \$ conda create --name \[yourenv\] -f explicit_env.txt"
puts stderr ""
puts stderr "NB: because `conda init` alters your .bashrc, and that is"
puts stderr "shared across farm5 and farm22, during the transition period"
puts stderr "between farm5 and farm22, you'll have to keep doing `conda init`"
puts stderr "every time you switch to a different farm."
}
module-whatis "miniforge wrapper with auditing and /software config"
set group [exec id -gn $env(USER)]
setenv CONDA_GROUP $group
prepend-path PATH /software/hgi/installs/conda-audited/miniforge/bin