Skip to content
  • Bill Ryder @bill.ryder.nz ·

    You could do it this way if you want to use awk

    pip download $PACKAGE -d /tmp --no-binary :all: | awk '/Collecting/ && $2 !~ /'${PACKAGE}'([~=!<>]|$)/ { print $2 }'

    But the snippet was very helpful though - thanks for sharing.

    Edited by Bill Ryder
  • Thanks! But this doesn't clean up after itself and it doesn't check for dependencies of the dependencies. Try using https://pypi.org/project/johnnydep/

    Edited by Andrew Lamarra
  • Bill Ryder @bill.ryder.nz ·

    Oh interesting.

    I've switched to using this now

    https://pypi.org/project/pipgrip/

    I particularly like the json output since I'm a big fan of https://stedolan.github.io/jq/

0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment