Skip to content

Jenkins build user variables plugin: injects name of user started the build into build variables set.

Notifications You must be signed in to change notification settings

smartrecruiters/build-user-vars-plugin

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Build User Vars Plugin

Build Status Coverage Contributors Jenkins Plugin GitHub release Jenkins Plugin Installs

Set of environment variables that describe the user who started the build.

Variables provided

The plugin provides the following environment variables:

Variable Description
BUILD_USER Full name (first name + last name)
BUILD_USER_FIRST_NAME First name
BUILD_USER_LAST_NAME Last name
BUILD_USER_ID Jenkins user ID
BUILD_USER_GROUPS Jenkins user groups
BUILD_USER_EMAIL Email address

Since 1.8

Set the global option to add build user variables to the environment for all builds (in Manage Jenkins, Configure System).

Usage example

Select Set Jenkins user build variables and reference the variables during the build:

Pipeline Examples

node {
  withBuildUser {
    def user = env.BUILD_USER_ID
  }
}

or with declarative option:

options {
  withBuildUser()
}

Changelog

Release notes are available in GitHub Releases since July 2020 (build-user-vars plugin 1.6 and later). Prior release notes are available in the plugin repository changelog.

About

Jenkins build user variables plugin: injects name of user started the build into build variables set.

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Java 97.8%
  • HTML 2.2%