# Code Detect Dup

> 该skill提供了一份simian执行样例，借鉴此样例，完成对代码的重复度检查

- **Type:** Skill
- **Install:** `agentstack add skill-hellyguo-self-ai-spec-code-detect-dup`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [hellyguo](https://agentstack.voostack.com/s/hellyguo)
- **Installs:** 0
- **Category:** [Agent Skills](https://agentstack.voostack.com/c/agent-skills)
- **Latest version:** 0.1.0
- **License:** Apache-2.0
- **Upstream author:** [hellyguo](https://github.com/hellyguo)
- **Source:** https://github.com/hellyguo/self-ai-spec/tree/main/skills/code-detect-dup

## Install

```sh
agentstack add skill-hellyguo-self-ai-spec-code-detect-dup
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

```bash
#!/bin/bash

java -jar ~/app/simian/simian-4.2.1.jar -language=java -threshold=20 $(fd -H -I -s -c never -t f -e java | grep --color=never -v "\/test\/" | xargs) > docs/dup-{yyyy-mm-dd}-{seq}.txt 2>&1

```

1. 其中，threshold 代表重复代码的行数，应根据实际情况调整
2. 其中，language=java应根据实际情况调整
3. 其中的 fd0/grep0, fd0='fd -H -I -s -c never', grep0='grep --color=never'
4. seq 应从 001 开始，按日重置，dup-{yyyy-mm-dd}-{seq}.txt 最终应 git 留档

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [hellyguo](https://github.com/hellyguo)
- **Source:** [hellyguo/self-ai-spec](https://github.com/hellyguo/self-ai-spec)
- **License:** Apache-2.0

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-hellyguo-self-ai-spec-code-detect-dup
- Seller: https://agentstack.voostack.com/s/hellyguo
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
