1
- .\" Automatically generated by Pandoc 2 .2.1
1
+ .\" Automatically generated by Pandoc 3 .2.1
2
2
.\"
3
- .TH "PY" "1" "2022-11-04" "Python Launcher 1.0.0" "Python Launcher"
4
- .hy
3
+ .TH "PY" "1" "2024-06-30" "Python Launcher 1.0.1" "Python Launcher"
5
4
.SH NAME
6
- .PP
7
5
py \- launch a Python interpreter
8
6
.SH SYNOPSIS
9
- .PP
10
- \f[B] py \f[ ] [\f[B] \- [X]/[X.Y] \f[ ] ] \& ...
7
+ \f[B] py \f[ R ] [\f[B] \- [X]/[X.Y] \f[ R ] ] \& ...
11
8
.SH DESCRIPTION
12
- .PP
13
- \f[B] py \f[ ] launches the most appropriate Python interpreter it can
9
+ \f[B] py \f[ R ] launches the most appropriate Python interpreter it can
14
10
find.
15
- It is meant to act as a shorthand for launching \f[B] python \f[ ] without
16
- having to think about \f[I] which \f[ ] Python interpreter is the most
11
+ It is meant to act as a shorthand for launching \f[B] python \f[ R ] without
12
+ having to think about \f[I] which \f[ R ] Python interpreter is the most
17
13
desired.
18
14
The Python Launcher is not meant to substitute all ways of launching
19
15
Python, e.g.\ if a specific Python interpreter is desired then it is
20
16
assumed it will be directly executed.
21
17
.SH SPECIFYING A PYTHON VERSION
22
- .PP
23
- If a command\- line option is provided in the form of \f[B] \- X \f[ ] or
24
- \f[B] \- X.Y \f[ ] where \f[I] X \f[ ] and \f[I] Y \f[ ] are integers, then that
25
- version of Python will be launched (if available).
26
- For instance, providing \f[B] \- 3 \f[ ] will launch the newest version of
27
- Python 3 while \f[B] \- 3.6 \f[ ] will try to launch Python 3.6.
18
+ If a command\- line option is provided in the form of \f[B] \- X \f[ R ] or
19
+ \f[B] \- X.Y \f[ R ] where \f[I] X \f[ R ] and \f[I] Y \f[ R ] are integers, then
20
+ that version of Python will be launched (if available).
21
+ For instance, providing \f[B] \- 3 \f[ R ] will launch the newest version of
22
+ Python 3 while \f[B] \- 3.6 \f[ R ] will try to launch Python 3.6.
28
23
.SH SEARCHING FOR PYTHON INTERPRETERS
29
- .PP
30
24
When no command\- line arguments are provided to the launcher, what is
31
25
deemed the most \[lq ] appropriate\[rq ] interpreter is searched for as
32
26
follows:
33
27
.IP " 1." 3
34
28
An activated virtual environment (launched immediately if available)
35
29
.IP " 2." 3
36
- A \f[B] .venv \f[ ] directory in the current working directory or any
30
+ A \f[B] .venv \f[ R ] directory in the current working directory or any
37
31
parent directory containing a virtual environment (launched immediately
38
32
if available)
39
33
.IP " 3." 3
40
34
If a file path is provided as the first argument, look for a shebang
41
- line containing \f[B] /usr/bin/python \f[ ] ,
42
- \f[B] /usr/local/bin/python \f[ ] , \f[B] /usr/bin/env python \f[ ] or
43
- \f[B] python \f[ ] and any version specification in the executable name is
44
- treated as a version specifier (like with \f[B] \- X \f[ ] /\f[B] \- X.Y \f[ ]
35
+ line containing \f[B] /usr/bin/python \f[ R ] ,
36
+ \f[B] /usr/local/bin/python \f[ R ] , \f[B] /usr/bin/env python \f[ R ] or
37
+ \f[B] python \f[ R ] and any version specification in the executable name is
38
+ treated as a version specifier (like with \f[B] \- X \f[ R ] /\f[B] \- X.Y \f[ R ]
45
39
command\- line options)
46
40
.IP " 4." 3
47
41
Check for any appropriate environment variable (see
48
- \f[B] ENVIRONMENT \f[ ] )
42
+ \f[B] ENVIRONMENT \f[ R ] )
49
43
.IP " 5." 3
50
- Search \f[B] PATH \f[ ] for all \f[B] pythonX.Y \f[ ] executables
44
+ Search \f[B] PATH \f[ R ] for all \f[B] pythonX.Y \f[ R ] executables
51
45
.IP " 6." 3
52
46
Launch the newest version of Python (while matching any version
53
47
restrictions previously specified)
@@ -56,70 +50,49 @@ All unrecognized command\-line arguments are passed on to the launched
56
50
Python interpreter.
57
51
.SH OPTIONS
58
52
.TP
59
- . B \f[B] \- h \f[ ] / \f[B] \[ en ] help \f[ ]
53
+ \f[B] \- h \f[ R ] , \f[B] \-\- help \f[ R ]
60
54
Print a help message and exit; must be specified on its own.
61
- .RS
62
- .RE
63
55
.TP
64
- .B \f[B] \[en ] list \f[ ]
65
- List all known interpreters (except activated virtual environment); must
66
- be specified on its own.
67
- .RS
68
- .RE
56
+ \f[B] \-\- list \f[ R ]
57
+ List all known interpreters (except virtual environments); must be
58
+ specified on its own.
69
59
.TP
70
- . B \f[B] \- [X] \f[ ]
71
- Launch the latest Python \f[I] X \f[ ] version (e.g.
72
- \f[B] \- 3 \f[ ] for the latest Python 3).
73
- See \f[B] ENVIRONMENT \f[ ] for details on the \f[B] PY_VERSION[X] \f[ ]
60
+ \f[B] \- [X] \f[ R ]
61
+ Launch the latest Python \f[I] X \f[ R ] version (e.g.\ \f[B] \- 3 \f[ R ] for
62
+ the latest Python 3).
63
+ See \f[B] ENVIRONMENT \f[ R ] for details on the \f[B] PY_VERSION[X] \f[ R ]
74
64
environment variable.
75
- .RS
76
- .RE
77
65
.TP
78
- .B \f[B] \- [X.Y] \f[ ]
79
- Launch the specified Python version (e.g.
80
- \f[B] \- 3.6 \f[ ] for Python 3.6).
81
- .RS
82
- .RE
66
+ \f[B] \- [X.Y] \f[ R ]
67
+ Launch the specified Python version (e.g.\ \f[B] \- 3.6 \f[ R ] for Python
68
+ 3.6).
83
69
.SH ENVIRONMENT
84
70
.TP
85
- . B \f[B] PY_PYTHON \f[ ]
71
+ \f[B] PY_PYTHON \f[ R ]
86
72
Specify the version of Python to search for when no Python version is
87
- explicitly requested (must be formatted as `X.Y'; e.g.
88
- \f[B] 3.6 \f[ ] to use Python 3.6 by default).
89
- .RS
90
- .RE
73
+ explicitly requested (must be formatted as `X.Y'; e.g.\ \f[B] 3.6 \f[ R ] to
74
+ use Python 3.6 by default).
91
75
.TP
92
- . B \f[B] PY_PYTHON[X] \f[ ]
76
+ \f[B] PY_PYTHON[X] \f[ R ]
93
77
Specify the version of Python to search for when only a major version is
94
- specified (must be formatted as `X.Y'; e.g.\ set \f[B] PY_PYTHON3 \f[ ] to
95
- \f[B] 3.6 \f[ ] to cause \f[B] \- 3 \f[ ] to use Python 3.6).
96
- .RS
97
- .RE
78
+ specified (must be formatted as `X.Y'; e.g.\ set \f[B] PY_PYTHON3 \f[ R ] to
79
+ \f[B] 3.6 \f[ R ] to cause \f[B] \- 3 \f[ R ] to use Python 3.6).
98
80
.TP
99
- . B \f[B] PYLAUNCH_DEBUG \f[ ]
81
+ \f[B] PYLAUNCH_DEBUG \f[ R ]
100
82
Log details to stderr about how the Launcher is operating.
101
- .RS
102
- .RE
103
83
.TP
104
- . B \f[B] VIRTUAL_ENV \f[ ]
84
+ \f[B] VIRTUAL_ENV \f[ R ]
105
85
Path to a directory containing virtual environment to use when no Python
106
86
version is explicitly requested; typically set by activating a virtual
107
87
environment.
108
- .RS
109
- .RE
110
88
.TP
111
- . B \f[B] PATH \f[ ]
89
+ \f[B] PATH \f[ R ]
112
90
Used to search for Python interpreters.
113
- .RS
114
- .RE
115
91
.SH AUTHORS
116
- .PP
117
92
Copyright © 2018 Brett Cannon.
118
93
.PP
119
94
Licensed under MIT.
120
95
.SH HOMEPAGE
121
- .PP
122
96
https://github.com/brettcannon/python\- launcher/
123
97
.SH SEE ALSO
124
- .PP
125
98
python(1), python3(1).
0 commit comments