Skip to content

Commit

Permalink
Merge branch 'feature/enhance-option-lines' of github.com:tonyseek/pi…
Browse files Browse the repository at this point in the history
…p-tools

Merge latest changes from jazzband#448 PR.

Also updated the Change Log entry.

* 'feature/enhance-option-lines' of github.com:tonyseek/pip-tools:
  Rename "no-trusted-host" to "no-emit-trusted-host"
  • Loading branch information
suutari-ai committed Mar 11, 2017
2 parents 3ad131b + d7ed6d5 commit 23dad68
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# 1.8.1 (unreleased)

- Recalculate secondary dependencies between rounds (#378)
- Add "--emit-trusted-host/--no-trusted-host" option
- Add "--emit-trusted-host/--no-emit-trusted-host" option
- Deduplicate the option lines of output
- Ignore pkg-resources
- Support pinned VCS dependencies
Expand Down
4 changes: 2 additions & 2 deletions piptools/scripts/compile.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ class PipCommand(pip.basecommand.Command):
help="Add header to generated file")
@click.option('--index/--no-index', is_flag=True, default=True,
help="Add index URL to generated file")
@click.option('--emit-trusted-host/--no-trusted-host', is_flag=True, default=True,
help="Add trusted host option to generated file")
@click.option('--emit-trusted-host/--no-emit-trusted-host', is_flag=True,
default=True, help="Add trusted host option to generated file")
@click.option('--annotate/--no-annotate', is_flag=True, default=True,
help="Annotate results, indicating where dependencies come from")
@click.option('-U', '--upgrade', is_flag=True, default=False,
Expand Down
2 changes: 1 addition & 1 deletion piptools/writer.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ def write_header(self):
if not self.emit_index:
params += ['--no-index']
if not self.emit_trusted_host:
params += ['--no-trusted-host']
params += ['--no-emit-trusted-host']
if not self.annotate:
params += ['--no-annotate']
if self.generate_hashes:
Expand Down
4 changes: 2 additions & 2 deletions tests/test_cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -128,10 +128,10 @@ def test_trusted_host_no_emit(pip_conf):
open('requirements.in', 'w').close()
out = runner.invoke(cli, ['-v',
'--trusted-host', 'example.com',
'--no-trusted-host'])
'--no-emit-trusted-host'])
print(out.output)
assert '--trusted-host example.com' not in out.output
assert '--no-trusted-host' in out.output
assert '--no-emit-trusted-host' in out.output


def test_realistic_complex_sub_dependencies(tmpdir):
Expand Down

0 comments on commit 23dad68

Please sign in to comment.