This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revision | |||
| working_with_python [2024/04/22 10:51] – jansen | working_with_python [2025/04/07 15:07] (current) – Modified example for RHEL9 jansen | ||
|---|---|---|---|
| Line 73: | Line 73: | ||
| === Method 1 - subsection Incompatible versions === | === Method 1 - subsection Incompatible versions === | ||
| - | Unfortunately, | + | Unfortunately, |
| In cases like this, it might be necessary to create a separate python user directory structure for those machines: | In cases like this, it might be necessary to create a separate python user directory structure for those machines: | ||
| Line 79: | Line 79: | ||
| Add to your .bashrc something like this: | Add to your .bashrc something like this: | ||
| if [ ! -f / | if [ ! -f / | ||
| - | export PYTHONUSERBASE=$HOME/ | + | export PYTHONUSERBASE=$HOME/ |
| fi | fi | ||
| For users of the '' | For users of the '' | ||
| if (! -f / | if (! -f / | ||
| - | setenv PYTHONUSERBASE $HOME/ | + | setenv PYTHONUSERBASE $HOME/ |
| endif | endif | ||
| - | And make sure to create that directory ~/.local-rhel7. Now the pip --user commands on RHEL7 machines will install into that newly created directory in stead of the default one used by the desktop systems. | + | And make sure to create that directory ~/.local-rhel9. Now the pip --user commands on RHEL9 machines will install into that newly created directory in stead of the default one used by the desktop systems. |
| ==== METHOD 2: venv ==== | ==== METHOD 2: venv ==== | ||