Skip to content

kelvinou01/conda-which

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

26 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

conda-which

Which package does this file belong to?

➜ conda activate my-env
(my-env) ➜ cd /path/to/my-env/bin
(my-env) ➜ conda which ./zstd
File '/path/to/my-env/bin/zstd' belongs to
  📦 Package: zstd-1.5.6-hb46c0d2_0
  🌏 Environment: /path/to/my-env

Installation

Using conda-forge (recommended)

  1. Ensure you have conda-forge added as a channel:

    conda config --add channels conda-forge
  2. Install the plugin using conda:

    conda install conda-which

Using pip

  1. Clone the repository:

    git clone https://github.com/kelvinou01/conda-which.git
  2. Navigate to the repository directory:

    cd conda-which
  3. With the target conda environment activated, install the plugin using pip:

    pip install -e .

Usage

# Full path
conda which /path/to/my-env/bin/zstd

cd /path/to/my-env
# Relative path
conda which bin/zstd
# Multiple files
conda which bin/zstd bin/ahost lib/cmake/OpenSSL/OpenSSLConfig.cmake

Local development

Test changes

conda activate dev-env
pip install -e .
conda which /path/to/file  # Changes to conda-which will immediately show up

Run tests with a conda environment

conda env create -f tests/environment.yml
conda activate test
pytest tests/test.py

Run actions in a docker container with act

act -j 'test' --container-architecture linux/amd64 -vv

About

Which package does this file belong to?

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages