mirror of
https://github.com/kennethreitz/pipenv.git
synced 2026-06-05 22:50:18 +00:00
warn if requested update package is not in Pipfile
Signed-off-by: Kenneth Reitz <me@kennethreitz.org>
This commit is contained in:
@@ -362,6 +362,17 @@ def update(ctx, three=None, python=False, system=False, verbose=False, clear=Fal
|
||||
)
|
||||
else:
|
||||
|
||||
for package in ([package] + list(more_packages) or []):
|
||||
|
||||
if package not in core.project.all_packages:
|
||||
click.echo(
|
||||
'{0}: {1} was not found in your Pipfile! Aborting.'
|
||||
''.format(
|
||||
crayons.red('Warning', bold=True),
|
||||
crayons.green(package, bold=True)
|
||||
), err=True
|
||||
)
|
||||
sys.exit(1)
|
||||
core.ensure_lockfile(keep_outdated=core.project.lockfile_exists)
|
||||
|
||||
# Install the dependencies.
|
||||
|
||||
Reference in New Issue
Block a user