@@ -17,7 +17,7 @@ Environment Variables
17
17
18
18
.. envvar :: HOME
19
19
20
- The user's home directory. On linux , :envvar: `~ <HOME> ` is shorthand for :envvar: `HOME `.
20
+ The user's home directory. On Linux , :envvar: `~ <HOME> ` is shorthand for :envvar: `HOME `.
21
21
22
22
.. envvar :: MPLBACKEND
23
23
@@ -26,13 +26,14 @@ Environment Variables
26
26
27
27
.. envvar :: MPLCONFIGDIR
28
28
29
- This is the directory used to store user customizations to matplotlib, as
30
- well as some caches to improve performance. If :envvar: `MPLCONFIGDIR ` is not
31
- defined, :file: `{ HOME } /.config/matplotlib ` is generally used on unix-like
32
- systems and :file: `{ HOME } /.matplotlib ` is used on other platforms, if they are
33
- writable. Otherwise, the python standard library :func: `tempfile.gettempdir `
34
- is used to find a base directory in which the :file: `matplotlib ` subdirectory
35
- is created.
29
+ This is the directory used to store user customizations to
30
+ Matplotlib, as well as some caches to improve performance. If
31
+ :envvar: `MPLCONFIGDIR ` is not defined, :file: `{ HOME } /.config/matplotlib `
32
+ and :file: `{ HOME } /.cache/matplotlib ` are used on Linux, and
33
+ :file: `{ HOME } /.matplotlib ` on other platforms, if they are
34
+ writable. Otherwise, the Python standard library's `tempfile.gettempdir ` is
35
+ used to find a base directory in which the :file: `matplotlib ` subdirectory is
36
+ created.
36
37
37
38
.. envvar :: PATH
38
39
@@ -50,64 +51,41 @@ Environment Variables
50
51
51
52
.. _setting-linux-osx-environment-variables :
52
53
53
- Setting environment variables in Linux and OS-X
54
- ===============================================
54
+ Setting environment variables in Linux and macOS
55
+ ================================================
55
56
56
57
To list the current value of :envvar: `PYTHONPATH `, which may be empty, try::
57
58
58
59
echo $PYTHONPATH
59
60
60
61
The procedure for setting environment variables in depends on what your default
61
- shell is. :program: `BASH ` seems to be the most common, but :program: `CSH ` is
62
- also common. You should be able to determine which by running at the command
63
- prompt::
62
+ shell is. Common shells include :program: `bash ` and :program: `csh `. You
63
+ should be able to determine which by running at the command prompt::
64
64
65
65
echo $SHELL
66
66
67
-
68
- BASH/KSH
69
- --------
70
-
71
- To create a new environment variable::
72
-
73
- export PYTHONPATH=~/Python
74
-
75
- To prepend to an existing environment variable::
76
-
77
- export PATH=~/bin:${PATH}
78
-
79
- The search order may be important to you, do you want :file: `~/bin ` to
80
- be searched first or last? To append to an existing environment
81
- variable::
82
-
83
- export PATH=${PATH}:~/bin
84
-
85
- To make your changes available in the future, add the commands to your
86
- :file: `~/.bashrc ` file.
87
-
88
-
89
- CSH/TCSH
90
- --------
91
-
92
67
To create a new environment variable::
93
68
94
- setenv PYTHONPATH ~/Python
69
+ export PYTHONPATH=~/Python # bash/ksh
70
+ setenv PYTHONPATH ~/Python # csh/tcsh
95
71
96
72
To prepend to an existing environment variable::
97
73
98
- setenv PATH ~/bin:${PATH}
74
+ export PATH=~/bin:${PATH} # bash/ksh
75
+ setenv PATH ~/bin:${PATH} # csh/tcsh
99
76
100
- The search order may be important to you, do you want :file: `~/bin ` to be searched
101
- first or last? To append to an existing environment variable::
77
+ The search order may be important to you, do you want :file: `~/bin ` to be
78
+ searched first or last? To append to an existing environment variable::
102
79
103
- setenv PATH ${PATH}:~/bin
80
+ export PATH=${PATH}:~/bin # bash/ksh
81
+ setenv PATH ${PATH}:~/bin # csh/tcsh
104
82
105
83
To make your changes available in the future, add the commands to your
106
- :file: `~/.cshrc ` file.
84
+ :file: `~/.bashrc `/ :file: ` . cshrc ` file.
107
85
108
86
.. _setting-windows-environment-variables :
109
87
110
- Setting environment variables in windows
88
+ Setting environment variables in Windows
111
89
========================================
112
90
113
91
Open the :program: `Control Panel ` (:menuselection: `Start --> Control Panel `),
0 commit comments