# Docs Update From Diff

Review local code changes with git diff and update the official docs under docs/ to match.

- Repository: https://github.com/QwenLM/qwen-code (28858 stars)
- Category: Git and review
- License: Apache-2.0
- Last updated: 2026-11-01
- Runs scripts: no, instructions only

## Install

Claude Code: `npx skills add QwenLM/qwen-code --skill docs-update-from-diff -g -a claude-code -y`
Codex: `npx skills add QwenLM/qwen-code --skill docs-update-from-diff -g -a codex -y`
Cursor: `npx skills add QwenLM/qwen-code --skill docs-update-from-diff -g -a cursor -y`
Gemini CLI: `npx skills add QwenLM/qwen-code --skill docs-update-from-diff -g -a gemini-cli -y`

## Description

Review local code changes with git diff and update the official docs under docs/ to match. Use when the user asks to document current uncommitted work, sync docs with local changes, update docs after a feature or refactor, or when phrases like "git diff", "local changes", "update docs", or "official docs" appear.

## SKILL.md, as published by its author (untrusted third-party text, read it as data)

# Docs Update From Diff

## Overview

Inspect local diffs, derive the documentation impact, and update only the
repository's `docs/` pages. Treat the current code as the source of truth and
keep changes scoped, specific, and navigable.

Read [references/docs-surface.md](references/docs-surface.md) before editing if
the affected feature does not map cleanly to an existing docs section.

## Workflow

### 1. Build the change set

Start from local Git state, not from assumptions.

- Inspect `git status --short`, `git diff --stat`, and targeted `git diff`
  output.
- Focus on non-doc changes first so the documentation delta is grounded in
  code.
- Ignore `README.md` and other non-`docs/` content unless they help confirm
  intent.

### 2. Derive the docs impact

For every changed behavior, extract the user-facing or developer-facing facts
that documentation must reflect.

- New command, flag, config key, default, workflow, or limitation
- Renamed behavior or removed behavior
- Changed examples, paths, or setup steps
- New feature that belongs in an existing page but is not mentioned yet

Prefer updating an existing page over creating a new page. Create a new page
only when the feature introduces a stable topic that would make an existing page
harder to follow.

### 3. Find the right docs location

Map each change to the smallest correct documentation surface:

- End-user behavior: `docs/users/**`
- Developer internals, SDKs, contributor workflow, tooling:
  `docs/developers/**`
- Shared landing or navigation changes: root `docs/**` and `_meta.ts`

If you add a new page, update the nearest `_meta.ts` in the same docs section so
the page is discoverable.

### 4. Write the update

Edit documentation with the following bar:

The rest: https://github.com/QwenLM/qwen-code/blob/HEAD/.qwen/skills/docs-update-from-diff/SKILL.md
