This commit is contained in:
Robert Bendun 2023-03-22 15:06:06 +01:00
parent 4c6f16e215
commit b122851eb7
1 changed files with 26 additions and 0 deletions

26
Jenkinsfile vendored Normal file
View File

@ -0,0 +1,26 @@
node {
stage('Preparation') {
properties([
parameters([
string(
defaultValue: 'Hello World!',
description: 'Tekst do wyświetlenie',
name: 'INPUT_TEXT',
trim: false
)
])
])
}
stage('Hello') {
//Wypisz wartość parametru w konsoli (To nie jest polecenie bash, tylko groovy!)
echo "INPUT_TEXT: ${INPUT_TEXT}"
//Wywołaj w konsoli komendę "figlet", która generuje ASCI-art
sh "figlet \"${INPUT_TEXT}\" | tee output.txt"
}
stage('Goodbye') {
echo 'Goodbye!'
//Zarchiwizuj wynik
archiveArtifacts 'output.txt'
}
}