> For the complete documentation index, see [llms.txt](https://viva.gitbook.io/project/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://viva.gitbook.io/project/kai-fa/python/gong-ju/pip.md).

# pip

python包管理工具

### 快速上手

1、安装 pip 工具

{% tabs %}
{% tab title="Ubuntu" %}

```
apt install python3-pip
```

{% endtab %}
{% endtabs %}

2、更新 pip 工具

```
pip3 install -i https://pypi.tuna.tsinghua.edu.cn/simple pip -U
```

3、配置 pip 源

```
pip3 config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple
```

### 使用

通过requirements.txt文件安装python依赖包

```
pip3 install -r requirements.txt
```
