If I have a directory with setup.py
, in pip
, I can pip install .
in the directory to install the package.
What if I am using conda
?
conda install .
makes conda
to find a package named dot.
conda
packages are a different structure than standard python packaging. As a result, the official, recommended and best-practice approach is to use conda
to install pip
within an activated conda
environment, and use that to install standard packages:
conda install pip
NOTE: You want to use conda
packages whenever they're available, as they have more features within a conda
environment than non-conda
packages.
conda install pip
will install pip within the currently activated conda
environment, and will ensure that it is integrated with conda
so that, for example, conda list
, will include any packages installed with pip
.
NOTE: Commands like conda update
will ignore pip
installed packages, as it only checks conda
channels
for available updates, so they still need to be updated using pip
. See this Question/Answer discussion:
Does conda update packages from pypi installed using pip install?
NOTE: See @kalefranz comment below regarding conda
4.6 experimental handling of packages.
If you're interested in creating your own conda
package(s), take a look at this question/1st answer for a great run-down:
How to install my own python module (package) via conda and watch its changes
If you simply wish to install non-conda
packages, using pip
is the correct, and expected, way to go.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With