R013: 注释的废弃代码

Official

Detect and remove commented-out dead test code.

Authoropenharmonyinsight
Version1.0.0
Installs0

System Documentation

What problem does it solve?

This Skill finds test files that keep large blocks of commented-out, no-longer-used code, which reduces readability and makes reviews harder.

Core Features & Use Cases

  • Targets test files automatically: Scans only .test.ets, .test.ts, and .test.js files.
  • Detects abandoned code comment blocks: Flags consecutive comment blocks (3+ lines) that appear to contain code rather than pure documentation.
  • Attributes findings to the right test case: Traces the commented block’s location to the nearest surrounding it() block, or marks it as - if outside.
  • Excludes documentation-style JSDoc: Skips blocks that look like JSDoc (e.g., includes multiple @tc.*, @param, @return-style markers).

Quick Start

Use R013 to scan your test directory and automatically get a list of commented-out dead code blocks with their file, line range, and owning it() testcase.

Dependency Matrix

Required Modules

None required

Components

Standard package

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: R013: 注释的废弃代码
Download link: https://github.com/openharmonyinsight/openharmony-skills/archive/main.zip#r013

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository

Agent Skills Search Helper

Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.