Metadata-Version: 2.5
Name: cargai
Version: 0.1.1
Summary: Toolkit CLI pour installer et gérer des outils tiers liés à l'IA (headroom-ai, ...)
Project-URL: Repository, https://github.com/LionelHARRY/cargai
Project-URL: Issues, https://github.com/LionelHARRY/cargai/issues
Author: Lionel Harry
License-Expression: MIT
License-File: LICENSE
Keywords: ai,cli,installer,llm,toolkit
Classifier: Environment :: Console
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Requires-Python: >=3.9
Requires-Dist: rich>=13
Requires-Dist: tomli>=2; python_version < '3.11'
Requires-Dist: typer>=0.12
Provides-Extra: dev
Requires-Dist: pytest>=8; extra == 'dev'
Description-Content-Type: text/markdown

# cargai

Toolkit CLI pour installer et gérer des outils tiers liés à l'IA, à partir d'un catalogue déclaratif.

## Installation

```bash
# recommandé
uv tool install cargai          # ou depuis le repo : uv tool install .
# alternative
pipx install cargai
```

## Utilisation

```bash
cargai list                         # catalogue + statut d'installation
cargai info headroom                # détails d'un outil
cargai install headroom             # installe headroom-ai[proxy]
cargai install headroom -e all      # avec d'autres extras
cargai install headroom --dry-run   # affiche la commande sans l'exécuter
cargai install headroom -U          # met à jour
cargai uninstall headroom
cargai doctor                       # vérifie uv / pipx / npm / brew
```

Les outils Python sont installés isolément via `uv tool` (ou `pipx` à défaut), chacun dans son propre environnement.

## Ajouter un outil

Chaque outil est un fichier TOML :

- intégré au package : `src/cargai/catalog/<nom>.toml`
- perso (sans modifier le package) : `~/.config/cargai/tools/<nom>.toml` — prioritaire sur le catalogue intégré

```toml
name = "mon-outil"
description = "Ce que fait l'outil."
homepage = "https://..."

[install]
method = "python"        # python | npm | brew
package = "mon-outil"    # nom du package PyPI / npm / formule brew
extras = []              # python uniquement
python = "3.12"          # optionnel, version de Python à utiliser
binaries = ["mon-outil"] # sert à détecter si l'outil est installé

[post_install]
message = "Lance : mon-outil --help"
```

## Développement

```bash
python3 -m venv .venv && source .venv/bin/activate
pip install -e ".[dev]"
pytest
```

## Publication

La publication sur PyPI est automatisée par GitHub Actions (`.github/workflows/publish.yml`),
via le Trusted Publishing de PyPI (aucun jeton à gérer). Pour sortir une version :

1. Mettre à jour `__version__` dans `src/cargai/__init__.py` (seule source de la version).
2. Committer, puis tagger et pousser :
   ```bash
   git tag -a v0.2.0 -m "cargai 0.2.0" && git push origin main v0.2.0
   ```

Le workflow lance les tests, vérifie que le tag correspond à la version, publie sur PyPI
et crée la release GitHub.

## Licence

MIT — voir [LICENSE](LICENSE).
