mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-05-04 20:45:49 +08:00
Mention uv for the initial install in CONTRIBUTING.md (#13595)
This commit is contained in:
+53
-23
@@ -50,37 +50,67 @@ please refer to this
|
||||
|
||||
Note that some tests require extra setup steps to install the required dependencies.
|
||||
|
||||
### Linux/Mac OS/WSL
|
||||
<table>
|
||||
<tr>
|
||||
<td>Linux / macOS / WSL</td>
|
||||
<td>
|
||||
|
||||
On Linux and Mac OS, you will be able to run the full test suite on Python
|
||||
3.9-3.12.
|
||||
To install the necessary requirements, run the following commands from a
|
||||
terminal window:
|
||||
On Linux and macOS, you will be able to run the full test suite on Python
|
||||
3.9-3.12.
|
||||
To install the necessary requirements, run the following commands from a
|
||||
terminal window:
|
||||
|
||||
```bash
|
||||
$ python3 -m venv .venv
|
||||
$ source .venv/bin/activate
|
||||
(.venv)$ pip install -U pip
|
||||
(.venv)$ pip install -r requirements-tests.txt
|
||||
```
|
||||
```bash
|
||||
$ python3 -m venv .venv
|
||||
$ source .venv/bin/activate
|
||||
(.venv)$ pip install -U pip
|
||||
(.venv)$ pip install -r requirements-tests.txt
|
||||
```
|
||||
|
||||
### Windows
|
||||
</td>
|
||||
</tr>
|
||||
<tr><!-- disables zebra striping --></tr>
|
||||
<tr>
|
||||
<td>Windows</td>
|
||||
<td>
|
||||
|
||||
Run the following commands from a Windows terminal to install all requirements:
|
||||
Run the following commands from a Windows terminal to install all requirements:
|
||||
|
||||
```powershell
|
||||
> python -m venv .venv
|
||||
> .venv\Scripts\activate
|
||||
(.venv) > pip install -U pip
|
||||
(.venv) > pip install -r "requirements-tests.txt"
|
||||
```
|
||||
```powershell
|
||||
> python -m venv .venv
|
||||
> .venv\Scripts\activate
|
||||
(.venv) > pip install -U pip
|
||||
(.venv) > pip install -r requirements-tests.txt
|
||||
```
|
||||
|
||||
To be able to run pytype tests, you'll also need to install it manually
|
||||
To be able to run pytype tests, you'll also need to install it manually
|
||||
as it's currently excluded from the requirements file:
|
||||
|
||||
```powershell
|
||||
(.venv) > pip install -U pytype
|
||||
```
|
||||
```powershell
|
||||
(.venv) > pip install -U pytype
|
||||
```
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr><!-- disables zebra striping --></tr>
|
||||
<tr>
|
||||
<td>Using uv</td>
|
||||
<td>
|
||||
|
||||
If you already have [uv](https://docs.astral.sh/uv/getting-started/installation/) installed, you can simply replace the commands above with:
|
||||
|
||||
```shell
|
||||
uv venv
|
||||
uv pip install -r requirements-tests.txt
|
||||
```
|
||||
|
||||
```shell
|
||||
uv pip install -U pytype
|
||||
```
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
## Code formatting
|
||||
|
||||
|
||||
Reference in New Issue
Block a user