Re: [PATCH] dt-bindings: pip command elaboration

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Aug 12, 2020 at 1:06 AM Linus Walleij <linus.walleij@xxxxxxxxxx> wrote:
>
> pip is now for most practical set-ups implied to be pip3, so
> just use "pip" rather than "pip3" in the instructions.

Are you sure about that? A fresh ubuntu 20.04 install for me defaulted
to python2 for 'python' and 'pip'. From what I've read, that should
always be the case. Anything expressly needing python3 should be
explicit. But then ubuntu has python-is-python2 and python-is-python3
packages to set the default, so I'm confused... (I was trying to
figure out what to do with spdxcheck.py which broke on 20.04 because
the new version of the 'git' python module is python3 only and
spdxcheck.py was using python2.)

In any case, pip3 always works and pip may or may not work. So I think
the answer here is obvious.

> Pass --user explicitly in the example so it is clear that this
> gets installed in the user home directory.
>
> Add an additional instruction on how to upgrade the project,
> not everyone is aware of how pip works.

BTW, releases are now on PyPi, so you can do just 'pip3 install
dtschema'. I've been meaning to update this doc with that.


>
> Signed-off-by: Linus Walleij <linus.walleij@xxxxxxxxxx>
> ---
>  Documentation/devicetree/writing-schema.rst | 7 ++++++-
>  1 file changed, 6 insertions(+), 1 deletion(-)
>
> diff --git a/Documentation/devicetree/writing-schema.rst b/Documentation/devicetree/writing-schema.rst
> index 8c74a99f95e2..a9cebfca8d31 100644
> --- a/Documentation/devicetree/writing-schema.rst
> +++ b/Documentation/devicetree/writing-schema.rst
> @@ -115,11 +115,16 @@ The DT schema project must be installed in order to validate the DT schema
>  binding documents and validate DTS files using the DT schema. The DT schema
>  project can be installed with pip::
>
> -    pip3 install git+https://github.com/devicetree-org/dt-schema.git@master
> +    pip install --user git+https://github.com/devicetree-org/dt-schema.git@master
>
>  Several executables (dt-doc-validate, dt-mk-schema, dt-validate) will be
>  installed. Ensure they are in your PATH (~/.local/bin by default).
>
> +We sometimes update th DT schema project, and then you can simply add the
> +"--upgrade" option to the above command to get to the latest version:
> +
> +    pip install --user --upgrade git+https://github.com/devicetree-org/dt-schema.git@master
> +
>  dtc must also be built with YAML output support enabled. This requires that
>  libyaml and its headers be installed on the host system. For some distributions
>  that involves installing the development package, such as:
> --
> 2.26.2
>



[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux