Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

show-diff

БесплатноБез исполняемых скриптовНе проверен

Compare two or more subjects when the user asks to compare them, asks how they differ, or asks which to choose between them. Plain requests such as “compare…

narumirunaот narumiruna★ 19 звёзд на GitHub

Об этом скилле

Show Diff

Resolve the comparison

  1. Identify what the user wants to compare.
    • For concepts, products, or approaches, compare the subjects in the order given under the same assumptions. State versions, variants, or defaults when they affect the comparison.
    • For repository changes, use the supplied diff or resolve the requested files, commits, or branches.
      • If no subjects or range are given, inspect staged, unstaged, and relevant untracked changes.
      • For changes proposed by a branch or open PR, compare the branches' common ancestor with the feature tip.
      • For a direct comparison of two branch snapshots, compare their tips.
      • For a merged PR, verify the target branch's state immediately before and after the merge, then compare those two states. Do not compare the PR head with the current target tip.
  2. Report only supported differences and distinguish intended behavior from verified results where applicable. For a verified addition or deletion, treat the absent side as empty. If there are no material differences or required information is missing, say so.
  3. Keep comparisons read-only except for the preference updates defined below. Do not stage, commit, or push those updates.

Choose the format and level of detail

Honor the user's requested format. If a follow-up only changes the format, keep the same subjects and scope. Otherwise, use the most specific matching confirmed preference from preferences.md in this skill directory. If no confirmed preference clearly applies, choose one primary format:

  • Use a high-level Git-style diff for a bare “show diff” request, repository changes, or a before-and-after comparison. Also use it for two subjects with a few clear contrasts that read well as - and + pairs.
  • Use a Markdown table when readers need to scan the same attributes or trade-offs across alternatives. Put one comparison criterion per row and one subject per column. Label differences in text instead of relying on color or icons alone.
  • Use Mermaid when the key difference is easier to see as a path, dependency, interaction order, or state transition. Focus on the relationships that differ and state the main takeaway in text.

Unless the user asks for both formats, add a second format only if it clarifies an important difference without repeating the full comparison. For more detail, expand the requested parts with exact excerpts, examples, formulas, or source details as useful. Label diff excerpts as partial. For a raw diff, complete patch, or line-by-line file comparison, show the actual diff for the requested scope without paraphrasing or adding visuals. Do not present an excerpt as complete or invent a patch when there are no files to compare.

Show before and after in one Mermaid diagram

When using Mermaid for a before-and-after comparison, put both states in one diagram rather than drawing separate diagrams. Show unchanged components, steps, or participants once when practical. Label additions, removals, or changes in text so the reader can tell what stays and what differs. Use labeled sections within the same diagram if combining the states would make ownership or message order unclear. Use color or dashed lines only to reinforce labels, and preserve the diagram type's normal arrow meanings.

Remember format preferences by comparison type

Update only the skill's preference file, not a copy in the repository being compared. Save only the comparison type and primary format: Git-style summary, Markdown table, or Mermaid. Omit subject names, raw patches, quotes, and conversation details.

  • When the user asks to switch the current comparison's primary format, apply it and save it as a candidate for that type. Leave the confirmed default unchanged, even if the user requests the same switch again.
  • When the user explicitly sets a default for a type, save it as confirmed and clear the candidate.
  • Do not save a preference if the request is one-time, applicable rules prohibit writes, only the level of detail changes, or the comparison type is unclear.

Reuse an existing type when it fits; add a narrower row when the user states a distinct preference. If the file cannot be updated, apply the requested format without saving it. When a preference changes, briefly say what was recorded so the user can review it in Git.

Format the high-level summary

  • Label the output as a summary, not an apply-ready patch, and use one fenced diff block.
  • For file changes, use diff --git a/<old-path> b/<new-path> with repository-relative paths. Show rename from and rename to only when the rename is established.
  • For concepts, use --- <first subject> and +++ <second subject> instead of inventing Git paths.
  • Use @@ <scope> @@ <key difference> for each group of related differences. Put a short topic or scope between the markers, without line numbers. After the closin
Полный SKILL.md на GitHub

Установить show-diff в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

Вложенные файлы

references/preferences.md

FAQ

Что делает скилл show-diff?

Compare two or more subjects when the user asks to compare them, asks how they differ, or asks which to choose between them. Plain requests such as “compare Python and Rust” count; no format or diff keyword is required. Also use to show Git changes, PR comparisons, or raw patches. Choose a Git-style summary, table, or Mermaid diagram based on the comparison unless the user requests a format.

Как установить скилл show-diff?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл show-diff запускает скрипты?

Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.

Похожие скиллы

Сравнить show-diff с