Skip to main content

uv2conda

PyPI

Tiny Python package to create a conda environment file from a Python project using uv.

Assuming you have installed uv:

uvx uv2conda \
    --project-dir "/path/to/my/project/" \
    --name "my_conda_env_name" \
    --python "3.12.7" \
    --conda-env-file "my_conda_env.yaml" \
    --requirements-file "requirements.txt" \
    --uv-args "--prerelease=allow"

Or, in Python:

from uv2conda import CondaEnvironment

environment = CondaEnvironment.from_project_dir(
    project_dir="/path/to/my/project/",
    name="my_conda_env_name",
    python_version="3.12.7",
    uv_args=["--prerelease=allow"],
)
environment.to_pip_requirements_file("requirements.txt")
environment.to_yaml("environment.yaml")

Example for this library:

$ uv2conda --python 3.12.7
name: uv2conda
dependencies:
  - python=3.12.7
  - pip
  - pip:
      - click==8.1.7
      - colorama==0.4.6 ; sys_platform == 'win32' or platform_system == 'Windows'
      - loguru==0.7.2
      - markdown-it-py==3.0.0
      - mdurl==0.1.2
      - packaging==24.2
      - pygments==2.18.0
      - pyyaml==6.0.2
      - rich==13.9.4
      - shellingham==1.5.4
      - typer==0.15.1
      - typing-extensions==4.12.2
      - win32-setctime==1.1.0 ; sys_platform == 'win32'

Related projects

Metadata

Release files for uv2conda 1.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for uv2conda 1.0.1
File Size Uploaded
uv2conda-1.0.1.tar.gz 8.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for uv2conda 1.0.1
File Interpreter ABI Platform
uv2conda-1.0.1-py3-none-any.whl Python 3 none any Details

Total release size: 16.9 kB

Release files / uv2conda-1.0.1.tar.gz

Download URL uv2conda-1.0.1.tar.gz
Size 8.8 kB
Tags Source
SHA-256 checksum
How to use checksums
a47bdd3a36e2e25136d5204230176dedbe6ab6053d8b9b6997551b06126de9e5
BLAKE2b-256 checksum
How to use checksums
11c1c9707c3d8473de0c30c32381f329fbb6859fd1f8b514b6feb8f51ad100be
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.5.9

Release files / uv2conda-1.0.1-py3-none-any.whl

Download URL uv2conda-1.0.1-py3-none-any.whl
Size 8.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
cde3fa896c36e69d2489f1c4d1511fe78d8fc922b49f18b46d1ba6fd40dd67d9
BLAKE2b-256 checksum
How to use checksums
34107c641868bec668090a16417d9f0cb94ac6f81d9448be2de34dc0e348dc7a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.5.9

Release history Release notifications | RSS feed

This release

1.0.1 This release

2 release files

1.0.0

2 release files

0.1.8

2 release files

0.1.7

2 release files

0.1.6

2 release files

0.1.5

2 release files

0.1.4

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page