A PDM plugin to install project dependencies with Conda
Project description
pdm-conda
A PDM plugin to install project dependencies with Conda.
Configuration
Config item | Description | Default value | Possible values |
---|---|---|---|
conda.runner |
Conda runner executable | conda |
conda , mamba , micromamba |
conda.channels |
Conda channels to use, order will be enforced | [] |
|
conda.as_default_manager |
Use Conda to install all possible requirements | False |
|
conda.dependencies |
Array of dependencies to install with Conda, analogue to project.dependencies |
[] |
|
conda.optional-dependencies |
Groups of optional dependencies to install with Conda, analogue to project.optional-dependencies |
{} |
|
conda.dev-dependencies |
Groups of development dependencies to install with Conda, analogue to tool.pdm.dev-dependencies |
{} |
|
conda.pypi-mapping.download-dir |
PyPI-Conda mapping download directory | $HOME/.pdm-conda/ |
All configuration items use prefix pdm.tool
, this is a viable configuration:
[tool.pdm.conda]
runner = "micromamba"
channels = ["conda-forge/noarch", "conda-forge", "anaconda"]
dependencies = ["pdm"]
as_default_manager = true
[tool.pdm.conda.pypi-mapping]
download-dir = "/tmp"
[tool.pdm.conda.optional-dependencies]
extra = ["anaconda:ffmpeg"] # non python dependency, obtained from anaconda channel
[tool.pdm.conda.dev-dependencies]
dev = ["pytest"]
Usage
This plugin modifies PDM commands so after adding configuration to the pyproject file it's done.
Working commands
The following commands were tested and work:
pdm lock
pdm install
pdm add
:- To add a Conda managed package
--conda
flag can be used multiple times followed a package (analogue to--editable
). - You can specify per package Conda channel using conda notation
channel::package
. - You also can specify a default Conda channel with
-c
or--channel
. - With flag
-r
or--runner
you can specify the Conda runner to use.
- To add a Conda managed package
pdm remove
pdm list
Development
For development docker-compose
files exist in deploy
directory, helper script deploy/docker-compose.sh
can be used
for executing docker.
For running dev environment:
bash deploy/docker-compose.sh -d up
And for productive environment:
bash deploy/docker-compose.sh up
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
pdm-conda-0.4.0.tar.gz
(27.5 kB
view hashes)
Built Distribution
pdm_conda-0.4.0-py3-none-any.whl
(22.4 kB
view hashes)
Close
Hashes for pdm_conda-0.4.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7c9bd186fbc14e011ed53857785413d697185ca6ea0760c72fbb318e0af8bb40 |
|
MD5 | 9da1bdc6c72de6baba7b8bb802555719 |
|
BLAKE2b-256 | 719d4d46125032fb1bcda2c94517e2a710b14cd5bc81d04f745a27cf540024f6 |