Architekt
I am equipped to address your inquiries across these dimensions without necessitating further explanations.
Unterstützt dich bei Claude Code Statusline Design mit strukturierten Schritten, klaren Anforderungen und umsetzbaren Ergebnissen für schnellere, s...
You are a systems programmer creating a highly-optimized status bar script for Claude Code.
A single-file Python script (~/.claude/statusline.py) that displays developer-critical information in Claude Code's status line.
Read JSON from stdin with this structure:
{
"model": {"display_name": "Opus|Sonnet|Haiku"},
"workspace": {"current_dir": "/path/to/workspace", "project_dir": "/path/to/project"},
"output_style": {"name": "explanatory|default|concise"},
"cost": {
"total_cost_usd": 0.0,
"total_duration_ms": 0,
"total_api_duration_ms": 0,
"total_lines_added": 0,
"total_lines_removed": 0
}
}
\033[38;5;208mOpus\033[0m \033[38;5;33mIsaacLab\033[0m \033[38;5;154mmain\033[0m \033[38;5;245m●\033[0m \033[38;5;245mA:12%\033[0m
Execution time: < 100ms (called every 300ms)
Cache persistence: Store Git status cache in /tmp/claude_statusline_cache.json (script exits after each run, so cache must persist on disk)
Cache TTL: Refresh Git file counts only when cache age > 5 seconds OR .git/index mtime changes
Git logic optimization:
Branch name: Read .git/HEAD directly (no subprocess)
File counts: Call subprocess.run(['git', 'status', '--porcelain']) ONLY when cache expires
Standard library only: No external dependencies (use only sys, json, os, pathlib, subprocess, time)
{
"statusLine": {
"type": "command",
"command": "~/.claude/statusline.py",
"padding": 0
}
}
This is a "developer professional" style status bar. It prioritizes:
I am equipped to address your inquiries across these dimensions without necessitating further explanations.
Build a Kanban project management board using HTML5, CSS3, and JavaScript.
Develop a web-based image editor using HTML5 Canvas, CSS3, and JavaScript.
ℹ️ Dieser Prompt stammt aus der Open-Source-Community-Sammlung prompts.chat und steht unter der CC0-Lizenz (Public Domain). Kostenlos für jeden Einsatz.