Onboards repositories to Harness Code Coverage (HCC) in Harness CI: inspects test setups, wires the codeCoverage step after unit tests, configures PR and baseline triggers, and sets exclusions via Harness MCP.
Ships in Harness Pipelines & Execution. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Onboard any repository or pipeline to Harness Code Coverage (HCC) in Harness CI end-to-end. The skill inspects the build and test setup, verifies report generation across all modules, adds the codeCoverage step immediately after tests, and configures PR and default-branch baseline triggers.
hcli cov upload → evaluate patch gate via hcli cov wait-until → configure PR & baseline triggers) is extensible and can be replicated on other platforms, but this skill specifically manages Harness CI pipelines and triggers.harness-mcp-v2 / harness-mcp) for autonomous discovery and write operations (inspecting repositories, checking PR checks, reading/updating pipeline YAML, and provisioning triggers).hcli is pre-installed on the system PATH.hcli helper binary into step containers on PATH. No custom binary download or installation step is required in the pipeline.Detail lives in references/ — read a reference only when needed:
| Reference | Read when |
|---|---|
| config.md | Standard thresholds, status checks, auto-discovery order |
| language-recipes.md | Multi-module detection, report formats, build file recipes |
| pipelines.md | Step classification, step placement rules, wiring YAML |
| triggers.md | Checking or creating PR and baseline push triggers |
| troubleshooting.md | Diagnosing errors or symptom-to-fix mapping |
Follow this structured checklist:
Enable code coverage — <repo>
- [ ] 1. Discover (read-only, cached) & early-exit checks
- [ ] 2. Classify onboarding path & step placement
- [ ] 3. Validate coverage report generation (every module)
- [ ] 4. Plan & decisions (one batched approval)
- [ ] 5. Apply (pipeline, repo fix, triggers)
- [ ] 6. Verify & prerequisites
- [ ] 7. Quality-check summary
org_id and project_id. Retrieve default branch (main or master), git connector, and existing PR checks via harness_list(resource_type="pr_check").harness_list and harness_get.hcli cov upload or uses codeCoverage, skip wiring.codeCoverage step must be placed immediately after the test step within the same stage (reports must exist before upload). Never place it in parallel before tests run.codeCoverage step (from templates/codeCoverage.yaml) immediately after the unit-test step in the existing pipeline.HCC analyzes only lines present in uploaded coverage reports; it does not analyze raw git source. Verify that every module in multi-module setups (Maven <modules>, Gradle subprojects, npm workspaces, go test ./..., pytest) produces a supported report format:
jacoco.xml)lcov.info) or Cobertura (coverage.xml)coverage.out)If any module lacks reports, prepare the build-file fix using recipes in references/language-recipes.md.
Show all proposed diffs together (pipeline YAML, trigger YAMLs, repo PR diff). Ask for explicit chat approval before making any changes. In dry-run mode, stop here and produce the plan summary.
harness_update(resource_type="pipeline", body={ "yamlPipeline": "<YAML string>" }).PullRequest webhook, 80% patch gate) and Baseline trigger (Push webhook on default branch) via harness_create(resource_type="trigger").ACCESS_DENIED is returned, flag the missing permission and resource scope directly to the user.coverage-patch check appears on PRs; baseline trigger runs on merges to the default branch.Always conclude with this fixed summary:
Quality check — <repo> [mode: normal | dry-run]
1. PR coverage
- Patch coverage (coverage-patch): working | failing | not yet verified | planned — <evidence>
- Project coverage (coverage-project): working | failing | not yet verified | planned — <evidence>
- PR trigger: existing | created (<id>) | planned
- Modules with reports: <n>/<total> — <missing modules, if any>
2. Branch scans / repo coverage (baseline)
- Baseline trigger on <default branch>: existing | created (<id>) | planned
- Baseline execution: <link + status> | pending until a PR is merged
- Monitoring: <user will monitor the first post-merge run | offered to check it after merge>
3. Fixes made
- Repo-side fix: PR <link> | manual instructions given | none needed
- Pipeline: PR/commit <link> (REMOTE) | inline update — <diff summary> | none
- Triggers: created <ids> (inline, no PR) | already existed
- Outstanding prerequisites: <e.g. account coverage enablement, deferred exclusions>
/enable-code-coverage https://app.harness.io/ng/account/l7B_kbSEQD2wjrM7PShm5w/all/orgs/default/projects/demo/pipelines/build_pipeline
The agent inspects the pipeline, detects the mvn test step, confirms JaCoCo report generation, drafts the codeCoverage step immediately after test execution, prepares PR and baseline triggers, and presents diffs for approval.
/enable-code-coverage Dry run on repository analytics-service in org default, project core.
The agent inspects the repository and pipelines, validates multi-module coverage outputs, and prints the plan and quality summary without performing any write calls.
harness_list(resource_type="pr_check") to avoid redundant runs.| Symptom | Root Cause | Fix |
|---|---|---|
| Coverage shows 0% | Reports not generated or not placed in standard auto-discovery paths | Verify test tool output matches paths in references/config.md; check module test commands |
ACCESS_DENIED | Missing API permissions | Flag the missing permission (e.g. Pipeline Edit or Trigger Create) directly to the user |
| Baseline coverage missing | Default branch has no baseline trigger | Create the baseline push trigger; baseline populates after the first post-merge run |
| Pipeline update rejected | Invalid YAML payload | Verify pipeline YAML using harness_schema(resource_type="pipeline") |
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
/harness-pipelines:enable-code-coveragefrom Harness Pipelines & Execution
npx claudepluginhub harness/harness-skills --plugin harness-pipelines9 skills in this plugin
/create-pipelineGenerate Harness v0 Pipeline YAML for CI/CD workflows and create them via MCP. Supports CI stages (build, test, Docker push), CD stages (Kubernetes, Helm, ECS, serverless), approval gates, parallel execution, matrix strategies, and failure rollback. Use when asked to create a pipeline, build pipeline, deployment pipeline, CI/CD workflow, or set up Harness pipelines. Do NOT use for v1 simplified pipelines (use create-pipeline-v1) or FME flag rollout stages (use fme-pipeline). Trigger phrases: create pipeline, build pipeline, deployment pipeline, CI/CD, Harness pipeline, Kubernetes deploy pipeline./create-pipeline-v1Generate Harness v1 simplified Pipeline YAML using the new concise syntax with flat structure, ${{ }} expressions, script field, and action steps. Supports CI stages (run, run-test, background), CD stages (service/environment with action steps for K8s, Helm, ECS), approval (stage-level and inline), parallel execution, matrix/for/while strategies, caching, volumes, and templates. Use when asked for a v1 pipeline, simplified pipeline, new pipeline format, or when user specifically requests v1 syntax. Do NOT use for v0/standard pipelines (use create-pipeline). Trigger phrases: v1 pipeline, simplified pipeline, new pipeline format, create v1, modern pipeline syntax./create-templateGenerate Harness v0 Template YAML for reusable pipeline components (Step, Stage, Pipeline, StepGroup) and create them via MCP. Use when asked to create a template, build a step template, stage template, pipeline template, or reusable step. Do NOT use for checking template usage or references (use template-usage instead). Trigger phrases: create template, step template, stage template, pipeline template, reusable step, template YAML./create-triggerGenerate Harness Trigger YAML for automated pipeline execution and create via MCP. Use when user says "create trigger", "webhook trigger", "cron trigger", "scheduled build", "artifact trigger", or wants pipelines to run automatically./debug-pipelineDiagnose Harness pipeline executions via MCP. Analyzes any execution (failed or successful) to produce structured reports with stage/step breakdown, timing, bottlenecks, failure details, chained pipeline drill-down, and execution logs. Use when asked to debug a pipeline, investigate a failure, find out why a build failed, analyze pipeline errors, check execution logs, review execution performance, or find bottlenecks. Trigger phrases: debug pipeline, pipeline failed, why did my build fail, analyze failure, pipeline error, execution logs, fix pipeline, execution bottleneck, slow pipeline./manage-freeze-windowsManage Harness deployment freeze windows via MCP. Create, list, get, update, and delete project-level freeze windows; toggle them Enabled/Disabled; and get or enable/disable the project-level global freeze. Use when asked about freeze windows, deployment freezes, change freezes, release blackouts, maintenance windows, holiday freezes, or to pause deployments. Trigger phrases: freeze window, deployment freeze, change freeze, release blackout, maintenance window, holiday freeze, pause deployments, block pipeline execution, global freeze.Other plugins' skills for the same job