claude-launcher-profiles/README.md

121 lines
2.1 KiB
Markdown
Raw Permalink Normal View History

2026-06-28 01:50:13 +02:00
# claude-launcher-profiles
Portable Claude Code launcher profiles for Anthropic Pro and OpenRouter models.
## Ziel
Claude Code über einfache Profile starten:
- `claude-pro`
- `claude-glm`
- `claude-kimi`
- `claude-free`
- `claude-profile <name>`
Die eigentliche Konfiguration der Modelle liegt in einer YAML-Datei.
Der OpenRouter-API-Key kommt aus der Shell-Umgebung.
2026-06-28 01:50:13 +02:00
## Voraussetzungen
- `claude` installiert
- funktionierendes Claude-Pro-Login für das `pro`-Profil
- `bash`
- `yq` zum Parsen der YAML-Datei
Beispiel Debian/Ubuntu:
```bash
sudo apt-get update
sudo apt-get install -y yq
```
## Setup
```bash
git clone https://kitux.de/forgejo/dschlueter/claude-launcher-profiles.git
cd claude-launcher-profiles
cp config/profiles.example.yml config/profiles.yml
$EDITOR config/profiles.yml
chmod +x bin/claude-profile bin/install-claude-profiles lib/profiles.sh
./bin/install-claude-profiles
source ~/.bashrc
```
## OpenRouter-Key setzen
Der OpenRouter-Key wird **nicht** in `config/profiles.yml` gespeichert.
Stattdessen wird er über die Shell-Umgebung gesetzt.
Temporär für die aktuelle Session:
```bash
export OPENROUTER_API_KEY="sk-or-v1-..."
```
Dauerhaft in `~/.bashrc`:
```bash
export OPENROUTER_API_KEY="sk-or-v1-..."
source ~/.bashrc
```
2026-06-28 01:50:13 +02:00
## Nutzung
```bash
claude-pro
claude-glm
claude-kimi
claude-free
```
Oder generisch:
```bash
claude-profile pro
claude-profile glm
claude-profile kimi
claude-profile free
```
## Konfiguration
Die Datei `config/profiles.yml` enthält nur noch:
- den Startbefehl für Claude Code,
- die OpenRouter-Base-URL,
- die Profile,
- die Modellnamen.
Beispiel:
```yaml
defaults:
claude_cmd: "claude"
openrouter_base_url: "https://openrouter.ai/api"
profiles:
pro:
mode: "pro"
glm:
mode: "openrouter"
model: "z-ai/glm-5.2"
kimi:
mode: "openrouter"
model: "moonshotai/kimi-k2.7-code"
free:
mode: "openrouter"
model: "openrouter/free"
2026-06-28 01:50:13 +02:00
```
## Sicherheit
`config/profiles.yml` enthält lokale Einstellungen und bleibt unversioniert.
Nur `config/profiles.example.yml` gehört ins Repository.
Keine echten API-Keys committen.
2026-06-28 01:50:13 +02:00