Skip to content

jenkins-pipeline

Build Jenkins declarative and scripted pipelines with stages, agents, parameters, and plugins. Implement multi-branch pipelines and deployment automation.

— (0 ratings) 2.2K downloads aj-geddes
$ npx skills add https://github.com/aj-geddes/useful-ai-prompts --skill jenkins-pipeline

Skills can run code on your computer. Review the source before installing. This listing is community-made and isn't affiliated with Anthropic.

About this skill

Jenkins Pipeline

Table of Contents

Overview

Create enterprise-grade Jenkins pipelines using declarative and scripted approaches to automate building, testing, and deploying with advanced control flow.

When to Use

  • Enterprise CI/CD infrastructure
  • Complex multi-stage builds
  • On-premise deployment automation
  • Parameterized builds

Quick Start

Minimal working example:

pipeline {
    agent { label 'linux-docker' }
    environment {
        REGISTRY = 'docker.io'
        IMAGE_NAME = 'myapp'
    }
    parameters {
        string(name: 'DEPLOY_ENV', defaultValue: 'staging')
    }
    stages {
        stage('Checkout') { steps { checkout scm } }
        stage('Install') { steps { sh 'npm ci' } }
        stage('Lint') { steps { sh 'npm run lint' } }
        stage('Test') {
            steps {
                sh 'npm run test:coverage'
                junit 'test-results.xml'
            }
        }
        stage('Build') {
            steps {
                sh 'npm run build'
                archiveArtifacts artifacts: 'dist/**/*'
            }
        }
// ... (see reference guides for full implementation)

Reference Guides

Detailed implementations in the references/ directory:

Guide Contents
Declarative Pipeline (Jenkinsfile) Declarative Pipeline (Jenkinsfile)
Scripted Pipeline Scripted Pipeline (Groovy), Multi-Branch Pipeline, Parameterized Pipeline, Pipeline with Credentials

Best Practices

✅ DO

  • Use declarative pipelines for clarity
  • Use credentials plugin for secrets
  • Archive artifacts and reports
  • Implement approval gates for production
  • Keep pipelines modular and reusable

❌ DON'T

  • Store credentials in pipeline code
  • Ignore pipeline errors
  • Skip test coverage reporting
  • Use deprecated plugins

Installs: 2.2K | GitHub stars: 396 | First seen: Jan 21, 2026

Related skills

New

Coding & dev tools

code-review

Review the changes since a fixed point (commit, branch, tag, or merge-base) along two axes: Standards (does the code follow this repo's documented coding

New • 951K
New

Agent workflows

microsoft-foundry

End-to-end deployment, evaluation, and management of AI agents on Microsoft Foundry.

New • 792.7K
New

Debugging & code review

azure-diagnostics

Systematic diagnosis and remediation for Azure production issues using AppLens, Monitor, and resource health.

New • 783.3K