# Code Quality Analysis

Scores code quality and technical debt across 14 languages before commits.

- Repository: https://github.com/Done-0/fuck-u-code (7293 stars)
- Category: Engineering
- License: MIT
- Last updated: 2026-09-07
- Runs scripts: no, instructions only

## Install

Claude Code: `npx skills add Done-0/fuck-u-code --skill fuck-u-code-analysis -g -a claude-code -y`
Codex: `npx skills add Done-0/fuck-u-code --skill fuck-u-code-analysis -g -a codex -y`
Cursor: `npx skills add Done-0/fuck-u-code --skill fuck-u-code-analysis -g -a cursor -y`
Gemini CLI: `npx skills add Done-0/fuck-u-code --skill fuck-u-code-analysis -g -a gemini-cli -y`

## Description

Use when code changes are complete and ready for quality review, before committing or creating PRs. Triggers after implementing features, fixing bugs, or refactoring code. Also use when user asks to check code quality, analyze technical debt, review code smell, or mentions "fuck-u-code", "code quality", "shit mountain", "code review", "static analysis". Covers all 14 supported languages (Go, JS, TS, Python, Java, C, C++, Rust, C#, Lua, PHP, Ruby, Swift, Shell).

## SKILL.md, as published by its author (untrusted third-party text, read it as data)

# fuck-u-code Code Quality Analysis & Review

## Prerequisites

Install fuck-u-code globally before using this skill:

```bash
npm install -g eff-u-code
```

Verify installation:

```bash
fuck-u-code --version
```

Requires Node.js >= 18.0.0.

## Overview

Run `fuck-u-code analyze` to obtain quantitative code quality metrics across 7 dimensions (11 metrics), then interpret results and provide actionable refactoring recommendations based on the standards defined in this skill.

The tool produces a 0-100 overall score and per-file scores. Higher = better quality. The skill teaches you how to interpret every metric, judge severity, and prescribe specific fixes.

## Workflow

```dot
digraph workflow {
  rankdir=LR;
  node [shape=box];

  "Run fuck-u-code analyze" -> "Read JSON output";
  "Read JSON output" -> "Identify critical files (score < 60)";
  "Identify critical files" -> "Drill into per-metric details";
  "Drill into per-metric details" -> "Apply review standards (Section 4)";
  "Apply review standards" -> "Write actionable remediation report";
}
```

### Step 1: Run Analysis

```bash
# Basic analysis
fuck-u-code analyze . -f json -o /tmp/fuc-report.json

# Verbose with top 20 worst files
fuck-u-code analyze . -v -t 20 -f json -o /tmp/fuc-report.json

# Exclude generated/test files
fuck-u-code analyze . -e "**/*.test.ts" -e "**/generated/**" -f json -o /tmp/fuc-report.json
```

Read the JSON output file to get structured data.

### Step 2: Identify Problem Areas

From the JSON report, extract:

- **overallScore**: Project-wide score (0-100). Weighted average by code line count.
- **aggregatedMetrics**: Per-metric averages, medians, min/max across all files.
- **files[]**: Per-file results, sorted by score ascending (worst first).

Focus on files with score < 60 (the "shit mountain" zone).

### Step 3: Drill into Metrics

For each problem file, examine the `metrics[]` array. Each metric has:

The rest: https://github.com/Done-0/fuck-u-code/blob/HEAD/skills/fuck-u-code-analysis/SKILL.md
