update conf jenkins x MAN/WIN-NEXT

This commit is contained in:
Samuele Locatelli
2021-10-25 11:47:54 +02:00
parent 4104ef0bf3
commit 9b1c53d14c
Vendored
+48 -43
View File
@@ -33,7 +33,7 @@ pipeline {
// CAMBIO numero versione in file sorgente!!!
bat "e:\\fart.exe VersGen\\VersGen.cs 0.0.0.0 ${env.versionNumber} || EXIT /B 0"
// checkout NuGet in file sorgente!!!
fixNuget("${WORKSPACE}\\IOB-WIN.sln")
fixNuget("${WORKSPACE}\\IOB-MAN.sln")
fixNuget("${WORKSPACE}\\IOB-WIN-NEXT.sln")
}
script {
@@ -41,13 +41,13 @@ pipeline {
parallel (
IOB_WIN: {
// BUILD!
bat "\"${tool 'MSBuild-16.0'}\" IOB-WIN/IOB-WIN.csproj -target:Build /p:Configuration=Release /p:Platform=\"x86\" /p:OutputPath=bin/ /verbosity:minimal /m"
bat "\"${tool 'MSBuild-16.0'}\" IOB-MAN/IOB-MAN.csproj -target:Build /p:Configuration=Release /p:Platform=\"x86\" /p:OutputPath=bin/ /verbosity:minimal /m"
bat "\"${tool 'MSBuild-16.0'}\" IOB-WIN-NEXT/IOB-WIN-NEXT.csproj -target:Build /p:Configuration=Release /p:Platform=\"x86\" /p:OutputPath=bin/ /verbosity:minimal /m"
},
IOB_MAN: {
// BUILD!
bat "\"${tool 'MSBuild-16.0'}\" IOB-MAN/IOB-MAN.csproj -target:Build /p:Configuration=Release /p:Platform=\"x86\" /p:OutputPath=bin/ /verbosity:minimal /m"
},
// IOB_MAN: {
// // BUILD!
// bat "\"${tool 'MSBuild-16.0'}\" IOB-MAN/IOB-MAN.csproj -target:Build /p:Configuration=Release /p:Platform=\"x86\" /p:OutputPath=bin/ /verbosity:minimal /m"
// },
failFast: false
)
}
@@ -70,7 +70,7 @@ pipeline {
// CAMBIO numero versione in file sorgente!!!
bat "e:\\fart.exe VersGen\\VersGen.cs 0.0.0.0 ${env.versionNumber} || EXIT /B 0"
// checkout NuGet in file sorgente!!!
fixNuget("${WORKSPACE}\\IOB-WIN.sln")
fixNuget("${WORKSPACE}\\IOB-MAN.sln")
fixNuget("${WORKSPACE}\\IOB-WIN-NEXT.sln")
}
// a seconda del branch decido cosa e come compilare e caricare...
@@ -82,7 +82,7 @@ pipeline {
// procedo solo se NON si tratta di commit in ramo DOCUMentazione...
else if (env.BRANCH_NAME == "develop" || env.BRANCH_NAME.contains("master") ) {
// BUILD!
bat "\"${tool 'MSBuild-16.0'}\" IOB-WIN/IOB-WIN.csproj -target:Build /p:Configuration=Release /p:Platform=\"x86\" /p:OutputPath=bin/ /verbosity:minimal /m"
bat "\"${tool 'MSBuild-16.0'}\" IOB-MAN/IOB-MAN.csproj -target:Build /p:Configuration=Release /p:Platform=\"x86\" /p:OutputPath=bin/ /verbosity:minimal /m"
bat "\"${tool 'MSBuild-16.0'}\" IOB-WIN-NEXT/IOB-WIN-NEXT.csproj -target:Build /p:Configuration=Release /p:Platform=\"x86\" /p:OutputPath=bin/ /verbosity:minimal /m"
}
else
@@ -92,40 +92,41 @@ pipeline {
}
// ora mi occupo delle operazioni di compressione e copia...
script {
// se è ramo IobMan compilo SOLO IOB-MAN...
if(env.BRANCH_NAME == "IobMan") {
env.classifier = ""
// rimuovo vecchio zip...
bat "del /f ${WORKSPACE}\\Releases\\${env.BRANCH_NAME}\\*.zip || EXIT /B 0"
// Compressione in .zip dell'installer...
bat "e:\\7za.exe a -tzip ${WORKSPACE}\\Releases\\${env.BRANCH_NAME}\\MAPO-IOB-MAN.zip ${WORKSPACE}\\IOB-MAN\\bin\\*"
// ora mi occupo delle operazioni di invio a NEXUS...
nexusArtifactUploader(
nexusVersion: 'nexus3',
protocol: 'https',
nexusUrl: 'nexus.steamware.net',
groupId: 'MAPO',
//version: "${env.versionNumber}",
version: "stable",
repository: 'utility',
credentialsId: 'bc9d8e92-4302-3266-817f-7b58501d12d5',
artifacts: [
[artifactId: 'IOB-MAN',
classifier: "${env.classifier}",
file: "Releases\\${env.BRANCH_NAME}\\MAPO-IOB-MAN.zip",
type: 'zip']
]
)
}
// procedo solo se NON si tratta di commit in ramo DOCUMentazione...
else if (env.BRANCH_NAME == "develop" || env.BRANCH_NAME.contains("master") || env.BRANCH_NAME.contains("feature") ) {
fixResources("IOB-WIN")
// // se è ramo IobMan compilo SOLO IOB-MAN...
// if(env.BRANCH_NAME == "IobMan") {
// env.classifier = ""
// // rimuovo vecchio zip...
// bat "del /f ${WORKSPACE}\\Releases\\${env.BRANCH_NAME}\\*.zip || EXIT /B 0"
// // Compressione in .zip dell'installer...
// bat "e:\\7za.exe a -tzip ${WORKSPACE}\\Releases\\${env.BRANCH_NAME}\\MAPO-IOB-MAN.zip ${WORKSPACE}\\IOB-MAN\\bin\\*"
// // ora mi occupo delle operazioni di invio a NEXUS...
// nexusArtifactUploader(
// nexusVersion: 'nexus3',
// protocol: 'https',
// nexusUrl: 'nexus.steamware.net',
// groupId: 'MAPO',
// //version: "${env.versionNumber}",
// version: "stable",
// repository: 'utility',
// credentialsId: 'bc9d8e92-4302-3266-817f-7b58501d12d5',
// artifacts: [
// [artifactId: 'IOB-MAN',
// classifier: "${env.classifier}",
// file: "Releases\\${env.BRANCH_NAME}\\MAPO-IOB-MAN.zip",
// type: 'zip']
// ]
// )
// }
// ...
// else if (env.BRANCH_NAME == "develop" || env.BRANCH_NAME.contains("master") || env.BRANCH_NAME.contains("feature") ) {
if (env.BRANCH_NAME == "develop" || env.BRANCH_NAME.contains("master") ) {
fixResources("IOB-MAN")
fixResources("IOB-WIN-NEXT")
// elimino vecchio zip...
bat "RD /S /Q Releases\\${env.BRANCH_NAME}\\ || EXIT /B 0"
compressZip("IOB-WIN")
compressZip("IOB-MAN")
compressZip("IOB-WIN-NEXT")
// fix classificazione x develop/master...
@@ -150,11 +151,15 @@ pipeline {
repository: 'utility',
credentialsId: 'bc9d8e92-4302-3266-817f-7b58501d12d5',
artifacts: [
[artifactId: 'IOB-WIN',
classifier: "",
// classifier: "${env.classifier}",
file: "Releases\\${env.BRANCH_NAME}\\MAPO-IOB-WIN.zip",
type: 'zip'],
// [artifactId: 'IOB-WIN',
// classifier: "",
// // classifier: "${env.classifier}",
// file: "Releases\\${env.BRANCH_NAME}\\MAPO-IOB-WIN.zip",
// type: 'zip'],
[artifactId: 'IOB-MAN',
classifier: "${env.classifier}",
file: "Releases\\${env.BRANCH_NAME}\\MAPO-IOB-MAN.zip",
type: 'zip']
[artifactId: 'IOB-WIN-NEXT',
classifier: "",
// classifier: "${env.classifier}",
@@ -165,7 +170,7 @@ pipeline {
}
else
{
echo 'Nessuna compressione+copia post deploy x documentazione'
echo 'Nessuna compressione+copia post deploy'
}
}
}