Metadata-Version: 2.1
Name: whl2conda
Version: 24.1.2
Summary: Build conda packages directly from pure python wheels
Project-URL: homepage, https://github.com/analog-cbarber/whl2conda
Project-URL: repository, https://github.com/analog-cbarber/whl2conda
Project-URL: documentation, https://zuzukin.github.io/whl2conda/
Author-email: Christopher Barber <christopher.barber@analog.com>
License-Expression: Apache-2.0
License-File: LICENSE.md
Keywords: build,conda,wheel
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Software Development :: Build Tools
Requires-Python: >=3.8
Requires-Dist: conda-package-handling>=2.2
Requires-Dist: platformdirs>=3.10
Requires-Dist: pyyaml>=6.0
Requires-Dist: tomlkit>=0.12
Requires-Dist: wheel>=0.41
Description-Content-Type: text/markdown

# whl2conda 

[![pypi version](https://img.shields.io/pypi/v/whl2conda.svg)](https://pypi.org/project/whl2conda/)
[![conda version](https://img.shields.io/conda/vn/conda-forge/whl2conda)](https://anaconda.org/conda-forge/whl2conda)
[![documentation](https://img.shields.io/badge/docs-mkdocs%20material-blue.svg?style=flat)](https://zuzukin.github.io/whl2conda/)  
![PyPI - Python Version](https://img.shields.io/pypi/pyversions/whl2conda)
![GitHub](https://img.shields.io/github/license/analog-cbarber/whl2conda)  
[![CI](https://github.com/zuzukin/whl2conda/actions/workflows/python-package-conda.yml/badge.svg)](https://github.com/zuzukin/whl2conda/actions/workflows/python-package-conda.yml) [![codecov](https://codecov.io/gh/zuzukin/whl2conda/graph/badge.svg?token=097C3MBNIX)](https://codecov.io/gh/zuzukin/whl2conda)
![GitHub issues](https://img.shields.io/github/issues/analog-cbarber/whl2conda)


**Generate conda packages directly from pure python wheels**

*whl2conda* is a command line utility to build and test conda packages
generated directly from pure python wheels.

* **Performance**: because it does not need to create conda environments
    in order to build, this is *much* faster than solutions involving *conda-build*.

* **Dependency renaming**: renames pypi package dependencies to their 
    corresponding conda name. Automatically renames packages from known
    list collected from conda-forge and supports user-specified rename
    patterns as well.

* **Multiple package formats**: can generate both V1 ('.tar.bz2') and V2 ('.conda')
    conda package formats. Can also generate a unpacked directory tree for debugging
    or additional user customization.

* **Project configuration**: *whl2conda* project-specific options can be read from
    project's `pyproject.toml` file.

* **Test install support**: supports installing conda package into a conda
    environment for testing prior to deployment.

* **Hides pypi dependencies**: rewrites the original pip/pypi dependencies in the
    installed dist-info to avoid [compatibility issues](https://zuzukin.github.io/whl2conda/latest/guide/renaming.html#hide-pip).


## Installation

With pip:

```bash
pip install whl2conda
```

With conda (upcoming):

```bash
conda install -c conda-forge whl2conda
```

## Quick usage

Generate a conda package in same directory as wheel file:

```bash
whl2conda build dist/mypackage-1.2.3-py3-none-any.whl
```

Add default tool options to `pyproject.toml`

```bash
whl2conda config --generate-pyproject pyproject.toml
```
Build both wheel and conda package for project:

```bash
whl2conda build --build-wheel my-project-root
```

Create python 3.10 test environment for generated conda package:

```bash
whl2conda install dist/mypackage-1.2.3.-py_0.conda --create -n testenv \
  --extra pytest python=3.10
```
