summaryrefslogtreecommitdiff
path: root/lib/spack/docs/getting_started.rst
diff options
context:
space:
mode:
authorChuck Atkins <chuck.atkins@kitware.com>2021-02-12 13:52:44 -0500
committerGitHub <noreply@github.com>2021-02-12 10:52:44 -0800
commit5a771bc8ad3ddb1b3f550f1685c451cc6cb49e64 (patch)
tree67216810f4f0f0d94d805110f1ffe4e5fb757a99 /lib/spack/docs/getting_started.rst
parent7add9de2e531e7a498cff85c20ff474d6d4eddec (diff)
downloadspack-5a771bc8ad3ddb1b3f550f1685c451cc6cb49e64.tar.gz
spack-5a771bc8ad3ddb1b3f550f1685c451cc6cb49e64.tar.bz2
spack-5a771bc8ad3ddb1b3f550f1685c451cc6cb49e64.tar.xz
spack-5a771bc8ad3ddb1b3f550f1685c451cc6cb49e64.zip
Introduce a SPACK_PYTHON environment variable (#21222)
The SPACK_PYTHON environment variable can be set to a python interpreter to be used by the spack command. This allows the spack command itself to use a consistent and separate interpreter from whatever python might be used for package building.
Diffstat (limited to 'lib/spack/docs/getting_started.rst')
-rw-r--r--lib/spack/docs/getting_started.rst8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/spack/docs/getting_started.rst b/lib/spack/docs/getting_started.rst
index 3cf910cc8d..6f3340b18b 100644
--- a/lib/spack/docs/getting_started.rst
+++ b/lib/spack/docs/getting_started.rst
@@ -75,6 +75,14 @@ shell integration for :ref:`certain commands <packaging-shell-support>`,
If you do not want to use Spack's shell support, you can always just run
the ``spack`` command directly from ``spack/bin/spack``.
+When the ``spack`` command is executed it searches for an appropriate
+Python interpreter to use, which can be explicitly overridden by setting
+the ``SPACK_PYTHON`` environment variable. When sourcing the appropriate shell
+setup script, ``SPACK_PYTHON`` will be set to the interpreter found at
+sourcing time, ensuring future invocations of the ``spack`` command will
+continue to use the same consistent python version regardless of changes in
+the environment.
+
^^^^^^^^^^^^^^^^^^
Check Installation