props/Jenkinsfile

52 lines
2.3 KiB
Plaintext
Raw Normal View History

pipeline {
agent any
stages {
stage("Install") {
2022-04-25 08:56:41 +00:00
steps {
sh 'mamba env update --file environment.yml'
sh 'echo "mamba activate props" >> ~/.bashrc'
sh 'node --version && npm --version'
2022-12-01 07:02:10 +00:00
sh 'cd Props && npm install'
sh 'dotnet restore Props.Shop/Props.Shop.sln'
sh 'dotnet restore Props.Shop/Props.Shop.Tests.sln'
sh 'dotnet restore Props.Tests'
2022-04-25 08:56:41 +00:00
}
}
stage("Props.Shop") {
stages {
stage("Test") {
steps {
sh 'dotnet test --logger xunit --no-restore Props.Shop/Props.Shop.Tests.sln'
2022-04-25 07:44:05 +00:00
xunit([xUnitDotNet(excludesPattern: '', pattern: 'Props.Shop/*.Tests/TestResults/*.xml', stopProcessingIfError: true)])
}
}
stage("Publish") {
steps {
sh 'dotnet publish --configuration Release --output output/shop-modules Props.Shop/Props.Shop.sln'
fingerprint 'output/shop-modules/**/Props.Shop.*'
sh "python3 scripts/load_shop_modules.py"
}
}
}
}
stage("Props") {
stages {
stage("Test") {
steps {
sh 'dotnet test --logger xunit --no-restore Props.Tests'
2022-04-25 07:44:05 +00:00
xunit([xUnitDotNet(excludesPattern: '', pattern: 'Props.Tests/TestResults/*.xml', stopProcessingIfError: true)])
}
}
stage("Publish") {
steps {
sh 'dotnet publish --configuration Release --output output/props/props-linux-x64 --runtime linux-x64 --self-contained Props'
sh 'dotnet publish --configuration Release --output output/props/props-win-x64 --runtime win-x64 --self-contained Props'
fingerprint 'output/props/**/Props*'
2022-04-26 08:48:05 +00:00
tar file: "output/props-linux-x64.tar.gz", archive: true, compress: true, dir: "output/props/props-linux-x64"
zip zipFile: "output/props-win-x64.zip", archive: true, dir: "output/props/props-win-x64"
}
}
}
}
}
}