ChuckNorris

Jenkins Plugin GitHub release Jenkins Plugin Installs

Jenkins logo

What it is

This plugin adds an absolutely delightful feature to Jenkins: depending if your build succeeds, fails, or is unstable, it will show a picture of Chuck Norris auto-adapting (that's right, computer science it is!) to the build result!

Seeing that, already many thousands (yes, thousands!) of people have decided to take the plunge and install this plugin to finally see the light. Why not you?

Table of Contents

Download & Installation

Install this plugin from the Jenkins Plugin Manager (Manage Jenkins > Plugins > Available plugins), or download the latest .hpi and upload it via Manage Jenkins > Plugins > Advanced settings.

Usage

Freestyle / Maven jobs

  1. Open the job’s configuration page, click Add post-build action, and select Activate Chuck Norris.
  2. Save the configuration.
  3. Run a build. After it completes, Chuck Norris (along with a random quote) will appear on the job and build pages.

With Job DSL, including jobs created through Configuration as Code, use the chuckNorris symbol:

freeStyleJob('my-app') {
    publishers {
        chuckNorris()
    }
}

Pipeline jobs

Add the chuckNorris() step to your Jenkinsfile:

pipeline {
    agent any
    stages {
        stage('Build') {
            steps {
                echo 'Building...'
            }
        }
    }
    post {
        always {
            chuckNorris()
        }
    }
}

Put chuckNorris() in post { always { ... } } so Chuck reacts to the final build result. Calling the step more than once in a run is fine: the latest call replaces the earlier fact.

The step prints the fact to the build log and returns it, so you can reuse it elsewhere:

post {
    always {
        script {
            def fact = chuckNorris()
            echo "Today's wisdom: ${fact}"
        }
    }
}

Moods

Build result Chuck's mood
Success Thumbs up
Unstable / running Alert
Failure Bad ass
Aborted / not built Disappointed

Screenshots

Success Unstable
Successful build: Chuck gives a thumbs up Unstable build: Chuck is on alert
Failure Aborted / not built
Failed build: Chuck is bad ass Aborted build: Chuck is disappointed

The fact of the latest build also appears on the job page, and Chuck works with the dark theme too:

Job page Dark theme
Job page showing the latest fact Failed build in the dark theme

The step also prints the fact to the build log:

Console output with the Chuck Norris fact

Release Notes

See GitHub Releases.

Testimonials

Localization

Facts are displayed in the user's browser locale when available. Supported languages:

  • English (default)
  • Italian
  • German
  • Brazilian
  • Russian
  • Dutch
  • Simplified Chinese
  • Traditional Chinese

The plugin's own text is translated into the same languages: the post-build action and step names, and the lines it writes to the build log. Build log lines use the Jenkins controller's language, because the log is written before anyone views it.

Contributions of new translations are welcome — see the FactGenerator.properties (facts) and Messages.properties (plugin text) files under src/main/resources.

Credits

Maintainer

This plugin is actively maintained. Co-contributors and feedback are welcome — please open an issue or pull request.


Jenkins community • Report a bug