diff --git a/docs/html/reference/pip_install.rst b/docs/html/reference/pip_install.rst index bd61151d7..9b5303e2b 100644 --- a/docs/html/reference/pip_install.rst +++ b/docs/html/reference/pip_install.rst @@ -934,6 +934,17 @@ Examples $ pip install --pre SomePackage + +#. Install packages from source. + + Do not use any binary packages:: + + $ pip install SomePackage1 SomePackage2 --no-binary :all: + + Specify ``SomePackage1`` to be installed from source:: + + $ pip install SomePackage1 SomePackage2 --no-binary SomePackage1 + ---- .. [1] This is true with the exception that pip v7.0 and v7.0.1 required quotes diff --git a/news/3191.doc b/news/3191.doc new file mode 100644 index 000000000..513cf2d0a --- /dev/null +++ b/news/3191.doc @@ -0,0 +1 @@ +Clarify the usage of --no-binary command. diff --git a/src/pip/_internal/cli/cmdoptions.py b/src/pip/_internal/cli/cmdoptions.py index 79958550e..4cbd5abf2 100644 --- a/src/pip/_internal/cli/cmdoptions.py +++ b/src/pip/_internal/cli/cmdoptions.py @@ -475,12 +475,12 @@ def no_binary(): "--no-binary", dest="format_control", action="callback", callback=_handle_no_binary, type="str", default=format_control, - help="Do not use binary packages. Can be supplied multiple times, and " - "each time adds to the existing value. Accepts either :all: to " - "disable all binary packages, :none: to empty the set, or one or " - "more package names with commas between them (no colons). Note " - "that some packages are tricky to compile and may fail to " - "install when this option is used on them.", + help='Do not use binary packages. Can be supplied multiple times, and ' + 'each time adds to the existing value. Accepts either ":all:" to ' + 'disable all binary packages, ":none:" to empty the set (notice ' + 'the colons), or one or more package names with commas between ' + 'them (no colons). Note that some packages are tricky to compile ' + 'and may fail to install when this option is used on them.', ) @@ -491,12 +491,12 @@ def only_binary(): "--only-binary", dest="format_control", action="callback", callback=_handle_only_binary, type="str", default=format_control, - help="Do not use source packages. Can be supplied multiple times, and " - "each time adds to the existing value. Accepts either :all: to " - "disable all source packages, :none: to empty the set, or one or " - "more package names with commas between them. Packages without " - "binary distributions will fail to install when this option is " - "used on them.", + help='Do not use source packages. Can be supplied multiple times, and ' + 'each time adds to the existing value. Accepts either ":all:" to ' + 'disable all source packages, ":none:" to empty the set, or one ' + 'or more package names with commas between them. Packages ' + 'without binary distributions will fail to install when this ' + 'option is used on them.', )