Skip to content
Back to skills

R Util Code Modernize

ASecurity

Assess codebase modernization maturity and generate a phased remediation

  • 20 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added November 7, 2026
developmentgoshellbashapidocumentation

Works with

  • cli
  • api

Security analysis

A100/100

Scanned November 7, 2026

npx -y skills add rfxn/rdf --skill r-util-code-modernize --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of R Util Code Modernize?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for R Util Code Modernize
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/rfxn-r-util-code-modernize/badge)](https://www.skillsdirectory.com/skills/rfxn-r-util-code-modernize)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: r-util-code-modernize
description: >
  Assess codebase modernization maturity and generate a phased remediation
---

Assess codebase modernization maturity and generate a phased remediation
plan. This is a **read-only assessment** — it does NOT modify any project
files.

## Arguments
- `$ARGUMENTS` — optional: project name or path (default: CWD)

## Setup

Read `.rdf/governance/index.md` to identify:
- Project name, language, and conventions
- Verification checks (from governance/verification.md)
- Anti-patterns (from governance/anti-patterns.md)
- Constraints (from governance/constraints.md)

## Procedure

### 1. Read project context

- Read governance index and relevant governance files
- Read PLAN.md if present (check for existing modernization phases)
- Identify the project's language, framework, and toolchain

### 2. Run static analysis

Execute checks appropriate to the project's language:

**For shell projects:**
- `bash -n` on all shell files
- `shellcheck` on all shell files
- Anti-pattern density (via code-scan pattern library)

**For other languages:**
- Run the project's linter(s) as identified in governance/verification.md
- Run type checker if applicable
- Scan for language-specific anti-patterns from governance

### 3. Score 5 dimensions (0-100 each)

**3a. Lint Score**
- Start at 100
- Deduct per syntax/lint failure (severity-weighted)
- Floor at 0

**3b. Anti-Pattern Score**
- Start at 100
- Deduct per anti-pattern instance (severity-weighted)
- Floor at 0

**3c. Test Coverage Score**
- 100: comprehensive suite with high coverage
- 75: suite exists, moderate coverage
- 50: basic tests exist
- 25: minimal or broken tests
- 0: no test infrastructure

**3d. Documentation Score**
- 25 pts each for: primary docs (man page/API docs), README, CLI help/usage,
  configuration documentation

**3e. Dependency Hygiene Score**
- Score based on dependency management practices: version pinning,
  shared library usage, vendoring strategy, upgrade paths

### 4. Map findings to phases

Group findings by logical unit (not by severity). Order phases by
dependency: fixes before features, infrastructure before consumers.

### 5. Generate assessment report

    # Modernization Assessment — <project> v<version>

    ## Maturity Scores
    | Dimension             | Score | Grade |
    |-----------------------|-------|-------|
    | Lint                  | XX    | A-F   |
    | Anti-Patterns         | XX    | A-F   |
    | Test Coverage         | XX    | A-F   |
    | Documentation         | XX    | A-F   |
    | Dependency Hygiene    | XX    | A-F   |
    | **Overall**           | XX    | A-F   |

    Grade scale: A=90-100, B=80-89, C=70-79, D=60-69, F=<60

    ## Key Findings
    - <finding with file:line evidence>
    ...

    ## Remediation Phases
    | Phase | Title | Est. Scope | Dependencies |
    |-------|-------|-----------|--------------|
    ...

    ## Recommended Next Steps
    1. <action> — <rationale>
    ...

### 6. Offer PLAN generation

After displaying the report, ask:
"Generate PLAN-modernize.md with the remediation phases? [y/n]"

If yes, write PLAN-modernize.md using standard PLAN format.

## Rules
- Read-only assessment — do NOT modify any existing project files
- Score objectively — do not inflate grades
- Include evidence (file:line) for every finding
- If PLAN.md already has modernization phases, note overlap and recommend
  merging rather than duplicating

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.