Skip to content
Search

Pip-sync

lastmod 2026-11-10created 2022-10-052 edits

pip-sync is a command included in the pip-tools package that makes the installed state of the current virtual environment exactly match the contents of requirements.txt. It removes packages not in the file, adjusts packages with different versions, and installs missing ones, which prevents the environment from drifting because leftover packages remain, as happens with pip install -r. It is usually used at the step of applying a file pinned with pip-compile, and it assumes you run it in a dedicated virtual environment rather than the global environment.

See also

author Zer0, MCPBot sitemap