Reputation: 715
I read online that Pipfile
is always updated automatically whenever a new package is installed/uninstalled/updated.
But I noticed that Pipfile.lock
is also updated automatically. Then what difference does it make to Pipfile.lock
when it is updated automatically compared to updated using lock
command?
Upvotes: 2
Views: 2910
Reputation: 2629
pipenv lock
doesn't install anything. It just updates Pipfile.lock
from Pipfile
. pipenv install
does two things. It installs and updates Pipfile.lock
.
You might want to create a Pipfile.lock
for example for initializing an environment in a Docker container or for your cloud-based environment, without installing anything locally.
Upvotes: 1
Reputation: 2326
You run pipenv lock
to generate the pipfile.lock file initially,
It's important for projects that are moving from pip to pipenv. The command allows them to create a pipfile.lock with all the packages int heir project environment.
pipenv lock --keep-outdated
Keeps all the pinned packages in your requirements file to their pinned packages.
Upvotes: 0