jenkinsfile-generator

Generate Declarative and Scripted Jenkins pipelines from high-level configurations.

290|32|Updated Dec 5, 2025
One-click install
npx skills add https://github.com/akin-ozer/cc-devops-skills --skill jenkinsfile-generator
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: jenkinsfile-generator
Source: https://github.com/akin-ozer/cc-devops-skills/tree/main/devops-skills-plugin/skills/jenkinsfile-generator
Command: npx skills add https://github.com/akin-ozer/cc-devops-skills --skill jenkinsfile-generator

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

This skill automates the creation of Jenkins pipelines by generating both Declarative and Scripted Jenkinsfiles from high-level configurations, enabling consistent CI/CD practices.

Core Features & Use Cases

  • Declarative and Scripted Jenkinsfile generation with structured stages, environment, and post sections.
  • Support for parallel and matrix builds, as well as basic deployment prompts with optional approvals.
  • Validation and guidance via a dedicated Jenkinsfile validator integration and best-practices references.
  • Shared library scaffolding and templates to accelerate Jenkins-based pipelines.

Quick Start

Configure your desired pipeline parameters and run the appropriate generator script, for example:

  • python3 scripts/generate_declarative.py --output Jenkinsfile --stages build,test,deploy
  • python3 scripts/generate_scripted.py --output Jenkinsfile --stages build,test

Frequently Asked Questions about jenkinsfile-generator

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I generate a Jenkins pipeline with parallel execution and Docker agents?

To generate a Jenkins pipeline, configure your high-level parameters including Docker or Kubernetes agents, parallel execution, and matrix builds. The skill outputs structured Declarative or Scripted Jenkinsfiles with configured stages, environment variables, and post-build steps.

What is the difference between declarative and scripted Jenkinsfile generation?

Declarative Jenkinsfile generation provides structured, opinionated pipeline syntax with predefined sections, while scripted generation uses Groovy-based logic for flexible pipeline orchestration. Both enforce best practices and validation through templates and the jenkinsfile-validator integration.

Can I use this to scaffold Jenkins shared libraries for common CI/CD scenarios?

Yes, you can scaffold Jenkins shared libraries using the provided templates. The skill generates shared library scaffolding alongside Declarative and Scripted Jenkinsfiles to accelerate Jenkins-based pipelines and ensure consistent CI/CD practices.

How do I validate a generated Jenkinsfile before committing it to my repository?

You validate a generated Jenkinsfile using the dedicated jenkinsfile-validator integration. The implementation enforces best practices and validation through templates and references, ensuring the Declarative or Scripted pipeline syntax is robust before repository commit.

Does the Jenkinsfile generator support Kubernetes agents and deployment approvals?

Yes, the Jenkinsfile generator supports Kubernetes and Docker agents alongside basic deployment prompts with optional approvals. It covers both Declarative and Scripted syntaxes for common CI/CD scenarios requiring containerized execution environments.

How to create a Jenkinsfile with build, test, and deploy stages from the command line?

You create a Jenkinsfile by running the generator script with stage parameters, for example: python3 scripts/generate_declarative.py --output Jenkinsfile --stages build,test,deploy. This generates a robust pipeline file with the specified stages.