Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

improve docs on modulefiles #769

Merged
merged 1 commit into from
Sep 13, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 12 additions & 3 deletions docs/src/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ Preferences are merged across the Julia load path, such that it is feasible to p
mpiexec = "/software/mpi/bin/mpiexec"
```

2. Create a file called `Project.toml` or `JuliaProject.toml` in a central location, for example `/software/mpi/julia` or in the same directory as the MPI library module, and add the following contents:
2. Create a file called `Project.toml` or `JuliaProject.toml` in a central location (for example `/software/mpi/julia`, or in the same directory as the MPI module file), and add the following contents:

```toml
[extras]
Expand All @@ -94,12 +94,21 @@ Preferences are merged across the Julia load path, such that it is feasible to p

3. Append the directory containing the file to the [`JULIA_LOAD_PATH`](https://docs.julialang.org/en/v1/manual/environment-variables/#JULIA_LOAD_PATH) environment variable, with a colon (`:`) separator.

If this variable is _not_ already set, it should be prefixed with a colon to ensure correct
behavior of the Julia load path, e.g. `JULIA_LOAD_PATH=":/software/mpi/julia"`.
!!! note
If this variable is _not_ already set, it should be prefixed with a colon to ensure correct
behavior of the Julia load path (e.g. `JULIA_LOAD_PATH=":/software/mpi/julia"`)

If using environment modules, this can be achieved with
```
append-path -d {} JULIA_LOAD_PATH :/software/mpi/julia
```
or if using an older version of environment modules
```
if { ![info exists ::env(JULIA_LOAD_PATH)] } {
append-path JULIA_LOAD_PATH ""
}
append-path JULIA_LOAD_PATH /software/mpi/julia
```
in the corresponding module file (preferably the module file for the MPI installation or for Julia).

The user can still provide differing MPI configurations for each Julia project
Expand Down