File tree 5 files changed +87
-5
lines changed
src/pip/_internal/commands
5 files changed +87
-5
lines changed Original file line number Diff line number Diff line change @@ -23,6 +23,13 @@ pip_freeze
23
23
pip_check
24
24
```
25
25
26
+ ``` {toctree}
27
+ :maxdepth: 1
28
+ :caption: Resolving dependencies
29
+
30
+ pip_lock
31
+ ```
32
+
26
33
``` {toctree}
27
34
:maxdepth: 1
28
35
:caption: Handling Distribution Files
Original file line number Diff line number Diff line change
1
+
2
+ .. _`pip lock` :
3
+
4
+ ========
5
+ pip lock
6
+ ========
7
+
8
+
9
+
10
+ Usage
11
+ =====
12
+
13
+ .. tab :: Unix/macOS
14
+
15
+ .. pip-command-usage :: lock "python -m pip"
16
+
17
+ .. tab :: Windows
18
+
19
+ .. pip-command-usage :: lock "py -m pip"
20
+
21
+
22
+ Description
23
+ ===========
24
+
25
+ .. pip-command-description :: lock
26
+
27
+ Options
28
+ =======
29
+
30
+ .. pip-command-options :: lock
31
+
32
+ .. pip-index-options :: lock
33
+
34
+
35
+ Examples
36
+ ========
37
+
38
+ #. Emit a ``pylock.toml `` for the the project in the current directory
39
+
40
+ .. tab :: Unix/macOS
41
+
42
+ .. code-block :: shell
43
+
44
+ python -m pip lock -e .
45
+
46
+ .. tab :: Windows
47
+
48
+ .. code-block :: shell
49
+
50
+ py -m pip lock -e .
Original file line number Diff line number Diff line change
1
+ :orphan:
2
+
3
+ ========
4
+ pip-lock
5
+ ========
6
+
7
+ Description
8
+ ***********
9
+
10
+ .. pip-command-description :: lock
11
+
12
+ Usage
13
+ *****
14
+
15
+ .. pip-command-usage :: lock
16
+
17
+ Options
18
+ *******
19
+
20
+ .. pip-command-options :: lock
Original file line number Diff line number Diff line change @@ -34,6 +34,9 @@ pip-uninstall(1)
34
34
pip-freeze(1)
35
35
Output installed packages in requirements format.
36
36
37
+ pip-lock(1)
38
+ Generate a lock file for requirements and their dependencies.
39
+
37
40
pip-list(1)
38
41
List installed packages.
39
42
Original file line number Diff line number Diff line change 26
26
27
27
class LockCommand (RequirementCommand ):
28
28
"""
29
- Lock packages from:
29
+ EXPERIMENTAL - Lock packages and their dependencies from:
30
30
31
31
- PyPI (and other indexes) using requirement specifiers.
32
32
- VCS project urls.
33
33
- Local project directories.
34
34
- Local or remote source archives.
35
35
36
- pip also supports locking from "requirements files", which provide
37
- an easy way to specify a whole environment to be installed.
36
+ pip also supports locking from "requirements files", which provide an easy
37
+ way to specify a whole environment to be installed.
38
+
39
+ The generated lock file is only guaranteed to be valid for the current
40
+ python version and platform.
38
41
"""
39
42
40
43
usage = """
44
+ %prog [options] [-e] <local project path> ...
41
45
%prog [options] <requirement specifier> [package-index-options] ...
42
46
%prog [options] -r <requirements file> [package-index-options] ...
43
- %prog [options] [-e] <vcs project url> ...
44
- %prog [options] [-e] <local project path> ...
45
47
%prog [options] <archive url/path> ..."""
46
48
47
49
def add_options (self ) -> None :
You can’t perform that action at this time.
0 commit comments