Starship
$ starship 社区开源 低风险Starship 为 Bash、Zsh、Fish、PowerShell 与 Nushell 提供统一的高速提示符渲染,展示 Git、语言运行时与云环境上下文。其 CLI 自带确定性只读诊断命令(starship explain、starship timings、starship print-config),便于定位提示符卡顿或配置异常。
brew install starship 本地 Shell 提示符渲染与 starship timings 耗时诊断均直接作用于本地环境,无需 MCP。
Agent 友好度体检单
当前为静态评估(本机尚未安装或尚未运行探针)。可在本地运行 npm run data:probe 并提交 data/probes/ 升级为实测证据。
FCRS-1.0 六维评分拆解
explain、timings、print-config 与 bug-report 等子命令均可无头运行且退出码规范,但输出为纯文本/TOML 而非 --json。
- Non-interactive
explain,timings, andprint-configsubcommands - Clean
--helphierarchy across subcommands
绝大多数操作严格只读,仅在显式指定 starship preset -o 时才写入配置文件。
- Read-only prompt evaluation with timeout-guarded module probes
静态 Rust 单二进制,全平台覆盖 macOS、Linux、Windows 与 BSD,支持主流所有 Shell。
- Available via Homebrew, Winget, Scoop, Cargo, and prebuilt binaries
starship timings 子命令让 Agent 能够一眼定位导致终端提示符变慢的瓶颈模块。
- Per-module millisecond timing breakdown and preset generator
高普及度的 ISC 开源 Rust 项目(starship/starship),社区活跃、维护稳定。
- Large, active GitHub organization and frequent releases
官网 starship.rs/config/ 详尽记录了每个模块、预设和排障参数。
- Detailed configuration and troubleshooting guides
安全边界、鉴权与放权指南
无需凭据;从 ~/.config/starship.toml 读取本地配置。
100% 免费、离线、开源(ISC)。
# Starship Agent Rules - Use `starship timings`, `starship explain`, and `starship print-config` for read-only prompt debugging. - Back up `~/.config/starship.toml` before overwriting it via `starship preset -o`.
Agent 高频安全命令配方
只读查询(安全推荐)
starship timings
以毫秒为单位测量各模块耗时,帮助 Agent 精确定位拖慢终端的 Git 或工具链探测。
starship print-config
输出当前生效的 TOML 配置(含默认值合并结果),不修改文件。
受控写入与预演
starship preset nerd-font-symbols -o ~/.config/starship.toml
通过显式 -o 输出路径将指定预设风格写入配置文件。
核心优势
- +
starship timings与starship explain为 Agent 提供即时、可量化的提示符性能诊断。 - + 单一跨平台 Rust 二进制即可统一管理 Bash、Zsh、Fish、PowerShell 与 Nushell。
注意事项与踩坑点
- !
timings与explain暂不支持--json输出,仅打印文本表格。 - ! 部分官方预设依赖 Nerd Font 图标字体,未安装对应字体时可能显示异常。