CtrlK
BlogDocsLog inGet started
Tessl Logo

pantheon-ai/jenkinsfile-toolkit

Complete jenkinsfile toolkit with generation and validation capabilities

97

Quality

97%

Does it follow best practices?

Impact

Pending

No eval scenarios have been run

SecuritybySnyk

Risky

Do not use without reviewing

Overview
Quality
Evals
Security
Files

instructions.jsonvalidator/evals/

{
  "instructions": [
    {
      "instruction": "Run the main orchestrator script bash scripts/validate_jenkinsfile.sh — not individual sub-scripts directly",
      "original_snippets": "Run complete validation (syntax + security + best practices): bash scripts/validate_jenkinsfile.sh Jenkinsfile...Auto-detects pipeline type, validates syntax, scans for hardcoded credentials, checks best practices",
      "relevant_when": "validating any Jenkinsfile",
      "why_given": "preference"
    },
    {
      "instruction": "For Shared Library files, use bash scripts/validate_shared_library.sh — separate from the main Jenkinsfile validator",
      "original_snippets": "Validate Jenkins Shared Library files using validate_shared_library.sh: bash scripts/validate_shared_library.sh vars/myStep.groovy",
      "relevant_when": "validating vars/*.groovy or src/**/*.groovy shared library files",
      "why_given": "new knowledge"
    },
    {
      "instruction": "Look up unknown plugin steps by checking references/common_plugins.md first, then Context7 MCP, then WebSearch as fallback",
      "original_snippets": "Check Local Reference First - Read: references/common_plugins.md...Use Context7 MCP...mcp__context7__resolve-library-id with query: 'jenkinsci <plugin-name>-plugin'...Web Search Fallback",
      "relevant_when": "encountering unrecognized steps in a Jenkinsfile (not in common_plugins.md)",
      "why_given": "new knowledge"
    },
    {
      "instruction": "Report results with line numbers, severity, and actionable suggestions",
      "original_snippets": "Report results with line numbers, severity, and actionable suggestions",
      "relevant_when": "reporting validation findings to the user",
      "why_given": "preference"
    },
    {
      "instruction": "Provide inline fix suggestions when errors are found — include corrected code snippets directly in the response",
      "original_snippets": "Provide inline fix suggestions when errors are found (include corrected code snippets directly in the response)",
      "relevant_when": "reporting errors or warnings in a Jenkinsfile",
      "why_given": "preference"
    },
    {
      "instruction": "When Jenkinsfile uses @Library, note all @Library calls and cross-reference the library version being loaded — NEVER validate in isolation",
      "original_snippets": "NEVER validate only the Jenkinsfile without checking Shared Library calls...Note all @Library calls and cross-reference the library version being loaded.",
      "relevant_when": "validating a Jenkinsfile that contains @Library declarations",
      "why_given": "new knowledge"
    },
    {
      "instruction": "For Declarative pipelines, validate using the Jenkins Declarative Linter — NEVER rely only on Groovy syntax checking",
      "original_snippets": "NEVER skip Declarative Linter validation for Declarative pipelines...Submit the Jenkinsfile to http://<jenkins>/pipeline-model-converter/validate or use the CLI linter.",
      "relevant_when": "validating any Declarative pipeline (pipeline { } syntax)",
      "why_given": "new knowledge"
    },
    {
      "instruction": "NEVER accept 'no errors' from a linter as a green-light to deploy — validate env vars, credentials, and sh steps exist in the target Jenkins environment",
      "original_snippets": "NEVER accept a 'no errors' result from a linter as a green-light to deploy...validate that sh steps, credentials references, and environment variables exist in the target Jenkins environment.",
      "relevant_when": "completing validation and advising on deployment readiness",
      "why_given": "new knowledge"
    },
    {
      "instruction": "NEVER leave retry(n) without investigating root cause — it masks flaky steps and increases build time",
      "original_snippets": "NEVER leave retry(n) in production pipelines without understanding why it was added...Investigate why the step is flaky, fix the root cause, and remove the retry.",
      "relevant_when": "encountering retry() in a Jenkinsfile during review",
      "why_given": "preference"
    },
    {
      "instruction": "For shared library vars/*.groovy: verify call() method exists, NonCPS annotation correctness, CPS compatibility, camelCase naming",
      "original_snippets": "vars/*.groovy: call() method, NonCPS annotation correctness, CPS compatibility, camelCase naming, documentation comments",
      "relevant_when": "validating vars/*.groovy files in a Jenkins Shared Library",
      "why_given": "new knowledge"
    },
    {
      "instruction": "For shared library src/**/*.groovy: verify package declaration, class-filename match, Serializable implementation",
      "original_snippets": "src/**/*.groovy: package declaration, class-filename match, Serializable implementation, wildcard import warnings, static method CPS compatibility",
      "relevant_when": "validating src/**/*.groovy class files in a Jenkins Shared Library",
      "why_given": "new knowledge"
    }
  ]
}

tile.json