← Back to Skills Marketplace
super9du

File Diff

by Super 9° · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ⚠ suspicious
125
Downloads
0
Stars
0
Active Installs
1
Versions
Install in OpenClaw
/install file-diff
Description
Compare two files and display their differences in a human-readable markdown format. Use when asked to "compare files", "show diff", "compare differences", "...
README (SKILL.md)

File Diff

Compare two files and display differences in a clean, readable markdown format.

Usage

Quick Compare (Two file paths)

diff \x3Csource_file> \x3Ctarget_file>

Unified Diff Format (Recommended)

diff -u \x3Csource_file> \x3Ctarget_file>

Output Format

The diff output is formatted as:

**File A**: `/path/to/file1`
**File B**: `/path/to/file2`

## Differences

### 1. [Section/Line description]
```diff
- removed line
+ added line

## Workflow

1. Identify the two files to compare
2. Run `diff -u` command
3. Parse the unified diff output
4. Format into readable markdown with:
   - File paths as headers
   - Line numbers from diff output
   - `-` prefix for removals (red)
   - `+` prefix for additions (green)
   - Context lines for clarity

## Example

Input:
```bash
diff -u /tmp/original.txt /tmp/modified.txt

Output format:

**File A**: `/tmp/original.txt`
**File B**: `/tmp/modified.txt`

## Differences

### Line 5
```diff
- old content
+ new content

## Notes

- Always use `-u` flag for unified format (more readable)
- Include both file paths in the output
- Preserve all changes including additions, deletions, and modifications
Usage Guidance
This skill appears to do what it says: run 'diff -u' on two files and format the output as markdown. Before installing, consider the following: (1) Metadata omits the external dependency: the bundled script calls the system 'diff' command — ensure 'diff' is available and trustworthy on your host. (2) The skill will output the contents of any files you ask it to compare; avoid giving it paths that contain secrets (keys, passwords, tokens) or run it in a sandbox. (3) The source and homepage are unknown — prefer skills from known publishers or review the code yourself. (4) If you plan to use this in an automated agent, ensure the agent is constrained so it cannot be instructed to diff sensitive system files. If you trust the code and your environment, this is low-risk; otherwise exercise caution or request a version with declared dependency metadata and an auditable source.
Capability Analysis
Type: OpenClaw Skill Name: file-diff Version: 1.0.0 The 'file-diff' skill is a straightforward utility designed to compare two local files and format the output into Markdown. The core logic in 'scripts/diff_to_markdown.py' uses the Python 'subprocess' module safely with argument lists to prevent shell injection, and the 'SKILL.md' instructions contain no malicious prompt injections or requests for unauthorized access.
Capability Assessment
Purpose & Capability
The script and SKILL.md both describe running the system 'diff -u' command and formatting its output to markdown — this aligns with the skill name and description. However, the package metadata declares no required binaries while the code invokes the external 'diff' binary via subprocess, so the manifest is incomplete/inconsistent.
Instruction Scope
Instructions and the bundled script only describe running diff on two files, parsing the unified diff output, and producing markdown. There are no instructions to read unrelated system state, call external endpoints, or access environment variables. Note: because the tool reads arbitrary file paths provided to it, it can reveal the contents of any files the agent is permitted to access (including secrets) in the diff output.
Install Mechanism
There is no install spec (instruction-only) and the repository contains a small helper script. Nothing is downloaded from external URLs or installed on the system by the skill itself, which is a low-install-risk configuration. The helper delegates to the system 'diff' binary.
Credentials
The skill requests no environment variables, credentials, or config paths and the code does not read env vars. This is proportionate to the stated purpose.
Persistence & Privilege
The skill is not marked 'always' and does not request elevated persistence. Model invocation is allowed (platform default) but there is no evidence the skill attempts to modify agent-wide settings or other skills.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install file-diff
  3. After installation, invoke the skill by name or use /file-diff
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.0
- Initial release of "file-diff": compare two files and display their differences in a readable markdown format. - Supports requests in English and Chinese, triggering on key phrases like "compare files" or "diff". - Uses unified diff (`diff -u`) for clear, context-rich comparison output. - Outputs file paths and formats differences with markdown and diff-style notation for clarity. - Step-by-step workflow: file detection, diff execution, parsing, and clean markdown formatting. - Includes usage instructions, output examples, and notes for best practices.
Metadata
Slug file-diff
Version 1.0.0
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 1
Frequently Asked Questions

What is File Diff?

Compare two files and display their differences in a human-readable markdown format. Use when asked to "compare files", "show diff", "compare differences", "... It is an AI Agent Skill for Claude Code / OpenClaw, with 125 downloads so far.

How do I install File Diff?

Run "/install file-diff" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is File Diff free?

Yes, File Diff is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does File Diff support?

File Diff is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created File Diff?

It is built and maintained by Super 9° (@super9du); the current version is v1.0.0.

💬 Comments