मुझे घोषणा नहीं है कि घोषणात्मक जेनकींस पाइपलाइन के साथ क्या करना है।जेनकींस पाइपलाइन में ansiColor जेनकिंस प्लगइन के लिए रैपर कहां रखा जाए?
उदाहरण यहाँ के बाद: https://github.com/jenkinsci/ansicolor-plugin
wrap([$class: 'AnsiColorBuildWrapper', 'colorMapName': 'XTerm']) {
sh 'something that outputs ansi colored stuff'
}
ऊपर टुकड़ा कहाँ जाती है?
#!groovy
pipeline {
agent any
// Set log rotation, timeout and timestamps in the console
options {
buildDiscarder(logRotator(numToKeepStr:'10'))
timeout(time: 5, unit: 'MINUTES')
}
stages {
stage('Initialize') {
steps {
sh '''
java -version
node --version
npm --version
'''
}
}
}
}
आवरण चरणों के चारों ओर जाना है:
यहाँ मेरी सरल Jenkinsfile है? क्या यह प्रत्येक चरण के आसपास जाता है?
जवाब मैं –