Skip to content

Commit

Permalink
Merge pull request #3348 from refack/verbose-run
Browse files Browse the repository at this point in the history
Enable output of script line for 'run' in verbose mode
  • Loading branch information
techalchemy authored Dec 9, 2018
2 parents 7a2bdfe + 670b010 commit 51b46c9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions news/3348.feature.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Added support for ``--verbose`` output to ``pipenv run``.
3 changes: 3 additions & 0 deletions pipenv/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -2303,6 +2303,9 @@ def do_run(command, args, three=None, python=False, pypi_mirror=None):
inline_activate_virtual_environment()
try:
script = project.build_script(command, args)
cmd_string = ' '.join([script.command] + script.args)
if environments.is_verbose():
click.echo(crayons.normal("$ {0}".format(cmd_string)), err=True)
except ScriptEmptyError:
click.echo("Can't run script {0!r}-it's empty?", err=True)
if os.name == "nt":
Expand Down

0 comments on commit 51b46c9

Please sign in to comment.