openlogs-server-logs

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Openlogs Server Logs

Openlogs 服务器日志

Use
openlogs tail
to retrieve recent server logs before asking the user to paste anything. Prefer the cleaned text log unless ANSI or raw terminal bytes matter.
在让用户粘贴任何内容之前,先使用
openlogs tail
获取近期服务器日志。除非需要ANSI代码或原始终端字节,否则优先选择清理后的文本日志。

Quick Start

快速开始

  • Run
    openlogs tail -n 200
    to inspect the latest run in the project.
  • If the user mentions a specific command or service, run
    openlogs tail <query> -n 200
    to get the most recent matching run.
  • Use
    ol tail -n 200
    if the short alias is preferred.
  • Read
    .openlogs/latest.txt
    directly only when file access is simpler than spawning the command and you specifically want the latest overall run.
  • Use
    openlogs tail --raw -n 200
    only when color codes, cursor control, or exact terminal output matters.
  • Use
    openlogs tail -f
    for live follow mode.
  • 运行
    openlogs tail -n 200
    查看项目中最近一次运行的日志。
  • 如果用户提到特定命令或服务,运行
    openlogs tail <query> -n 200
    获取最近一次匹配该查询的运行日志。
  • 如果偏好短别名,可使用
    ol tail -n 200
  • 仅当直接访问文件比执行命令更简单,且你明确需要查看最近一次整体运行日志时,才直接读取
    .openlogs/latest.txt
  • 仅当需要颜色代码、光标控制或精确终端输出时,使用
    openlogs tail --raw -n 200
  • 使用
    openlogs tail -f
    进入实时跟踪模式。

Workflow

工作流程

  1. Try
    openlogs tail -n 200
    .
  2. If the user names a command or service, try
    openlogs tail <query> -n 200
    .
  3. If that fails, try
    ol tail -n 200
    .
  4. If the CLI is unavailable but the workspace is accessible, read
    .openlogs/latest.txt
    or the matching command-specific file in
    .openlogs/
    .
  5. If the log directory is missing, check whether the server was started with
    openlogs <command>
    or
    ol <command>
    .
  6. If it was not, tell the user to relaunch the server through openlogs, then inspect the resulting logs.
  1. 尝试执行
    openlogs tail -n 200
  2. 如果用户指定了命令或服务,尝试执行
    openlogs tail <query> -n 200
  3. 如果上述命令失败,尝试
    ol tail -n 200
  4. 如果CLI不可用但可访问工作区,读取
    .openlogs/latest.txt
    .openlogs/
    目录中匹配特定命令的文件。
  5. 如果日志目录不存在,检查服务器是否是通过
    openlogs <command>
    ol <command>
    启动的。
  6. 如果不是,告知用户通过openlogs重新启动服务器,然后检查生成的日志。

Common Commands

常用命令

bash
openlogs tail -n 100
openlogs tail dev -n 100
openlogs tail server -f
openlogs tail -f
openlogs tail --raw -n 100
openlogs tail --out-dir logs -n 200
openlogs bun dev
ol npm run dev
bash
openlogs tail -n 100
openlogs tail dev -n 100
openlogs tail server -f
openlogs tail -f
openlogs tail --raw -n 100
openlogs tail --out-dir logs -n 200
openlogs bun dev
ol npm run dev

Interpretation Rules

解读规则

  • Prefer the text log for analysis because it strips ANSI noise.
  • openlogs tail
    without a query means the latest run overall in the current project.
  • openlogs tail <query>
    means the latest run whose command or explicit name contains that query.
  • Switch to
    --raw
    only when the cleaned log hides something important.
  • Quote the exact failing lines or error block in your answer when useful.
  • State whether you are looking at the latest captured run or a live-following stream.
  • If the agent cannot access local gitignored files, ask the user to run
    openlogs tail -n 200
    and paste the output.
  • 分析时优先使用文本日志,因为它会去除ANSI冗余信息。
  • 不带查询参数的
    openlogs tail
    表示当前项目中最近一次的整体运行日志。
  • openlogs tail <query>
    表示最近一次命令或显式名称包含该查询内容的运行日志。
  • 仅当清理后的日志隐藏了重要信息时,才切换到
    --raw
    模式。
  • 必要时在回复中引用确切的错误行或错误块。
  • 说明你查看的是最近捕获的运行日志还是实时跟踪流。
  • 如果Agent无法访问本地被git忽略的文件,请让用户运行
    openlogs tail -n 200
    并粘贴输出结果。

Response Shape

回复格式

  • Start with the command or file you used.
  • Summarize the likely issue in 1 to 3 sentences.
  • Include the most relevant error lines.
  • If logs are missing, say exactly what command the user should rerun under openlogs.
  • 开头说明你使用的命令或文件。
  • 用1-3句话总结可能的问题。
  • 包含最相关的错误行。
  • 如果日志缺失,明确告知用户应通过openlogs重新运行哪个命令。