Skip to content

Instantly share code, notes, and snippets.

View anandasubedi's full-sized avatar

Ananda Subedi anandasubedi

  • Karyathalo
  • PA, United States
View GitHub Profile
@ivan-pinatti
ivan-pinatti / jenkins-add-username-with-password-credential.groovy
Created May 21, 2018 14:49
Jenkins - Add Username with password credential via groovy script - #jenkins #groovy #username #password #credential #usernameWithPassword
#!groovy
// imports
import com.cloudbees.plugins.credentials.*
import com.cloudbees.plugins.credentials.domains.Domain
import com.cloudbees.plugins.credentials.impl.*
import hudson.util.Secret
import jenkins.model.Jenkins
// parameters